* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Roboto", sans-serif;
    line-height: 1.7;
    color: #333;
    background-color: #fff;
}

.article-wrapper {
    display: flex;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    gap: 2rem;
    padding-top: 6rem;
}

.article-container {
    flex: 1;
    max-width: 900px;
}

/* Article Metadata */
.article-metadata {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e0e0e0;
    font-size: 0.9rem;
    color: #666;
}

.article-metadata span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.article-metadata .tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.article-metadata .tag {
    background-color: #f0f0f0;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.85rem;
}

/* Article Header */
.article-header {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid #e0e0e0;
}

.article-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    color: #001327;
}

.article-intro {
    font-size: 1.25rem;
    color: #666;
    line-height: 1.8;
    margin-bottom: 1rem;
}

/* Author Section */
.author-section {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin: 2rem 0;
    border-left: 4px solid #001327;
}

.author-section h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #001327;
    margin-bottom: 0.5rem;
}

.author-section .author-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: #001327;
    margin-bottom: 0.25rem;
}

.author-section .author-title {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 0.75rem;
}

.author-section .author-bio {
    font-size: 0.95rem;
    color: #444;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.author-social {
    display: flex;
    gap: 1rem;
}

.author-social a {
    display: flex;
    align-items: center;
    color: #001327;
    text-decoration: none;
    font-size: 0.9rem;
}

.author-social a:hover {
    color: #002a4a;
}

.author-social img {
    width: 20px;
    height: 20px;
    margin-right: 0.5rem;
}

/* Table of Contents */
.toc-sidebar {
    width: 250px;
    position: sticky;
    top: 2rem;
    align-self: flex-start;
    max-height: calc(100vh - 4rem);
    overflow-y: auto;
}

.toc-sidebar h3 {
    font-size: 1rem;
    font-weight: 700;
    color: #001327;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e0e0e0;
}

.toc-sidebar ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.toc-sidebar li {
    margin-bottom: 0.5rem;
}

.toc-sidebar a {
    display: block;
    padding: 0.5rem 0.75rem;
    color: #666;
    text-decoration: none;
    font-size: 0.9rem;
    border-radius: 4px;
    transition: all 0.2s;
}

.toc-sidebar a:hover,
.toc-sidebar a.active {
    background-color: #f0f0f0;
    color: #001327;
    font-weight: 600;
}

/* Article Content */
.article-content {
    font-size: 1.1rem;
    line-height: 1.8;
}

.article-content h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    color: #001327;
    padding-top: 1rem;
    scroll-margin-top: 2rem;
}

.article-content h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #001327;
}

.article-content p {
    margin-bottom: 1.5rem;
    color: #444;
}

.article-content ul,
.article-content ol {
    margin-left: 2rem;
    margin-bottom: 1.5rem;
}

.article-content li {
    margin-bottom: 1rem;
    line-height: 1.7;
}

.article-content strong {
    font-weight: 600;
    color: #001327;
}

.article-content a {
    color: #0066cc;
    text-decoration: underline;
}

.article-content a:hover {
    color: #0052a3;
}

/* Callout Boxes */
.callout {
    margin: 2rem 0;
    padding: 1.25rem 1.5rem;
    border-radius: 6px;
    border-left: 4px solid;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.callout-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    margin-top: 0.25rem;
}

.callout-content {
    flex: 1;
}

.callout-content strong {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 1.05rem;
}

.callout-warning {
    background-color: rgba(255, 193, 7, 0.1);
    border-left-color: #ffc107;
    color: #856404;
}

.callout-tip {
    background-color: rgba(40, 167, 69, 0.1);
    border-left-color: #28a745;
    color: #155724;
}

.callout-info {
    background-color: rgba(0, 123, 255, 0.1);
    border-left-color: #007bff;
    color: #004085;
}

/* Visual Cards */
.cards-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin: 2rem 0;
    max-width: 100%;
}

/* Ensure 2 columns on all medium and larger screens - prevent auto-fit */
@media (min-width: 768px) {
    .cards-grid {
        grid-template-columns: 1fr 1fr !important;
        grid-auto-flow: row;
    }
}

.card {
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.3s;
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.card-number {
    display: inline-block;
    width: 32px;
    height: 32px;
    background-color: #001327;
    color: #fff;
    border-radius: 50%;
    text-align: center;
    line-height: 32px;
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.card h3 {
    font-size: 1.25rem;
    margin-top: 0;
    margin-bottom: 0.75rem;
}

.card p {
    margin-bottom: 0;
    font-size: 0.95rem;
}

/* FAQ Cards */
.faq-card {
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.faq-card h3 {
    font-size: 1.1rem;
    margin-top: 0;
    margin-bottom: 0.75rem;
    color: #001327;
}

.faq-card p {
    margin-bottom: 0;
    font-size: 0.95rem;
}

/* Article Images */
.article-image {
    margin: 1.5rem 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.article-image.float-right {
    float: right;
    margin-left: 2rem;
    margin-right: 0;
    max-width: 400px;
    width: 100%;
}

.article-image.float-left {
    float: left;
    margin-right: 2rem;
    margin-left: 0;
    max-width: 350px;
    width: 100%;
}

.article-image.full-width {
    width: 100%;
    max-width: 100%;
}

.article-image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
}

.article-image figcaption {
    font-size: 0.85rem;
    color: #666;
    text-align: center;
    margin-top: 0.5rem;
    font-style: italic;
    padding: 0 0.5rem;
}

/* Placeholder Images (for other images that aren't ready yet) */
.image-placeholder {
    background-color: #f0f0f0;
    border: 2px dashed #ccc;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 0.9rem;
    text-align: center;
    margin: 1.5rem 0;
}

.image-placeholder.float-right {
    float: right;
    margin-left: 2rem;
    margin-right: 0;
    width: 400px;
    max-width: 100%;
    min-height: 250px;
}

.image-placeholder.float-left {
    float: left;
    margin-right: 2rem;
    margin-left: 0;
    width: 350px;
    max-width: 100%;
    min-height: 200px;
}

.image-placeholder.full-width {
    width: 100%;
    min-height: 300px;
}

.image-caption {
    font-size: 0.85rem;
    color: #666;
    text-align: center;
    margin-top: 0.5rem;
    font-style: italic;
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, #001327 0%, #002a4a 100%);
    padding: 3rem 2rem;
    border-radius: 12px;
    margin: 4rem 0;
    text-align: center;
    color: #fff;
}

.cta-section h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #fff;
    margin-top: 0;
}

.cta-section p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.9);
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-section a {
    display: inline-block;
    background-color: #39FF12;
    color: #001327;
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s;
}

.cta-section a:hover {
    background-color: #2ee00f;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(57, 255, 18, 0.3);
}

.cta-section a.secondary {
    background-color: transparent;
    border: 2px solid #fff;
    color: #fff;
}

.cta-section a.secondary:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Mobile TOC */
.toc-mobile {
    display: none;
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.toc-mobile-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-weight: 600;
    color: #001327;
}

.toc-mobile-content {
    display: none;
    margin-top: 1rem;
}

.toc-mobile-content.active {
    display: block;
}

.toc-mobile ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.toc-mobile li {
    margin-bottom: 0.5rem;
}

.toc-mobile a {
    display: block;
    padding: 0.5rem 0.75rem;
    color: #666;
    text-decoration: none;
    border-radius: 4px;
}

.toc-mobile a:hover {
    background-color: #e0e0e0;
    color: #001327;
}

/* Responsive */
@media (max-width: 968px) {
    .article-wrapper {
        flex-direction: column;
        padding-top: 5rem;
    }

    .toc-sidebar {
        display: none;
    }

    .toc-mobile {
        display: block;
    }

            .image-placeholder.float-right,
            .image-placeholder.float-left,
            .article-image.float-right,
            .article-image.float-left {
                float: none;
                width: 100%;
                max-width: 100%;
                margin: 1.5rem 0;
            }
}

@media (max-width: 768px) {
    .article-wrapper {
        padding: 1rem;
        padding-top: 4rem;
    }

    .article-header h1 {
        font-size: 2rem;
    }

    .article-content h2 {
        font-size: 1.75rem;
    }

    .article-content {
        font-size: 1rem;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .cta-section {
        padding: 2rem 1.5rem;
    }

    .cta-section h3 {
        font-size: 1.5rem;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .cta-section a {
        width: 100%;
    }
}

/* Redirect Mapping Example Table */
.redirect-mapping-example {
    margin: 2rem 0;
    overflow-x: auto;
}

.redirect-example-table {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    border-collapse: collapse;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.redirect-example-table thead {
    background-color: #f8f9fa;
}

.redirect-example-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.95rem;
    color: #001327;
    border-bottom: 2px solid #e0e0e0;
}

.redirect-example-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #f0f0f0;
    color: #444;
    font-size: 0.9rem;
    font-family: 'Courier New', monospace;
}

.redirect-example-table tbody tr:last-child td {
    border-bottom: none;
}

.redirect-example-table tbody tr:hover {
    background-color: #f8f9fa;
}

@media (max-width: 768px) {
    .redirect-example-table {
        max-width: 100%;
    }
    
    .redirect-example-table th,
    .redirect-example-table td {
        padding: 0.5rem 0.75rem;
        font-size: 0.85rem;
    }
}
