/* ================================================ */
/* Modern, Clean Article Layout with Perfect Spacing */
/* ================================================ */

:root {
    /* Color Palette */
    --primary: #4361ee;
    --primary-dark: #3a0ca3;
    --accent: #7209b7;
    --accent-light: #f72585;
    --light: #f8f9fa;
    --dark: #1a1a2e;
    --gray-100: #f8f9fa;
    --gray-200: #e9ecef;
    --gray-300: #dee2e6;
    --gray-400: #ced4da;
    --gray-500: #6c757d;
    --gray-600: #495057;
    --gray-700: #343a40;
    --gray-800: #212529;

    /* Semantic Colors */
    --text: var(--gray-800);
    --text-light: var(--gray-600);
    --text-lighter: var(--gray-500);
    --border: var(--gray-300);
    --shadow: rgba(0, 0, 0, 0.08);
    --shadow-hover: rgba(0, 0, 0, 0.12);

    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 4rem;

    /* Border Radius */
    --radius-sm: 0.5rem;
    --radius-md: 1rem;
    --radius-lg: 1.5rem;
    --radius-xl: 2rem;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition: 0.3s ease;
    --transition-slow: 0.5s ease;

    /* Layout */
    --header-height: 80px;
    --content-width: 1200px;
    --content-narrow: 800px;
    --sidebar-width: 280px;
}

/* ===== BASE RESETS & UTILITIES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.article-main {
    padding-top: 0px;
    /*background: var(--gray-100);*/
    min-height: 100vh;
}

.container {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 var(--space-md);
}

.container-narrow {
    max-width: var(--content-narrow);
    margin: 0 auto;
    padding: 0 var(--space-md);
}

.glass-effect {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-md);
    box-shadow: 0 4px 20px var(--shadow);
}

/* ===== ARTICLE HERO SECTION ===== */
.article-hero {
    position: relative;
    padding: var(--space-2xl) 0 var(--space-xl);
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.05) 0%,
            rgba(114, 9, 183, 0.03) 100%);
    overflow: hidden;
}

.article-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%,
            rgba(67, 97, 238, 0.03) 0%,
            transparent 50%),
        radial-gradient(circle at 80% 20%,
            rgba(114, 9, 183, 0.02) 0%,
            transparent 50%);
    pointer-events: none;
}

.article-hero-content {
    position: relative;
    z-index: 2;
}

/* Breadcrumb */
.breadcrumb {
    margin-bottom: var(--space-lg);
}

.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    gap: var(--space-sm);
    align-items: center;
}

.breadcrumb li {
    display: flex;
    align-items: center;
    color: var(--text-lighter);
    font-size: 0.9rem;
}

.breadcrumb li:not(:last-child)::after {
    content: '/';
    margin-left: var(--space-sm);
    opacity: 0.5;
}

.breadcrumb a {
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

.breadcrumb a:hover {
    color: var(--accent);
}

.breadcrumb [aria-current="page"] {
    color: var(--text);
    font-weight: 500;
}

/* Article Header */
.article-header {
    margin-bottom: var(--space-xl);
}

.article-category {
    display: flex;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
    flex-wrap: wrap;
    align-items: center;
}

.category-badge {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.reading-time {
    color: var(--text-lighter);
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.article-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: var(--space-lg);
    color: var(--text);
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Article Meta */
.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--border);
    flex-wrap: wrap;
    gap: var(--space-md);
}

.author-info {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.author-avatar {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.author-name {
    display: block;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.25rem;
}

.publish-date {
    font-size: 0.9rem;
    /*color: var(--text-lighter);*/
}

.article-stats {
    display: flex;
    gap: var(--space-md);
}

.stat {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    /*color: var(--text-lighter);*/
    font-size: 0.9rem;
}

.stat i {
    color: var(--primary);
}

/* Featured Image */
.featured-image {
    margin: var(--space-xl) 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
}

.featured-image img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block;
}

.image-caption {
    padding: var(--space-sm) var(--space-md);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    font-size: 0.9rem;
    text-align: center;
}

/* Article Summary */
.article-summary {
    display: flex;
    gap: var(--space-lg);
    padding: var(--space-lg);
    margin: var(--space-xl) 0;
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.05),
            rgba(114, 9, 183, 0.03));
    border-left: 4px solid var(--accent);
    border-radius: var(--radius-md);
}

.summary-icon {
    font-size: 2.5rem;
    color: var(--accent);
    flex-shrink: 0;
}

.summary-content h3 {
    color: var(--primary);
    margin-bottom: var(--space-md);
    font-size: 1.4rem;
}

.summary-content ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.summary-content li {
    margin-bottom: 0.75rem;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-light);
    line-height: 1.6;
}

.summary-content li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: bold;
}

.summary-content li strong {
    color: var(--primary);
}

/* ===== MAIN CONTENT LAYOUT ===== */
.article-content {
    padding: var(--space-2xl) 0;
}

.content-wrapper {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    gap: var(--space-xl);
    align-items: start;
}

/* ===== TABLE OF CONTENTS ===== */
.table-of-contents {
    position: sticky;
    top: calc(var(--header-height) + var(--space-md));
    align-self: start;
    max-height: calc(100vh - var(--header-height) - var(--space-lg));
    overflow-y: auto;
}

.toc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-md);
    padding-bottom: var(--space-sm);
    border-bottom: 2px solid rgba(67, 97, 238, 0.1);
}

.toc-header h3 {
    font-size: 1.1rem;
    color: var(--primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.toc-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-lighter);
    cursor: pointer;
    transition: var(--transition);
}

.toc-toggle:hover {
    color: var(--primary);
}

.toc-nav ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

.toc-nav li {
    margin-bottom: 0.5rem;
}

.toc-nav a {
    /*color: var(--text-light);*/
    text-decoration: none;
    font-size: 0.95rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    display: block;
    transition: var(--transition);
    position: relative;
    padding-left: 1.5rem;
}

.toc-nav a::before {
    content: "#";
    position: absolute;
    left: 0.5rem;
    color: var(--primary);
    opacity: 0.7;
    font-weight: bold;
}

.toc-nav a:hover,
.toc-nav a.active {
    color: var(--primary);
    background: rgba(67, 97, 238, 0.1);
    padding-left: 1.75rem;
}

/* ===== ARTICLE BODY ===== */
.article-body {
    line-height: 1.8;
    /*color: var(--text-light);*/
}

.article-section {
    margin-bottom: var(--space-2xl);
    padding-bottom: var(--space-xl);
    border-bottom: 1px solid var(--border);
}

.article-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.article-section h2 {
    font-size: 2rem;
    color: var(--text);
    margin-bottom: var(--space-lg);
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.article-section h2 i {
    color: var(--primary);
    font-size: 1.8rem;
}

.article-section h3 {
    font-size: 1.5rem;
    color: var(--text);
    margin: var(--space-lg) 0 var(--space-md);
}

.article-section p {
    margin-bottom: var(--space-md);
    line-height: 1.8;
}

.article-section strong {
    color: var(--text);
    font-weight: 600;
}

/* ===== INFO BOXES ===== */
.info-box {
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    margin: var(--space-lg) 0;
    display: flex;
    gap: var(--space-md);
    align-items: flex-start;
}

.info-box.important {
    background: linear-gradient(135deg,
            rgba(255, 193, 7, 0.1),
            rgba(255, 152, 0, 0.05));
    border-left: 4px solid #ff9800;
}

.info-box.warning {
    background: linear-gradient(135deg,
            rgba(244, 67, 54, 0.1),
            rgba(229, 57, 53, 0.05));
    border-left: 4px solid #e53935;
}

.info-box.tip {
    background: linear-gradient(135deg,
            rgba(76, 175, 80, 0.1),
            rgba(56, 142, 60, 0.05));
    border-left: 4px solid #388e3c;
}

.info-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.info-box.important .info-icon {
    color: #ff9800;
}

.info-box.warning .info-icon {
    color: #e53935;
}

.info-box.tip .info-icon {
    color: #388e3c;
}

.info-content h4 {
    margin: 0 0 0.5rem 0;
    color: var(--primary);
    font-size: 1.1rem;
}

.info-content p {
    margin: 0;
    color: inherit;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ===== SLEEP STAGES CARDS ===== */
.sleep-stages-visual {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-md);
    margin: var(--space-lg) 0;
}

.stage-card {
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 4px 15px var(--shadow);
    transition: var(--transition);
    border: 2px solid transparent;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.stage-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px var(--shadow-hover);
}

.stage-card[data-stage="n1"] {
    border-color: #e3f2fd;
}

.stage-card[data-stage="n2"] {
    border-color: #e8f5e9;
}

.stage-card[data-stage="n3"] {
    border-color: #fce4ec;
}

.stage-card[data-stage="rem"] {
    border-color: #f3e5f5;
}

.stage-header {
    padding: var(--space-md);
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
}

.stage-number {
    display: block;
    font-size: 0.8rem;
    opacity: 0.9;
    margin-bottom: 0.25rem;
}

.stage-header h3 {
    margin: 0;
    font-size: 1.2rem;
    color: white;
}

.stage-content {
    padding: var(--space-md);
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.stage-duration {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: var(--space-md);
}

.stage-brainwave {
    margin-top: auto;
    padding-top: var(--space-md);
    border-top: 1px solid var(--border);
    font-size: 0.9rem;
}

.stage-brainwave .label {
    color: var(--text-lighter);
    margin-right: 0.5rem;
}

/* ===== COMPARISON TABLE ===== */
.comparison-table {
    margin: var(--space-xl) 0;
    overflow-x: auto;
    border-radius: var(--radius-md);
    box-shadow: 0 2px 10px var(--shadow);
}

.comparison-table h3 {
    color: var(--text);
    margin-bottom: var(--space-md);
    font-size: 1.4rem;
}

.comparison-table table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    min-width: 600px;
}

.comparison-table thead {
    background: linear-gradient(135deg, var(--primary), var(--accent));
}

.comparison-table th {
    padding: 1rem var(--space-md);
    text-align: left;
    color: white;
    font-weight: 600;
    font-size: 0.95rem;
}

.comparison-table tbody tr {
    border-bottom: 1px solid var(--border);
    transition: var(--transition);
}

.comparison-table tbody tr:hover {
    background: rgba(67, 97, 238, 0.05);
}

.comparison-table td {
    padding: var(--space-md);
    color: var(--text-light);
    font-size: 0.95rem;
}

.comparison-table td:first-child {
    font-weight: 600;
    color: var(--text);
}

/* ===== CYCLE VISUALIZATION ===== */
.cycle-visualization {
    margin: var(--space-xl) 0;
}

.cycle-timeline {
    display: flex;
    height: 80px;
    margin-bottom: var(--space-lg);
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
}

.timeline-bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    position: relative;
    transition: var(--transition);
    flex: 1;
}

.timeline-bar[data-stage="n1"] {
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
    color: #1565c0;
}

.timeline-bar[data-stage="n2"] {
    background: linear-gradient(135deg, #e8f5e9, #c8e6c9);
    color: #2e7d32;
}

.timeline-bar[data-stage="n3"] {
    background: linear-gradient(135deg, #fce4ec, #f8bbd9);
    color: #c2185b;
}

.timeline-bar[data-stage="rem"] {
    background: linear-gradient(135deg, #f3e5f5, #e1bee7);
    color: #7b1fa2;
}

.timeline-bar:hover {
    filter: brightness(1.1);
    transform: scale(1.02);
    z-index: 2;
}

.stage-label {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.time-label {
    font-size: 0.8rem;
    opacity: 0.9;
}

.cycle-marker {
    position: absolute;
    bottom: -1.5rem;
    left: 50%;
    transform: translateX(-50%);
    background: var(--dark);
    color: white;
    padding: 0.25rem 1rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    white-space: nowrap;
}

.cycle-legend {
    display: flex;
    justify-content: center;
    gap: var(--space-xl);
    margin-top: var(--space-xl);
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.color-box {
    width: 20px;
    height: 20px;
    border-radius: 4px;
}

.color-box.n1 {
    background: #e3f2fd;
}

.color-box.n2 {
    background: #e8f5e9;
}

.color-box.n3 {
    background: #fce4ec;
}

.color-box.rem {
    background: #f3e5f5;
}

/* ===== KEY INSIGHT ===== */
.key-insight {
    padding: var(--space-lg);
    margin: var(--space-lg) 0;
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.05),
            rgba(114, 9, 183, 0.03));
    border-left: 4px solid var(--accent);
    border-radius: var(--radius-md);
}

.key-insight h4 {
    color: var(--text);
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.2rem;
}

.key-insight p {
    margin: 0;
    color: var(--text-light);
    line-height: 1.7;
}

/* ===== TIPS GRID ===== */
.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-md);
    margin: var(--space-lg) 0;
}

.tip-card {
    background: white;
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    box-shadow: 0 4px 15px var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.tip-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px var(--shadow-hover);
}

.tip-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    margin-bottom: var(--space-md);
}

.tip-card h3 {
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: var(--space-sm);
}

.tip-card p {
    color: var(--text-light);
    margin-bottom: var(--space-md);
    font-size: 0.95rem;
    line-height: 1.6;
    flex-grow: 1;
}

.tip-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
    margin-top: auto;
}

.tip-link:hover {
    color: var(--accent);
    gap: 0.75rem;
}

/* ===== CALCULATOR CTA ===== */
.calculator-cta {
    padding: var(--space-xl);
    text-align: center;
    margin: var(--space-xl) 0;
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.08),
            rgba(114, 9, 183, 0.04));
    border-radius: var(--radius-md);
}

.cta-content h3 {
    color: var(--text);
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1.5rem;
}

.cta-content p {
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto var(--space-md);
    line-height: 1.7;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(67, 97, 238, 0.3);
}

/* ===== MYTH/TRUTH CARDS ===== */
.myth-truth-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-md);
    margin: var(--space-lg) 0;
}

.myth-card,
.truth-card {
    padding: var(--space-lg);
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.myth-card {
    background: linear-gradient(135deg,
            rgba(244, 67, 54, 0.1),
            rgba(229, 57, 53, 0.05));
    border: 2px solid rgba(244, 67, 54, 0.2);
}

.truth-card {
    background: linear-gradient(135deg,
            rgba(76, 175, 80, 0.1),
            rgba(56, 142, 60, 0.05));
    border: 2px solid rgba(76, 175, 80, 0.2);
}

.myth-header,
.truth-header {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-sm);
}

.myth-header i {
    color: #e53935;
    font-size: 1.5rem;
}

.truth-header i {
    color: #388e3c;
    font-size: 1.5rem;
}

.myth-header h4,
.truth-header h4 {
    margin: 0;
    font-size: 1.2rem;
    /*color: var(--text);*/
}

.myth-card p,
.truth-card p {
    margin: 0;
    color: var(--text-light);
    line-height: 1.6;
}

/* ===== RESOURCES GRID ===== */
.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-md);
    margin: var(--space-lg) 0;
}

.resource-card {
    background: white;
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    box-shadow: 0 4px 15px var(--shadow);
    text-align: center;
    transition: var(--transition);
    border: 2px solid transparent;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.resource-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
    box-shadow: 0 8px 25px var(--shadow-hover);
}

.resource-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    margin: 0 auto var(--space-md);
}

.resource-card h3 {
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: var(--space-sm);
}

.resource-card p {
    color: var(--text-light);
    margin-bottom: var(--space-md);
    font-size: 0.95rem;
    line-height: 1.6;
    flex-grow: 1;
}

.resource-link {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--primary);
    color: white;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    margin-top: auto;
}

.resource-link:hover {
    background: var(--accent);
    transform: translateY(-2px);
}

/* ===== AUTHOR BIO ===== */
.author-bio {
    display: flex;
    gap: var(--space-lg);
    padding: var(--space-lg);
    margin: var(--space-xl) 0;
    align-items: flex-start;
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.05),
            rgba(114, 9, 183, 0.03));
    border-radius: var(--radius-md);
}

.author-image {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
    flex-shrink: 0;
}

.author-details h3 {
    color: var(--text);
    margin-bottom: var(--space-sm);
    font-size: 1.4rem;
}

.author-name {
    font-weight: 600;
    color: var(--primary);
    margin-bottom: var(--space-sm);
    display: block;
}

.author-details p {
    color: var(--text-light);
    margin-bottom: var(--space-md);
    line-height: 1.7;
}

.author-credentials {
    display: flex;
    gap: var(--space-sm);
    flex-wrap: wrap;
}

.credential {
    background: rgba(67, 97, 238, 0.1);
    color: var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* ===== SHARE ARTICLE ===== */
.share-article {
    text-align: center;
    padding: var(--space-lg);
    margin: var(--space-xl) 0;
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.05),
            rgba(114, 9, 183, 0.03));
    border-radius: var(--radius-md);
}

.share-article h3 {
    color: var(--text);
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.share-article p {
    color: var(--text-light);
    margin-bottom: var(--space-md);
}

.share-buttons {
    display: flex;
    justify-content: center;
    gap: var(--space-sm);
    flex-wrap: wrap;
}

.share-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
    min-width: 140px;
    justify-content: center;
}

.share-btn.facebook {
    background: #1877f2;
    color: white;
}

.share-btn.twitter {
    background: #1da1f2;
    color: white;
}

.share-btn.linkedin {
    background: #0077b5;
    color: white;
}

.share-btn.copy {
    background: var(--dark);
    color: white;
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    filter: brightness(1.1);
}

/* ===== RELATED ARTICLES ===== */
.related-articles {
    margin: var(--space-2xl) 0;
}

.related-articles h3 {
    color: var(--text);
    margin-bottom: var(--space-lg);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-md);
}

.related-article {
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 4px 15px var(--shadow);
    transition: var(--transition);
    display: flex;
    height: 100%;
}

.related-article:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px var(--shadow-hover);
}

.article-image {
    width: 120px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    flex-shrink: 0;
}

.article-content {
    padding: var(--space-md);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.article-content h4 {
    /*margin: 0 0 var(--space-sm) 0;*/
    font-size: 1.1rem;
}

.article-content h4 a {
    color: var(--text);
    text-decoration: none;
    transition: var(--transition);
}

.article-content h4 a:hover {
    color: var(--primary);
}

.article-content p {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: var(--space-sm);
    flex-grow: 1;
}

.read-time {
    font-size: 0.8rem;
    color: var(--primary);
    font-weight: 600;
    margin-top: auto;
}

/* ===== COMMENTS SECTION ===== */
.comments-section {
    padding: var(--space-lg);
    margin: var(--space-xl) 0;
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.05),
            rgba(114, 9, 183, 0.03));
    border-radius: var(--radius-md);
}

.comments-section h3 {
    color: var(--text);
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.comments-section>p {
    color: var(--text-light);
    margin-bottom: var(--space-md);
}

.comment-form {
    margin-bottom: var(--space-lg);
}

.comment-form textarea {
    width: 100%;
    padding: var(--space-md);
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    min-height: 120px;
    transition: var(--transition);
}

.comment-form textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.form-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: var(--space-sm);
}

.char-count {
    color: var(--text-lighter);
    font-size: 0.9rem;
}

.submit-comment {
    padding: 0.75rem 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.submit-comment:hover {
    background: var(--accent);
    transform: translateY(-2px);
}

.comments-list {
    margin-top: var(--space-lg);
}

.comment {
    padding: var(--space-md);
    border-bottom: 1px solid var(--border);
}

.comment:last-child {
    border-bottom: none;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-sm);
    flex-wrap: wrap;
    gap: var(--space-sm);
}

.comment-author {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--text);
}

.comment-author i {
    font-size: 1.5rem;
    /*color: var(--text-lighter);*/
}

.comment-date {
    font-size: 0.85rem;
    color: var(--text-lighter);
}

.comment-body p {
    margin: 0;
    color: var(--text-light);
    line-height: 1.6;
}

/* ===== NEWSLETTER SECTION ===== */
.newsletter-section {
    padding: var(--space-2xl) 0;
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.1),
            rgba(76, 201, 240, 0.05));
}

.newsletter-content {
    display: flex;
    align-items: center;
    gap: var(--space-xl);
    padding: var(--space-xl);
    max-width: 900px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.newsletter-icon {
    font-size: 3rem;
    color: var(--primary);
    flex-shrink: 0;
}

.newsletter-text {
    flex: 1;
    min-width: 300px;
}

.newsletter-text h3 {
    color: var(--text);
    margin-bottom: var(--space-sm);
    font-size: 1.5rem;
}

.newsletter-text p {
    color: var(--text-light);
    margin: 0;
    line-height: 1.6;
}

.newsletter-form {
    display: flex;
    gap: var(--space-sm);
    flex-shrink: 0;
    min-width: 500px;
    width: 100%;
}

.newsletter-form input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: 2px solid var(--border);
    border-radius: 50px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--primary);
}

.newsletter-form button {
    padding: 1rem 2rem;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.newsletter-form button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(67, 97, 238, 0.3);
}

/* ===== BACK TO TOP ===== */
.article-back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(67, 97, 238, 0.3);
}

.article-back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.article-back-to-top:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 6px 20px rgba(67, 97, 238, 0.4);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1200px) {
    .content-wrapper {
        grid-template-columns: 250px 1fr;
        gap: var(--space-lg);
    }
}

@media (max-width: 992px) {
    .content-wrapper {
        grid-template-columns: 1fr;
    }

    .table-of-contents {
        position: static;
        max-height: none;
        margin-bottom: var(--space-lg);
    }

    .toc-toggle {
        display: block;
    }

    .toc-nav {
        display: none;
    }

    .toc-nav.active {
        display: block;
        max-height: 300px;
        overflow-y: auto;
    }

    .article-title {
        font-size: 2.5rem;
    }

    .newsletter-content {
        flex-direction: column;
        text-align: center;
        gap: var(--space-lg);
    }

    .newsletter-form {
        width: 100%;
    }

    .newsletter-form input,
    .newsletter-form button {
        width: 30%;
    }
}

@media (max-width: 768px) {
    .article-title {
        font-size: 2rem;
    }

    .article-section h2 {
        font-size: 1.6rem;
    }

    .article-section h3 {
        font-size: 1.3rem;
    }

    .article-meta {
        flex-direction: column;
        align-items: flex-start;
    }

    .article-summary {
        flex-direction: column;
        gap: var(--space-md);
    }

    .author-bio {
        flex-direction: column;
        text-align: center;
        align-items: center;
        gap: var(--space-md);
    }

    .author-image {
        width: 80px;
        height: 80px;
        font-size: 2rem;
    }

    .related-article {
        flex-direction: column;
    }

    .article-image {
        width: 100%;
        height: 120px;
    }

    .cycle-timeline {
        flex-direction: column;
        height: auto;
        min-height: auto;
    }

    .timeline-bar {
        height: 60px;
        width: 100% !important;
        flex-direction: row;
        justify-content: space-between;
        padding: 0 var(--space-md);
    }

    .cycle-marker {
        position: static;
        transform: none;
        margin-top: 0.5rem;
        align-self: center;
    }

    .share-buttons {
        flex-direction: column;
    }

    .share-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .article-title {
        font-size: 1.8rem;
    }

    .article-section h2 {
        font-size: 1.4rem;
    }

    .article-section h3 {
        font-size: 1.2rem;
    }

    .sleep-stages-visual,
    .tips-grid,
    .resources-grid,
    .articles-grid,
    .myth-truth-container {
        grid-template-columns: 1fr;
    }

    .info-box {
        flex-direction: column;
        gap: var(--space-sm);
        text-align: center;
    }

    .article-back-to-top {
        bottom: 1rem;
        right: 1rem;
        width: 45px;
        height: 45px;
    }
}

/* ===== DARK MODE ===== */
.dark-mode .article-main {
    background: var(--dark);
}

.dark-mode .glass-effect {
    background: rgba(30, 30, 46, 0.95);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.dark-mode .article-hero {
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.15),
            rgba(114, 9, 183, 0.1));
}

.dark-mode .article-title,
.dark-mode .article-section h2,
.dark-mode .article-section h3,
.dark-mode .comparison-table h3,
.dark-mode .key-insight h4,
.dark-mode .tip-card h3,
.dark-mode .resource-card h3,
.dark-mode .author-details h3,
.dark-mode .share-article h3,
.dark-mode .related-articles h3,
.dark-mode .comments-section h3,
.dark-mode .newsletter-text h3 {
    color: #e2e8f0;
}

.dark-mode .article-section p,
.dark-mode .article-section strong,
.dark-mode .summary-content li,
.dark-mode .info-content p,
.dark-mode .comparison-table td,
.dark-mode .key-insight p,
.dark-mode .tip-card p,
.dark-mode .cta-content p,
.dark-mode .myth-card p,
.dark-mode .truth-card p,
.dark-mode .resource-card p,
.dark-mode .author-details p,
.dark-mode .share-article p,
.dark-mode .article-content p,
.dark-mode .comment-body p,
.dark-mode .newsletter-text p {
    color: #cbd5e0;
}

.dark-mode .breadcrumb [aria-current="page"],
.dark-mode .author-name {
    color: #cbd5e0;
}

.dark-mode .stage-card,
.dark-mode .comparison-table table,
.dark-mode .tip-card,
.dark-mode .resource-card,
.dark-mode .related-article {
    background: rgba(26, 32, 44, 0.9);
    border-color: rgba(255, 255, 255, 0.1);
}

.dark-mode .comparison-table thead {
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.9),
            rgba(58, 12, 163, 0.9));
}

.dark-mode .comment-form textarea {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
}

.dark-mode .article-content h4 a {
    color: #e2e8f0;
}

.dark-mode .article-content h4 a:hover {
    color: var(--primary);
}

.dark-mode .article-summary,
.dark-mode .key-insight,
.dark-mode .calculator-cta,
.dark-mode .author-bio,
.dark-mode .share-article,
.dark-mode .comments-section {
    background: linear-gradient(135deg,
            rgba(67, 97, 238, 0.15),
            rgba(114, 9, 183, 0.1));
}

.dark-mode .border {
    border-color: rgba(255, 255, 255, 0.1) !important;
}


/* Calculator Guide Specific Styles */

/* Feature Comparison */
.feature-comparison {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

.comparison-card {
    background: white;
    border-radius: var(--article-border-radius);
    padding: 25px;
    box-shadow: var(--article-shadow);
    transition: var(--article-transition);
}

.dark-mode .comparison-card {
    background: rgba(26, 32, 44, 0.9);
    border-radius: 10px;
}

.comparison-card.old-way {
    border-top: 5px solid #ef4444;
}

.comparison-card.new-way {
    border-top: 5px solid #10b981;
}

.comparison-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.comparison-header i {
    font-size: 1.8rem;
}

.comparison-card.old-way .comparison-header i {
    color: #ef4444;
}

.comparison-card.new-way .comparison-header i {
    color: #10b981;
}

.comparison-header h3 {
    margin: 0;
    font-size: 1.3rem;
}

.comparison-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.comparison-card li {
    padding: 10px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    position: relative;
    padding-left: 25px;
}

.dark-mode .comparison-card li {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.comparison-card li:before {
    position: absolute;
    left: 0;
}

.comparison-card.old-way li:before {
    content: "✗";
    color: #ef4444;
}

.comparison-card.new-way li:before {
    content: "✓";
    color: #10b981;
}

/* Cycle Breakdown */
.cycle-breakdown {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.cycle-stage {
    display: flex;
    gap: 20px;
    align-items: center;
    background: rgba(255, 255, 255, 0.9);
    padding: 20px;
    border-radius: 10px;
    transition: var(--article-transition);
}

.dark-mode .cycle-stage {
    background: rgba(255, 255, 255, 0.05);
}

.cycle-stage:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.stage-visual {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
    transition: var(--article-transition);
}

.stage-1 {
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
    color: #1565c0;
}

.stage-2 {
    background: linear-gradient(135deg, #e8f5e9, #c8e6c9);
    color: #2e7d32;
}

.stage-3 {
    background: linear-gradient(135deg, #fce4ec, #f8bbd9);
    color: #c2185b;
}

.stage-rem {
    background: linear-gradient(135deg, #f3e5f5, #e1bee7);
    color: #7b1fa2;
}

.stage-info h4 {
    margin: 0 0 5px 0;
    font-size: 1.1rem;
}

.stage-info p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--article-gray);
}

/* Math Explanation */
.math-explanation {
    background: rgba(67, 97, 238, 0.05);
    border-radius: var(--article-border-radius);
    padding: 30px;
    margin: 40px 0;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.math-explanation h3 {
    color: var(--article-dark);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.math-example {
    margin-bottom: 25px;
}

.math-example p {
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--article-dark);
}

.calculation {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 10px;
    padding: 15px;
    background: white;
    border-radius: 10px;
}

.dark-mode .calculation {
    background: rgba(26, 32, 44, 0.9);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.calc-step {
    padding: 8px 15px;
    background: rgba(67, 97, 238, 0.1);
    border-radius: 6px;
    font-weight: 600;
}

.calc-operator {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--article-primary);
}

.calc-result {
    padding: 8px 15px;
    background: linear-gradient(135deg, var(--article-primary), var(--article-accent));
    color: white;
    border-radius: 6px;
    font-weight: 600;
}

.calc-note {
    font-size: 0.9rem;
    color: var(--article-gray);
    text-align: center;
    font-style: italic;
}

.option-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.sleep-option {
    background: white;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    border: 2px solid transparent;
    transition: var(--article-transition);
}

.dark-mode .sleep-option {
    background: rgba(26, 32, 44, 0.9);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.sleep-option.recommended {
    border-color: var(--article-primary);
    background: rgba(67, 97, 238, 0.05);
    transform: scale(1.05);
}

.cycles {
    display: block;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--article-primary);
    margin-bottom: 5px;
}

.time {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--article-dark);
    margin-bottom: 5px;
}

.note {
    display: block;
    font-size: 0.85rem;
    color: var(--article-gray);
}

/* Step by Step */
.step-by-step {
    counter-reset: step-counter;
    margin: 40px 0;
    padding: 0 50px 0 0;
    border-radius: 10px;
    border: 1px solid #6f6f6f47;
}

.step {
    display: flex;
    gap: 25px;
    margin-bottom: 40px;
    position: relative;
}

.step:not(:last-child):after {
    content: '';
    position: absolute;
    left: 35px;
    top: 70px;
    bottom: -40px;
    width: 2px;
    background: linear-gradient(to bottom, var(--article-primary), transparent);
}

.step-number {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--article-primary), var(--article-accent));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 700;
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}

.step-content {
    flex: 1;
}

.step-content h3 {
    color: var(--article-dark);
    margin-bottom: 15px;
    font-size: 1.4rem;
}

.mode-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.mode-option {
    background: white;
    border-radius: 10px;
    padding: 20px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    transition: var(--article-transition);
}

.dark-mode .mode-option {
    background: rgba(26, 32, 44, 0.9);
    border-color: rgba(255, 255, 255, 0.1);
}

.mode-option:hover {
    border-color: var(--article-primary);
    transform: translateY(-3px);
}

.mode-option i {
    font-size: 2rem;
    color: var(--article-primary);
    margin-bottom: 15px;
    display: block;
}

.mode-tip {
    display: block;
    margin-top: 10px;
    font-size: 0.85rem;
    color: var(--article-gray);
    font-style: italic;
}

.age-tips {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.age-tip {
    background: white;
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.dark-mode .age-tip {
    background: rgba(26, 32, 44, 0.9);
    border-color: rgba(255, 255, 255, 0.1);
}

.age-range {
    display: block;
    font-weight: 700;
    color: var(--article-dark);
    margin-bottom: 5px;
}

.hours {
    display: block;
    color: var(--article-primary);
    font-weight: 600;
    margin-bottom: 3px;
}

.cycles {
    display: block;
    font-size: 0.85rem;
    color: var(--article-gray);
}

.time-presets {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin: 15px 0;
}

.preset-btn {
    padding: 10px 20px;
    background: rgba(67, 97, 238, 0.1);
    border: 2px solid rgba(67, 97, 238, 0.2);
    border-radius: 25px;
    color: var(--article-primary);
    font-weight: 600;
    cursor: pointer;
    transition: var(--article-transition);
}

.preset-btn:hover {
    background: var(--article-primary);
    color: white;
    transform: translateY(-2px);
}

.cycle-recommendations {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.cycle-rec {
    background: white;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    border: 2px solid transparent;
    transition: var(--article-transition);
}

.dark-mode .cycle-rec {
    background: rgba(26, 32, 44, 0.9);
}

.cycle-rec.recommended {
    border-color: var(--article-primary);
    background: rgba(67, 97, 238, 0.05);
    transform: scale(1.05);
}

.cycle-count {
    display: block;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--article-primary);
    margin-bottom: 5px;
}

.duration {
    display: block;
    color: var(--article-dark);
    margin-bottom: 5px;
}

.rec-label {
    display: block;
    font-size: 0.85rem;
    color: var(--article-gray);
}

.tip {
    background: rgba(255, 193, 7, 0.1);
    border-left: 4px solid #ffc107;
    padding: 15px;
    border-radius: 0 8px 8px 0;
    margin: 20px 0;
}

.tip i {
    color: #ffc107;
    margin-right: 10px;
}

.result-preview {
    max-width: 400px;
    margin: 20px auto;
}

.result-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    border: 2px solid var(--article-primary);
    box-shadow: 0 5px 20px rgba(67, 97, 238, 0.15);
}

.dark-mode .result-card {
    background: rgba(26, 32, 44, 0.9);
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.quality.excellent {
    background: rgba(76, 175, 80, 0.2);
    color: #388e3c;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.result-time {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--article-dark);
    text-align: center;
    margin-bottom: 15px;
}

.result-details {
    display: flex;
    justify-content: center;
    gap: 15px;
    color: var(--article-gray);
    font-size: 0.9rem;
}

/* Case Studies */
.case-studies {
    display: grid;
    gap: 30px;
    margin: 40px 0;
}

.case-study {
    background: white;
    border-radius: var(--article-border-radius);
    overflow: hidden;
    box-shadow: var(--article-shadow);
    transition: var(--article-transition);
}

.dark-mode .case-study {
    background: rgba(26, 32, 44, 0.9);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.case-study:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.case-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 25px;
    background: linear-gradient(135deg, rgba(67, 97, 238, 0.1), rgba(76, 201, 240, 0.05));
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.dark-mode .case-header {
    background: linear-gradient(135deg, rgba(67, 97, 238, 0.2), rgba(76, 201, 240, 0.1));
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.case-avatar {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--article-primary), var(--article-accent));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.case-info h3 {
    margin: 0 0 5px 0;
    font-size: 1.3rem;
}

.case-role {
    color: var(--article-gray);
    font-size: 0.9rem;
}

.case-content {
    padding: 25px;
}

.case-content p {
    margin-bottom: 15px;
}

.case-calculation {
    background: rgba(67, 97, 238, 0.05);
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
}

.dark-mode .case-calculation {
    background: rgba(67, 97, 238, 0.1);
}

.input-group,
.result-group {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.dark-mode .input-group,
.dark-mode .result-group {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.label {
    font-weight: 600;
    color: var(--article-dark);
}

.value {
    color: var(--article-gray);
}

.value.highlight {
    color: var(--article-primary);
    font-weight: 600;
}

.value.result {
    color: var(--article-accent);
    font-weight: 700;
    font-size: 1.1rem;
}

/* Mistakes Grid */
.mistakes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

.mistake-card {
    background: white;
    border-radius: var(--article-border-radius);
    padding: 25px;
    box-shadow: var(--article-shadow);
    border-top: 5px solid #ef4444;
    transition: var(--article-transition);
    cursor: pointer;
}

.dark-mode .mistake-card {
    background: rgba(26, 32, 44, 0.9);
    border-radius: 10px;
}

.mistake-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.mistake-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.mistake-header i {
    color: #ef4444;
    font-size: 1.5rem;
}

.mistake-header h3 {
    margin: 0;
    font-size: 1.2rem;
    color: var(--article-dark);
}

.mistake-card p {
    color: var(--article-gray);
    margin-bottom: 15px;
    line-height: 1.6;
}

.correction {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    background: rgba(76, 175, 80, 0.1);
    border-radius: 8px;
    border-left: 4px solid #388e3c;
}

.correction i {
    color: #388e3c;
}

.pro-tip {
    display: flex;
    gap: 20px;
    padding: 25px;
    margin: 40px 0;
    border-left: 5px solid #ffc107;
}

.tip-icon {
    font-size: 2rem;
    color: #ffc107;
    flex-shrink: 0;
}

.tip-content h4 {
    color: var(--primary);
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.tip-content p {
    margin: 0;
    color: var(--article-gray);
    line-height: 1.7;
}

/* Advanced Tips */
.advanced-tips {
    display: grid;
    gap: 25px;
    margin: 30px 0;
}

.advanced-tip {
    display: flex;
    gap: 25px;
    background: white;
    border-radius: var(--article-border-radius);
    padding: 25px;
    box-shadow: var(--article-shadow);
    transition: var(--article-transition);
}

.dark-mode .advanced-tip {
    background: rgba(26, 32, 44, 0.9);
    border-radius: 10px;
}

.advanced-tip:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.tip-visual {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--article-primary), var(--article-accent));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    flex-shrink: 0;
    cursor: pointer;
    transition: var(--article-transition);
}

.tip-visual:hover {
    transform: rotate(15deg) scale(1.1);
}

.tip-content h3 {
    color: var(--article-dark);
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.tip-content p {
    color: var(--article-gray);
    margin-bottom: 15px;
    line-height: 1.6;
}

.tip-example,
.tip-math,
.tip-schedule {
    background: rgba(67, 97, 238, 0.05);
    border-radius: 8px;
    padding: 15px;
    margin-top: 10px;
    font-size: 0.95rem;
}

.dark-mode .tip-example,
.dark-mode .tip-math,
.dark-mode .tip-schedule {
    background: rgba(67, 97, 238, 0.1);
}

.phase {
    display: inline-block;
    background: white;
    padding: 5px 10px;
    border-radius: 4px;
    margin: 0 5px;
    font-weight: 600;
}

.dark-mode .phase {
    background: rgba(255, 255, 255, 0.1);
}

.math-item,
.schedule-item {
    display: block;
    margin-bottom: 8px;
}

.math-item:last-child,
.schedule-item:last-child {
    margin-bottom: 0;
}

.productivity-hack {
    padding: 30px;
    margin: 40px 0;
    background: linear-gradient(135deg, rgba(114, 9, 183, 0.1), rgba(67, 97, 238, 0.05));
    border-radius: var(--article-border-radius);
    border-left: 5px solid var(--article-accent);
}

.productivity-hack h3 {
    color: var(--article-dark);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.productivity-hack p {
    color: var(--article-gray);
    margin-bottom: 25px;
    line-height: 1.7;
}

.hack-schedule {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.work-block,
.break-block {
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    min-width: 120px;
    transition: var(--article-transition);
}

.work-block {
    background: linear-gradient(135deg, var(--article-primary), var(--article-accent));
    color: white;
}

.break-block {
    background: rgba(255, 193, 7, 0.2);
    color: #ff8f00;
}

.block-label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
}

.block-time {
    display: block;
    font-size: 1.2rem;
    font-weight: 700;
}

/* Calculator Demo */
.calculator-demo {
    background: linear-gradient(135deg, rgba(67, 97, 238, 0.05), rgba(76, 201, 240, 0.03));
    border-radius: 20px;
    padding: 40px;
    margin: 50px 0;
}

.demo-intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 30px;
    color: var(--article-gray);
    font-size: 1.1rem;
}

.demo-calculator {
    max-width: 800px;
    margin: 0 auto;
}

.demo-header {
    text-align: center;
    margin-bottom: 30px;
}

.demo-header h3 {
    color: var(--article-dark);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.demo-header p {
    color: var(--article-gray);
    margin: 0;
}

.demo-controls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.control-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.control-group label {
    font-weight: 600;
    color: var(--article-dark);
    display: flex;
    align-items: center;
    gap: 8px;
}

.demo-select,
.demo-input {
    padding: 15px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--article-transition);
}

.dark-mode .demo-select,
.dark-mode .demo-input {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.demo-select:focus,
.demo-input:focus {
    outline: none;
    border-color: var(--article-primary);
}

.cycle-control {
    display: flex;
    align-items: center;
    gap: 15px;
}

.cycle-btn {
    width: 40px;
    height: 40px;
    background: var(--article-primary);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--article-transition);
}

.cycle-btn:hover {
    background: var(--article-accent);
    transform: scale(1.1);
}

#demo-cycle-count {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--article-primary);
    min-width: 100px;
    text-align: center;
}

.demo-slider {
    width: 100%;
    height: 8px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    margin-top: 10px;
}

.dark-mode .demo-slider {
    background: rgba(255, 255, 255, 0.1);
}

.demo-slider::-webkit-slider-thumb {
    width: 24px;
    height: 24px;
    background: var(--article-primary);
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid white;
}

.demo-calculate-btn {
    width: 100%;
    padding: 20px;
    background: linear-gradient(135deg, var(--article-primary), var(--article-accent));
    color: white;
    border: none;
    border-radius: 15px;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--article-transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
}

.demo-calculate-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(67, 97, 238, 0.3);
}

.demo-results {
    animation: fadeIn 0.5s ease;
}

.demo-results h4 {
    color: var(--article-dark);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.result-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    border: 2px solid transparent;
    transition: var(--article-transition);
}

.dark-mode .result-card {
    background: rgba(26, 32, 44, 0.9);
}

.result-card.best {
    border-color: var(--article-primary);
    background: rgba(67, 97, 238, 0.05);
    transform: scale(1.05);
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.cycles {
    font-weight: 700;
    color: var(--article-primary);
}

.hours {
    color: var(--article-gray);
    font-size: 0.9rem;
}

.time-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.time-block {
    text-align: center;
}

.time-block .label {
    display: block;
    font-size: 0.85rem;
    color: var(--article-gray);
    margin-bottom: 5px;
}

.time-block .time {
    display: block;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--article-dark);
}

.recommended-badge {
    text-align: center;
    padding: 8px;
    background: rgba(255, 193, 7, 0.2);
    color: #ff8f00;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.demo-best-result {
    background: linear-gradient(135deg, var(--article-primary), var(--article-accent));
    color: white;
    border-radius: 15px;
    padding: 25px;
    text-align: center;
}

.best-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    font-size: 1.2rem;
    font-weight: 600;
}

.best-times {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 15px;
    font-size: 2rem;
    font-weight: 700;
}

.best-duration {
    font-size: 1.1rem;
    opacity: 0.9;
}

.demo-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 30px;
    padding: 15px;
    background: rgba(255, 193, 7, 0.1);
    border-radius: 10px;
}

.demo-note i {
    color: #ffc107;
    font-size: 1.2rem;
    flex-shrink: 0;
    margin-top: 2px;
}

.demo-note p {
    margin: 0;
    color: var(--article-gray);
    font-size: 0.95rem;
}

.demo-note a {
    color: var(--article-primary);
    font-weight: 600;
    text-decoration: none;
}

.demo-note a:hover {
    text-decoration: underline;
}

.action-cta {
    text-align: center;
    margin-top: 40px;
}

.cta-button.large {
    display: inline-flex;
    align-items: center;
    gap: 15px;
    padding: 20px 40px;
    /*background: linear-gradient(135deg, var(--article-primary), var(--article-accent));*/
    color: white;
    border-radius: 50px;
    text-decoration: none;
    font-size: 1.2rem;
    font-weight: 700;
    transition: var(--article-transition);
}

.cta-button.large:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(67, 97, 238, 0.4);
}

.cta-subtext {
    margin-top: 15px;
    color: var(--article-gray);
    font-size: 0.95rem;
}

/* FAQ Quick Section */
.faq-quick {
    margin: 50px auto;
    max-width: 800px;
}

.faq-quick h3 {
    text-align: center;
    margin-bottom: 30px;
    color: var(--article-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.faq-items {
    display: grid;
    gap: 15px;
}

.faq-item {
    background: white;
    border-radius: var(--article-border-radius);
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.dark-mode .faq-item {
    background: rgba(26, 32, 44, 0.9);
    border-color: rgba(255, 255, 255, 0.1);
}

.faq-question {
    width: 100%;
    padding: 20px;
    background: rgba(67, 97, 238, 0.05);
    border: none;
    color: var(--article-dark);
    text-align: left;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 600;
}

.dark-mode .faq-question {
    background: rgba(67, 97, 238, 0.1);
    color: white;
}

.faq-question i {
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-item.active .faq-answer {
    padding: 20px;
    max-height: 200px;
}

.faq-answer p {
    margin: 0;
    color: var(--article-gray);
    line-height: 1.6;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 768px) {

    .feature-comparison,
    .mode-options,
    .option-grid,
    .cycle-recommendations,
    .results-grid {
        grid-template-columns: 1fr;
    }

    .cycle-breakdown {
        grid-template-columns: 1fr;
    }

    .step {
        flex-direction: column;
        gap: 15px;
    }

    .step:not(:last-child):after {
        left: 50%;
        top: 70px;
        bottom: -40px;
        transform: translateX(-50%);
        height: calc(100% + 40px);
        width: 2px;
    }

    .step-number {
        align-self: center;
    }

    .advanced-tip {
        flex-direction: column;
        text-align: center;
    }

    .tip-visual {
        align-self: center;
    }

    .calculator-demo {
        padding: 20px;
    }

    .demo-controls {
        grid-template-columns: 1fr;
    }

    .best-times {
        flex-direction: column;
        gap: 10px;
    }

    .cta-button.large {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {

    .age-tips,
    .mistakes-grid {
        grid-template-columns: 1fr;
    }

    .hack-schedule {
        flex-direction: column;
        align-items: center;
    }

    .work-block,
    .break-block {
        width: 100%;
        max-width: 200px;
    }

    .time-presets {
        justify-content: center;
    }

    .case-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
}