/* Theme Variables */
:root {
    --brand-color: #8B5CF6;
}
html[data-theme="us"] {
    --brand-color: #10b981;
}
html[data-theme="metric"] {
    --brand-color: #8B5CF6;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #F9F7FB;
    color: #2D2D2D;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    background: #FFFFFF;
    box-shadow: 0 2px 10px rgba(139, 92, 246, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--brand-color, #8B5CF6);
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    color: #2D2D2D;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--brand-color, #8B5CF6);
}

.nav-link.active {
    color: var(--brand-color, #8B5CF6);
    font-weight: 600;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--brand-color, #8B5CF6);
    border-radius: 1px;
    transition: background 0.3s ease;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: #2D2D2D;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    padding: 80px 0;
    text-align: center;
}

.hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #2D2D2D;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #71717A;
    margin-bottom: 2rem;
}

.search-box {
    max-width: 500px;
    margin: 0 auto;
    display: flex;
    gap: 10px;
    background: #FFFFFF;
    padding: 8px;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(139, 92, 246, 0.1);
}

.search-box input {
    flex: 1;
    border: none;
    padding: 12px 20px;
    font-size: 1rem;
    background: transparent;
    outline: none;
}

.search-box button {
    background: #8B5CF6;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}

.search-box button:hover {
    background: #7C3AED;
}

/* Tools Grid */
.featured-tools, .all-tools {
    padding: 60px 0;
}

.featured-tools h2, .all-tools h2 {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: #2D2D2D;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.tool-card {
    background: #FFFFFF;
    border-radius: 20px;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    border-color: var(--brand-color);
}

.tool-card.featured {
    background: linear-gradient(135deg, #8B5CF6 0%, #A855F7 100%);
    color: white;
}

.tool-card.featured:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(139, 92, 246, 0.3);
}

.tool-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.tool-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    padding: 1.5rem;
    margin: 0;
    text-align: center;
}

.tool-card p {
    color: inherit;
    opacity: 0.8;
    line-height: 1.5;
}

.tool-card.featured p {
    opacity: 0.9;
}

/* Page Header */
.page-header {
    padding: 60px 0;
    text-align: center;
    background: #FFFFFF;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #2D2D2D;
}

.page-header p {
    font-size: 1.1rem;
    color: #71717A;
    max-width: 600px;
    margin: 0 auto;
}

/* Calculator Styles */
.calculator-section {
    padding: 60px 0;
}

.calculator-card {
    background: #FFFFFF;
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(139, 92, 246, 0.08);
    margin-bottom: 2rem;
}

.calculator-card h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: #2D2D2D;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #2D2D2D;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #E5E7EB;
    border-radius: 12px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #8B5CF6;
}

.btn {
    background: var(--brand-color);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
    font-size: 1rem;
}

.btn:hover {
    opacity: 0.85;
}

.result-card {
    background: #F3F4F6;
    padding: 1.5rem;
    border-radius: 12px;
    margin-top: 1.5rem;
    border-left: 4px solid #8B5CF6;
}

.result-card h3 {
    color: #2D2D2D;
    margin-bottom: 1rem;
}

/* Table Styles */
.yarn-table {
    width: 100%;
    border-collapse: collapse;
    background: #FFFFFF;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(139, 92, 246, 0.08);
}

.yarn-table th,
.yarn-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #E5E7EB;
}

.yarn-table th {
    background: #8B5CF6;
    color: white;
    font-weight: 600;
}

.yarn-table tr:hover {
    background: #F9F7FB;
}

/* Footer */
.footer {
    background: #2D2D2D;
    color: white;
    padding: 60px 0 20px;
    margin-top: 80px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
    color: var(--brand-color, #8B5CF6);
    transition: color 0.3s ease;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: #CCCCCC;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: var(--brand-color, #8B5CF6);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #444;
    color: #CCCCCC;
}

/* Responsive Design */
@media (max-width: 768px) {
    /* Force the top bar to align logo / toggle / hamburger on one line */
    .nav-container {
        flex-wrap: nowrap;
        padding: 0 16px;
        height: 60px;
        gap: 0;
    }

    .nav-logo {
        flex: 1 1 auto;
        font-size: 1.25rem;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 60px;
        flex-direction: column;
        background-color: #FFFFFF;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 1rem 0;
        max-height: calc(100vh - 60px);
        overflow-y: auto;
        z-index: 999;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-toggle {
        display: flex;
        flex-shrink: 0;
        margin-left: 12px;
    }

    .hero h1 {
        font-size: 2rem;
    }

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

    .search-box {
        flex-direction: column;
    }

    .search-box input,
    .search-box button {
        width: 100%;
    }
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mb-2 {
    margin-bottom: 2rem;
}

.mt-2 {
    margin-top: 2rem;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

@media (max-width: 768px) {
    .grid-2 {
        grid-template-columns: 1fr;
    }
}
/* Article Styles for Knowledge Base Pages */
.article-container {
    background: #FFFFFF;
    margin-top: 0;
}

.article-header {
    background: linear-gradient(135deg, #F9F7FB 0%, #FFFFFF 100%);
    padding: 60px 0 40px;
    border-bottom: 1px solid #E5E7EB;
}

.article-image-container {
    text-align: center;
    padding: 40px 0;
}

.breadcrumb {
    font-size: 0.9rem;
    color: #71717A;
    margin-bottom: 1rem;
}

.breadcrumb a {
    color: var(--brand-color);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

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

.article-subtitle {
    font-size: 1.25rem;
    color: #71717A;
    margin-bottom: 2rem;
    line-height: 1.4;
}

.article-meta {
    display: flex;
    gap: 2rem;
    font-size: 0.9rem;
    color: #71717A;
}

.reading-time, .article-category {
    background: #F3F4F6;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 500;
}

.article-content {
    padding: 60px 0;
}

.content-section {
    margin-bottom: 4rem;
}

.content-section h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #2D2D2D;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #8B5CF6;
    padding-bottom: 0.5rem;
}

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

.content-section h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2D2D2D;
    margin-bottom: 0.75rem;
    margin-top: 1.5rem;
}

.lead-paragraph {
    font-size: 1.2rem;
    line-height: 1.6;
    color: #2D2D2D;
    margin-bottom: 2rem;
}

.highlight-box {
    background: linear-gradient(135deg, #8B5CF6 0%, #A855F7 100%);
    color: white;
    padding: 2rem;
    border-radius: 20px;
    margin: 2rem 0;
}

.highlight-box h3 {
    color: white;
    margin-top: 0;
}

.highlight-box ul {
    margin-left: 1.5rem;
}

.reality-check {
    background: #FEF2F2;
    border: 2px solid #FECACA;
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem 0;
}

.reality-check h3 {
    color: #DC2626;
    margin-top: 0;
}

/* Yarn Weight Guide Styles */
.yarn-weight-guide {
    display: grid;
    gap: 1.5rem;
    margin: 2rem 0;
}

.weight-card {
    display: flex;
    background: #FFFFFF;
    border: 2px solid #E5E7EB;
    border-radius: 15px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.weight-card:hover {
    border-color: #8B5CF6;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.15);
}

.weight-card.featured-weight {
    border-color: #8B5CF6;
    background: #F9F7FB;
}

.weight-card.most-popular {
    border-color: #8B5CF6;
    background: linear-gradient(135deg, #8B5CF6 0%, #A855F7 100%);
    color: white;
}

.weight-number {
    font-size: 2rem;
    font-weight: 700;
    color: #8B5CF6;
    background: #F9F7FB;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1.5rem;
    flex-shrink: 0;
}

.most-popular .weight-number {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.weight-info h4 {
    margin-top: 0;
    margin-bottom: 0.5rem;
    font-size: 1.25rem;
}

.weight-info p {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    line-height: 1.4;
}

.popular-badge {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-block;
    margin-top: 0.5rem;
}

.pro-tip {
    background: #F0FDF4;
    border: 2px solid #BBF7D0;
    border-radius: 15px;
    padding: 1.5rem;
    margin: 2rem 0;
}

.pro-tip h3 {
    color: #16A34A;
    margin-top: 0;
}

/* Step-by-step Guide Styles */
.step-by-step-guide {
    margin: 2rem 0;
}

.step {
    display: flex;
    margin-bottom: 3rem;
    padding: 2rem;
    background: #FFFFFF;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(139, 92, 246, 0.08);
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.step:hover {
    border-color: #8B5CF6;
    transform: translateY(-2px);
}

.step.critical-step {
    border-color: #DC2626;
    background: #FEF2F2;
}

.step-number {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    background: #8B5CF6;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 2rem;
    flex-shrink: 0;
}

.critical-step .step-number {
    background: #DC2626;
}

.step-content h3 {
    margin-top: 0;
    color: #2D2D2D;
}

.why-box {
    background: #F9F7FB;
    border-left: 4px solid #8B5CF6;
    padding: 1rem 1.5rem;
    margin: 1rem 0;
    border-radius: 0 10px 10px 0;
}

.blocking-guide, .measuring-technique {
    background: #F3F4F6;
    padding: 1.5rem;
    border-radius: 10px;
    margin: 1rem 0;
}

.blocking-importance {
    background: #FEF2F2;
    border: 1px solid #FECACA;
    padding: 1.5rem;
    border-radius: 10px;
    margin: 1rem 0;
}

.measuring-tips {
    background: #F0FDF4;
    border: 1px solid #BBF7D0;
    padding: 1.5rem;
    border-radius: 10px;
    margin: 1rem 0;
}

/* Troubleshooting Styles */
.gauge-troubleshooting {
    margin: 2rem 0;
}

.gauge-scenario {
    background: #FFFFFF;
    border: 2px solid #E5E7EB;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.gauge-scenario.critical {
    border-color: #DC2626;
    background: #FEF2F2;
}

.gauge-scenario h3 {
    margin-top: 0;
    color: #2D2D2D;
}

.problem {
    background: #FEF2F2;
    border-left: 4px solid #DC2626;
    padding: 1rem 1.5rem;
    margin: 1rem 0;
    border-radius: 0 10px 10px 0;
}

.solution {
    background: #F0FDF4;
    border-left: 4px solid #16A34A;
    padding: 1rem 1.5rem;
    margin: 1rem 0;
    border-radius: 0 10px 10px 0;
}

.explanation {
    background: #F9F7FB;
    border-left: 4px solid #8B5CF6;
    padding: 1rem 1.5rem;
    margin: 1rem 0;
    border-radius: 0 10px 10px 0;
}

/* Utility Styles */
.myth-busting {
    margin: 2rem 0;
}

.myth {
    background: #FFFFFF;
    border: 2px solid #E5E7EB;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.myth h4 {
    color: #DC2626;
    margin-top: 0;
}

.control-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.control-item {
    background: #F9F7FB;
    padding: 1.5rem;
    border-radius: 15px;
    border: 2px solid #E5E7EB;
}

.control-item h4 {
    margin-top: 0;
    color: #8B5CF6;
}

.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.tip-card {
    background: #FFFFFF;
    border: 2px solid #E5E7EB;
    border-radius: 15px;
    padding: 2rem;
}

.tip-card h4 {
    margin-top: 0;
    color: #8B5CF6;
}

.success-checklist {
    background: #F0FDF4;
    border: 2px solid #BBF7D0;
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem 0;
}

.checklist {
    list-style: none;
    padding-left: 0;
}

.checklist li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #BBF7D0;
}

.checklist li:before {
    content: "✓ ";
    color: #16A34A;
    font-weight: bold;
    margin-right: 0.5rem;
}

.final-motivation {
    background: linear-gradient(135deg, #8B5CF6 0%, #A855F7 100%);
    color: white;
    padding: 2rem;
    border-radius: 20px;
    margin: 2rem 0;
    text-align: center;
}

.final-motivation h3 {
    color: white;
    margin-top: 0;
}

.next-steps {
    text-align: center;
    margin: 3rem 0;
}

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

.cta-button {
    display: inline-block;
    padding: 1rem 2rem;
    border-radius: 15px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.cta-button.primary {
    background: #8B5CF6;
    color: white;
}

.cta-button.primary:hover {
    background: #7C3AED;
    transform: translateY(-2px);
}

.cta-button.secondary {
    background: #F3F4F6;
    color: #2D2D2D;
    border: 2px solid #E5E7EB;
}

.cta-button.secondary:hover {
    border-color: #8B5CF6;
    color: #8B5CF6;
    transform: translateY(-2px);
}

/* WPI Guide Styles */
.wpi-guide {
    margin: 2rem 0;
}

.wpi-reference {
    background: #F9F7FB;
    border: 2px solid #8B5CF6;
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem 0;
}

.wpi-reference h3 {
    color: #8B5CF6;
    margin-top: 0;
}

.wpi-reference ul {
    columns: 2;
    column-gap: 2rem;
}

/* Label Guide Styles */
.label-guide {
    margin: 2rem 0;
}

.label-section {
    background: #FFFFFF;
    border: 2px solid #E5E7EB;
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.label-section h4 {
    margin-top: 0;
    color: #8B5CF6;
}

.important-note {
    background: #FEF2F2;
    border: 2px solid #FECACA;
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem 0;
}

.important-note h3 {
    color: #DC2626;
    margin-top: 0;
}

/* Advanced Tips Styles */
.advanced-tips {
    margin: 2rem 0;
}

.tip-section {
    background: #FFFFFF;
    border: 2px solid #E5E7EB;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.tip-section h3 {
    margin-top: 0;
    color: #8B5CF6;
}

.yarn-specific h4 {
    color: #2D2D2D;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.backup-strategies {
    margin: 2rem 0;
}

.strategy {
    background: #FFFFFF;
    border: 2px solid #E5E7EB;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.strategy h3 {
    margin-top: 0;
    color: #8B5CF6;
}

.how-it-works {
    background: #F9F7FB;
    padding: 1.5rem;
    border-radius: 10px;
    margin: 1rem 0;
}

.needle-size-guide {
    background: #F0FDF4;
    border: 2px solid #BBF7D0;
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem 0;
}

.needle-size-guide h3 {
    color: #16A34A;
    margin-top: 0;
}

/* Responsive Design for Articles */
@media (max-width: 768px) {
    .article-header h1 {
        font-size: 2rem;
    }
    
    .article-subtitle {
        font-size: 1.1rem;
    }
    
    .article-meta {
        flex-direction: column;
        gap: 1rem;
    }
    
    .step {
        flex-direction: column;
        text-align: center;
    }
    
    .step-number {
        margin-right: 0;
        margin-bottom: 1rem;
    }
    
    .control-grid, .tips-grid {
        grid-template-columns: 1fr;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .cta-button {
        width: 100%;
        max-width: 300px;
    }
    
    .wpi-reference ul {
        columns: 1;
    }
}/* Kn
owledge Base Link Styles */
.knowledge-link {
    background: linear-gradient(135deg, #F0FDF4 0%, #ECFDF5 100%);
    border: 2px solid #BBF7D0;
    border-radius: 15px;
    padding: 1.5rem 2rem;
    margin-top: 2rem;
    text-align: center;
    width: 100%;
    box-sizing: border-box;
}

.knowledge-link p {
    margin: 0;
    font-size: 1.1rem;
    color: #2D2D2D;
    line-height: 1.5;
    max-width: none;
}

.knowledge-link a {
    color: #16A34A;
    text-decoration: none;
    font-weight: 600;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.knowledge-link a:hover {
    color: #15803D;
    border-bottom-color: #15803D;
}
/* Ad
ditional responsive adjustments for knowledge links */
@media (max-width: 768px) {
    .knowledge-link {
        padding: 1.25rem 1.5rem;
        text-align: left;
        margin-top: 1.5rem;
    }
    
    .knowledge-link p {
        font-size: 1rem;
        line-height: 1.4;
    }
}
* Guides Page Specific Styles */
.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: #71717A;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Knowledge Article Cards */
.tool-card.knowledge-article {
    background: linear-gradient(135deg, #F9F7FB 0%, #FFFFFF 100%);
    border: 2px solid #8B5CF6;
    position: relative;
    overflow: hidden;
}

.tool-card.knowledge-article::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #8B5CF6 0%, #A855F7 100%);
}

.tool-card.knowledge-article:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 35px rgba(139, 92, 246, 0.2);
    border-color: #7C3AED;
}

.tool-card.knowledge-article img {
    width: 100%;
    height: 225px;
    object-fit: cover;
    border-radius: 20px 20px 0 0;
}

.tool-card.knowledge-article .tool-icon {
    background: linear-gradient(135deg, #8B5CF6 0%, #A855F7 100%);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.article-meta-small {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #E5E7EB;
}

.reading-time, .article-tag {
    font-size: 0.85rem;
    color: #71717A;
    background: #F3F4F6;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-weight: 500;
}

.article-tag {
    background: #8B5CF6;
    color: white;
}

/* Section spacing adjustments */
.featured-tools + .all-tools {
    padding-top: 40px;
}

.all-tools h2 {
    margin-bottom: 1rem;
}

/* Responsive adjustments for guides page */
@media (max-width: 768px) {
    .article-meta-small {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .reading-time, .article-tag {
        align-self: flex-start;
    }
}

/* Latest Articles Section */
.latest-articles {
    padding: 60px 0;
}

.latest-articles h2 {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: #2D2D2D;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.article-card {
    background: #FFFFFF;
    border-radius: 20px;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    overflow: hidden;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
}

.article-card:hover h3 {
    color: var(--brand-color);
}

.article-card img {
    width: 100%;
    height: 225px;
    object-fit: cover;
}

.article-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    padding: 1.5rem;
    margin: 0;
    text-align: left;
}

@media (max-width: 992px) {
    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .articles-grid {
        grid-template-columns: 1fr;
    }

    .latest-articles h2 {
        font-size: 2rem;
    }
}

/* --- Navigation Dropdown Styles (Add to main.css) --- */
.nav-menu li {
    position: relative;
}

/* Arrow styling */
.nav-link .arrow {
    font-size: 0.7em;
    margin-left: 4px;
    vertical-align: middle;
}

/* Dropdown Menu (Hidden by default) */
.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: white;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-radius: 8px;
    min-width: 200px;
    padding: 10px 0;
    z-index: 1000;
    list-style: none;
    border: 1px solid #eee;
}

/* Show Dropdown on Hover */
.has-dropdown:hover .dropdown-menu {
    display: block;
}

/* Dropdown Links */
.dropdown-menu li {
    margin: 0;
    display: block;
}

.dropdown-menu li a {
    display: block;
    padding: 10px 20px;
    color: #333;
    text-decoration: none;
    font-size: 0.95rem;
    white-space: nowrap;
    transition: background 0.2s;
}

.dropdown-menu li a:hover {
    background-color: #f5f7fa;
    color: #2c3e50;
}

/* Mobile Responsiveness for Dropdowns */
@media (max-width: 768px) {
    .dropdown-menu {
        position: static;
        box-shadow: none;
        border: none;
        padding-left: 20px; /* Indent sub-items on mobile */
        display: none; /* Keep hidden until clicked/active if using JS, or rely on hover for simplified layout */
    }
    
    /* On mobile, simply show them always or rely on simple layout flows */
    .has-dropdown:hover .dropdown-menu {
        display: block;
    }
    
    .nav-link .arrow {
        float: right;
    }
}