:root {
    /* Color Palette - Light Mode */
    --bg-primary: #fdfaf6; /* Parchment-like */
    --bg-secondary: #ffffff;
    --text-primary: #1a1a1a;
    --text-secondary: #4a4a4a;
    --accent-primary: #c43e1c; /* Deep Terracotta */
    --accent-secondary: #8b2d15;
    --border-color: rgba(0, 0, 0, 0.1);
    --glass-bg: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(255, 255, 255, 0.2);
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    
    /* Fonts */
    --font-heading: 'Amiri', serif;
    --font-body: 'Tajawal', sans-serif;
    
    /* Spacing */
    --container-width: 1200px;
    --nav-height: 80px;
}

[data-theme="dark"] {
    --bg-primary: #0f1115; /* Charcoal */
    --bg-secondary: #1a1d23;
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --accent-primary: #e65b39;
    --accent-secondary: #f07b5d;
    --border-color: rgba(255, 255, 255, 0.1);
    --glass-bg: rgba(15, 17, 21, 0.8);
    --glass-border: rgba(255, 255, 255, 0.05);
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

/* Header */
#main-header {
    height: var(--nav-height);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
}

#main-header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-icon {
    font-size: 1.8rem;
    color: var(--accent-primary);
}

.logo h1 {
    font-size: 1.8rem;
    letter-spacing: -1px;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a:hover {
    color: var(--accent-primary);
}

.actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

#theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
}

#theme-toggle:hover {
    transform: rotate(15deg);
}

.login-link {
    font-weight: 500;
    font-size: 0.95rem;
}

.login-link:hover {
    color: var(--accent-primary);
}

/* Buttons */
.btn {
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-family: var(--font-body);
}

.btn-primary {
    background-color: var(--accent-primary);
    color: white;
}

.btn-primary:hover {
    background-color: var(--accent-secondary);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(196, 62, 28, 0.3);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--accent-primary);
    color: var(--accent-primary);
}

.btn-outline:hover {
    background-color: var(--accent-primary);
    color: white;
}

.btn-lg {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
}

/* Sections Global */
section {
    padding: 8rem 0;
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s ease;
}

section.fade-in {
    opacity: 1;
    transform: translateY(0);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 3rem;
}

.view-all {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--accent-primary);
    font-weight: 500;
}

/* Hero Section Styles */
#hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: var(--nav-height);
    background: radial-gradient(circle at 10% 20%, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    overflow: hidden;
}

.hero-container {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-title {
    font-size: 5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.4rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 600px;
}

.hero-btns {
    display: flex;
    gap: 1.5rem;
}

.hero-image {
    position: relative;
    height: 600px;
}

.hero-blob {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: url('../images/hero-bg.png');
    background-size: cover;
    background-position: center;
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    animation: blobMorph 20s linear infinite alternate;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
}

@keyframes blobMorph {
    0% { border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%; }
    25% { border-radius: 58% 42% 75% 25% / 76% 46% 54% 24%; }
    50% { border-radius: 50% 50% 33% 67% / 55% 27% 73% 45%; }
    75% { border-radius: 33% 67% 58% 42% / 63% 68% 32% 37%; }
    100% { border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%; }
}

/* Featured Stories Section Styles */
.stories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
}

.story-card {
    background: var(--bg-secondary);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease;
    border: 1px solid var(--border-color);
}

.story-card:hover {
    transform: translateY(-10px);
}

.story-image {
    height: 240px;
    background-size: cover;
    background-position: center;
}

.story-body {
    padding: 2rem;
}

.category-tag {
    background: rgba(196, 62, 28, 0.1);
    color: var(--accent-primary);
    padding: 0.3rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    display: inline-block;
    margin-bottom: 1rem;
}

.story-card h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.story-card p {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.story-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

.author {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.author img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.author span {
    font-size: 0.9rem;
    font-weight: 500;
}

.read-time {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Categories Section Styles */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.category-item {
    background: var(--bg-secondary);
    padding: 3rem 2rem;
    border-radius: 24px;
    text-align: center;
    border: 1px solid var(--border-color);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
}

.category-item:hover {
    transform: translateY(-12px);
    background: var(--accent-primary);
    border-color: var(--accent-primary);
}

.category-item:hover * {
    color: white !important;
}

.category-icon {
    width: 60px;
    height: 60px;
    background: rgba(196, 62, 28, 0.1);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: var(--accent-primary);
    transition: all 0.3s ease;
}

.category-item h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.category-item p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Top Writers Section Styles */
.writers-scroll {
    display: flex;
    gap: 2rem;
    overflow-x: auto;
    padding: 1rem 0 3rem;
    scrollbar-width: none; /* Hide scrollbar Firefox */
}

.writers-scroll::-webkit-scrollbar {
    display: none; /* Hide scrollbar Chrome/Safari */
}

.writer-card {
    min-width: 280px;
    background: var(--bg-secondary);
    padding: 3rem 2rem;
    border-radius: 30px;
    text-align: center;
    box-shadow: var(--card-shadow);
    border: 1px solid var(--border-color);
    position: relative;
    transition: all 0.3s ease;
}

.writer-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.writer-avatar {
    position: relative;
    width: 100px;
    height: 100px;
    margin: 0 auto 1.5rem;
}

.writer-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--bg-primary);
}

.badge {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #666;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
    border: 2px solid var(--bg-secondary);
}

.badge.gold { background: #ffd700; color: #000; }
.badge.silver { background: #c0c0c0; color: #000; }
.badge.bronze { background: #cd7f32; color: #fff; }

.writer-card h3 {
    font-size: 1.4rem;
    margin-bottom: 0.3rem;
}

.writer-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.writer-stats {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

.writer-stats span {
    font-size: 0.85rem;
}

.writer-stats b {
    display: block;
    font-size: 1.1rem;
    color: var(--accent-primary);
}

/* Start Writing CTA Section Styles */
.cta-banner {
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    color: white;
    text-align: center;
    border-radius: 40px;
    margin: 4rem 2rem;
    padding: 6rem 2rem;
}

.cta-content h2 {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}

.cta-content p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 2.5rem;
    max-width: 700px;
    margin-inline: auto;
}

.cta-banner .btn-primary {
    background: white;
    color: var(--accent-primary);
}

.cta-banner .btn-primary:hover {
    background: #f3f4f6;
    color: var(--accent-secondary);
}

/* Testimonials Section Styles */
.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
}

.testimonial-card {
    background: var(--bg-secondary);
    padding: 3rem;
    border-radius: 30px;
    box-shadow: var(--card-shadow);
    border: 1px solid var(--border-color);
    position: relative;
}

.quote-icon {
    font-size: 5rem;
    color: var(--accent-primary);
    opacity: 0.1;
    position: absolute;
    top: 1rem;
    right: 2rem;
    line-height: 1;
}

.testimonial-card p {
    font-size: 1.2rem;
    font-style: italic;
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-info img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.user-info h4 {
    font-size: 1.1rem;
    margin-bottom: 0.2rem;
}

.user-info span {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* App Preview Section Styles */
.app-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    background: var(--bg-secondary);
    padding: 4rem;
    border-radius: 40px;
    border: 1px solid var(--border-color);
}

.tag {
    background: rgba(196, 62, 28, 0.1);
    color: var(--accent-primary);
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    display: inline-block;
}

.app-text h2 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
}

.app-text p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
}

.app-btns {
    display: flex;
    gap: 1rem;
}

.btn-dark {
    background: #000;
    color: white;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.app-visual {
    position: relative;
}

.app-mockup {
    width: 100%;
    border-radius: 20px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.2);
}

/* Newsletter Section Styles */
.newsletter-box {
    background: var(--accent-primary);
    background-image: radial-gradient(circle at 90% 10%, rgba(255,255,255,0.1) 0%, transparent 40%);
    color: white;
    padding: 6rem 4rem;
    border-radius: 40px;
    text-align: center;
}

.newsletter-box h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.newsletter-box p {
    margin-bottom: 3rem;
    opacity: 0.9;
    font-size: 1.1rem;
}

.newsletter-form {
    display: flex;
    gap: 1rem;
    max-width: 600px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 1rem 1.5rem;
    border-radius: 50px;
    border: none;
    font-family: var(--font-body);
    font-size: 1rem;
}

/* Footer Styles */
#main-footer {
    background: var(--bg-secondary);
    padding: 6rem 0 2rem;
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-about p {
    margin: 1.5rem 0 2rem;
    color: var(--text-secondary);
    max-width: 300px;
}

.social-links {
    display: flex;
    gap: 1.2rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: var(--bg-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: var(--accent-primary);
    color: white;
    transform: translateY(-3px);
}

.footer-links h4 {
    font-size: 1.4rem;
    margin-bottom: 2rem;
}

.footer-links ul li {
    margin-bottom: 1rem;
}

.footer-links a {
    color: var(--text-secondary);
}

.footer-links a:hover {
    color: var(--accent-primary);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Responsive Navigation */
#menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-primary);
    align-items: center;
    justify-content: center;
}

@media (max-width: 992px) {
    .nav-links {
        position: fixed;
        top: var(--nav-height);
        right: -100%;
        width: 100%;
        height: calc(100vh - var(--nav-height));
        background: var(--bg-secondary);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2.5rem;
        transition: 0.3s ease-in-out;
        z-index: 999;
        border-top: 1px solid var(--border-color);
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 1.5rem;
    }

    #menu-toggle {
        display: flex;
    }

    .actions .login-link, 
    .actions .btn-primary {
        display: none; /* Hide on mobile to show in menu or simplify */
    }
}

/* Tablet Adjustments */
@media (min-width: 769px) and (max-width: 1024px) {
    .stories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hero-title {
        font-size: 3.5rem;
    }
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .section-header {
        margin-bottom: 2.5rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .section-header h2 { font-size: 2rem; }
    
    .hero-title { 
        font-size: 2.8rem;
        text-align: center;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
        text-align: center;
    }

    .hero-btns {
        flex-direction: column;
        width: 100%;
    }

    .hero-btns .btn {
        width: 100%;
        text-align: center;
    }

    .hero-container, .stories-grid, .testimonials-grid, .app-container, .footer-grid {
        grid-template-columns: 1fr;
    }

    .hero-image { height: 350px; }
    
    .app-container, .newsletter-box {
        padding: 3rem 1.5rem;
    }

    .app-text h2, .newsletter-box h2 {
        font-size: 2.22rem;
    }

    .newsletter-form { flex-direction: column; }
    
    .cta-banner {
        margin: 2rem 1rem;
        padding: 4rem 1.5rem;
    }

    .cta-content h2 { font-size: 2.2rem; }
    .app-text h2 { font-size: 2.2rem; }

    .footer-grid {
        gap: 2.5rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 1s ease forwards;
}
/* Login Page Styles */
.login-body {
    height: 100vh;
    overflow: hidden;
}

.login-container {
    display: flex;
    height: 100vh;
    width: 100%;
    background: var(--bg-primary);
}

.login-visual {
    flex: 1.2;
    background:
        radial-gradient(circle at 20% 20%, rgba(196, 62, 28, 0.25), transparent 45%),
        radial-gradient(circle at 80% 70%, rgba(196, 62, 28, 0.12), transparent 50%),
        linear-gradient(135deg, #3a140b 0%, #5d2011 45%, #7a2a17 100%);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 4rem;
    color: white;
}

.login-visual::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent 50%, rgba(0,0,0,0.8) 100%);
    z-index: 1;
}

.login-visual-content {
    position: relative;
    z-index: 2;
    max-width: 500px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(6px);
    padding: 2rem;
    border-radius: 20px;
}

.login-visual-content h2 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: white;
}

.login-visual-content p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.login-form-side {
    flex: 1;
    background-color: var(--bg-secondary);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem 6rem;
    overflow-y: auto;
    position: relative;
    border-inline-start: 1px solid var(--border-color);
}

.login-header {
    margin-bottom: 3rem;
}

.auth-mode-switch {
    display: inline-flex;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 0.25rem;
    margin-top: 1.25rem;
}

.auth-mode-switch a {
    padding: 0.45rem 1rem;
    border-radius: 999px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.auth-mode-switch a.active {
    background: var(--accent-primary);
    color: #fff;
}

.login-header .logo {
    margin-bottom: 2rem;
}

.login-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.login-header p {
    color: var(--text-secondary);
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    position: relative;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.input-wrapper {
    position: relative;
}

.input-wrapper i {
    position: absolute;
    inset-inline-end: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    pointer-events: none;
    font-size: 1.2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.input-wrapper input {
    width: 100%;
    min-height: 52px;
    padding: 1rem 3rem 1rem 2.8rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(196, 62, 28, 0.1);
}

.toggle-password {
    margin-right: -30px;
    position: absolute;
    inset-inline-start: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 0;
    display: flex;
    align-items: center;
}

.form-utils {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.forgot-password {
    color: var(--accent-primary);
    font-weight: 500;
}

.login-btn {
    margin-top: 1rem;
    width: 100%;
}

.social-login {
    margin-top: 2.5rem;
    text-align: center;
}

.social-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.social-divider::before,
.social-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background-color: var(--border-color);
}

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

.btn-social {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    padding: 0.8rem;
    border-radius: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-body);
}

.btn-social:hover {
    background-color: var(--bg-secondary);
    border-color: var(--accent-primary);
    transform: translateY(-2px);
}

.login-footer {
    margin-top: 3rem;
    text-align: center;
    color: var(--text-secondary);
}

.login-footer a {
    color: var(--accent-primary);
    font-weight: 700;
}

.back-home {
    position: absolute;
    top: 2rem;
    right: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.back-home:hover {
    color: var(--accent-primary);
}

/* Responsive Login */
@media (max-width: 1024px) {
    .login-visual {
        display: none;
    }
    .login-form-side {
        padding: 4rem 1.25rem;
    }
    
    .back-home {
        position: static;
        margin-bottom: 2rem;
        justify-content: flex-start;
    }
}

@media (max-width: 480px) {
    .social-btns {
        flex-direction: column;
    }
    
    .btn-social {
        width: 100%;
    }
}

/* Story Details Page */
.story-details-page {
    padding-top: var(--nav-height);
}

.story-details-page section {
    opacity: 1;
    transform: none;
    transition: none;
    padding: 5rem 0;
}

.story-hero {
    padding-top: 3rem !important;
    background: radial-gradient(circle at 80% 10%, rgba(196, 62, 28, 0.08), transparent 40%);
}

.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 0.9rem;
}

.breadcrumbs a:hover {
    color: var(--accent-primary);
}

.story-hero-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2rem;
    align-items: stretch;
}

.story-main-card,
.sidebar-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    box-shadow: var(--card-shadow);
}

.story-main-card {
    padding: 2.2rem;
}

.story-main-card h2 {
    font-size: 3rem;
    line-height: 1.2;
    margin: 1rem 0;
}

.story-lead {
    color: var(--text-secondary);
    font-size: 1.15rem;
    margin-bottom: 2rem;
}

.story-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.story-cover {
    min-height: 420px;
    border-radius: 24px;
    background-size: cover;
    background-position: center;
    box-shadow: var(--card-shadow);
}

.story-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    align-items: start;
}

.article-body {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    padding: 2.5rem;
}

.article-body p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    line-height: 2;
}

.article-body blockquote {
    border-inline-start: 4px solid var(--accent-primary);
    background: rgba(196, 62, 28, 0.08);
    border-radius: 12px;
    padding: 1.2rem 1.4rem;
    margin: 2rem 0;
    font-size: 1.2rem;
    color: var(--text-primary);
    font-family: var(--font-heading);
}

.story-sidebar {
    display: grid;
    gap: 1rem;
}

.sidebar-card {
    padding: 1.5rem;
}

.sidebar-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.sidebar-card p {
    color: var(--text-secondary);
}

.sidebar-card ul {
    display: grid;
    gap: 0.8rem;
}

.sidebar-card li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.6rem;
    color: var(--text-secondary);
}

.sidebar-card li b {
    color: var(--accent-primary);
}

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

.related-stories .story-card h3 a:hover {
    color: var(--accent-primary);
}

@media (max-width: 992px) {
    .story-hero-grid,
    .story-layout {
        grid-template-columns: 1fr;
    }

    .story-main-card h2 {
        font-size: 2.3rem;
    }

    .story-cover {
        min-height: 320px;
    }
}

@media (max-width: 768px) {
    .story-details-page section {
        padding: 3.5rem 0;
    }

    .story-main-card,
    .article-body {
        padding: 1.5rem;
    }

    .story-main-card h2 {
        font-size: 1.9rem;
    }

    .story-lead,
    .article-body p {
        font-size: 1rem;
    }

    .breadcrumbs {
        flex-wrap: wrap;
    }
}

/* Writer Profile Page */
.writer-profile-page {
    padding-top: var(--nav-height);
}

.writer-profile-page section {
    opacity: 1;
    transform: none;
    transition: none;
    padding: 5rem 0;
}

.writer-profile-hero {
    padding-top: 3rem !important;
    background: radial-gradient(circle at 20% 10%, rgba(196, 62, 28, 0.08), transparent 35%);
}

.writer-profile-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 28px;
    box-shadow: var(--card-shadow);
    padding: 2rem;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 1.5rem;
    align-items: center;
}

.writer-profile-avatar img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid var(--bg-primary);
    object-fit: cover;
}

.writer-profile-main h2 {
    font-size: 2.8rem;
    margin: 0.8rem 0 0.4rem;
}

.writer-profile-role,
.writer-profile-bio {
    color: var(--text-secondary);
}

.writer-profile-role {
    font-weight: 500;
}

.writer-profile-bio {
    margin-top: 0.8rem;
    max-width: 760px;
}

.writer-profile-actions {
    margin-top: 1.2rem;
    display: flex;
    gap: 0.8rem;
}

.writer-profile-stats {
    display: grid;
    gap: 0.8rem;
    min-width: 120px;
}

.writer-profile-stats div {
    text-align: center;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 0.8rem;
    background: var(--bg-primary);
}

.writer-profile-stats b {
    color: var(--accent-primary);
    display: block;
    font-size: 1.2rem;
}

.writer-profile-stats span {
    color: var(--text-secondary);
    font-size: 0.86rem;
}

.writer-content-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    align-items: start;
}

.writer-stories-grid {
    grid-template-columns: repeat(2, 1fr);
}

.writer-side-panels {
    display: grid;
    gap: 1rem;
}

@media (max-width: 1100px) {
    .writer-profile-card {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .writer-profile-avatar {
        display: flex;
        justify-content: center;
    }

    .writer-profile-actions {
        justify-content: center;
    }

    .writer-profile-stats {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .writer-content-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .writer-profile-page section {
        padding: 3.5rem 0;
    }

    .writer-profile-main h2 {
        font-size: 2rem;
    }

    .writer-profile-stats {
        grid-template-columns: 1fr;
    }

    .writer-stories-grid {
        grid-template-columns: 1fr;
    }
}

/* Auth V2 */
.auth-v2-page {
    min-height: 100vh;
    background:
        radial-gradient(circle at 10% 10%, rgba(196, 62, 28, 0.12), transparent 30%),
        radial-gradient(circle at 90% 90%, rgba(196, 62, 28, 0.08), transparent 35%),
        var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-body);
}

.auth-v2-wrap {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1.05fr;
}

.auth-v2-brand {
    padding: 2.5rem;
    background: linear-gradient(140deg, rgba(196, 62, 28, 0.96), rgba(139, 45, 21, 0.98));
    color: #fff;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.auth-v2-home {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    width: fit-content;
    color: #fff;
    opacity: 0.9;
}

.auth-v2-home:hover {
    opacity: 1;
}

.auth-v2-brand-card {
    margin: auto 0;
    max-width: 520px;
}

.auth-v2-brand-card h2 {
    font-size: 3rem;
    line-height: 1.2;
    margin: 1rem 0;
}

.auth-v2-brand-card p {
    color: rgba(255, 255, 255, 0.88);
    font-size: 1.1rem;
    margin-bottom: 1.4rem;
}

.auth-v2-points {
    display: grid;
    gap: 0.9rem;
}

.auth-v2-points li {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    font-weight: 500;
}

.auth-v2-form-side {
    padding: 2.5rem 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.auth-v2-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 560px;
    width: 100%;
    margin: 0 auto 1.2rem;
}

.auth-v2-theme-toggle {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.auth-v2-switch {
    display: inline-flex;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: var(--bg-secondary);
    padding: 0.2rem;
}

.auth-v2-switch a {
    padding: 0.45rem 1rem;
    border-radius: 999px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.auth-v2-switch a.active {
    background: var(--accent-primary);
    color: #fff;
}

.auth-v2-card {
    max-width: 560px;
    width: 100%;
    margin: 0 auto;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    padding: 2rem;
}

.auth-v2-card h3 {
    font-size: 2rem;
}

.auth-v2-card > p {
    color: var(--text-secondary);
    margin-top: 0.4rem;
    margin-bottom: 1.2rem;
}

.auth-v2-form {
    display: grid;
    gap: 1rem;
}

.auth-v2-register-form {
    gap: 0.9rem;
}

.auth-v2-field {
    display: grid;
    gap: 0.45rem;
}

.auth-v2-field label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.auth-v2-input {
    position: relative;
}

.auth-v2-input > i,
.auth-v2-input > svg {
    position: absolute;
    inset-inline-start: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    pointer-events: none;
    width: 18px;
    height: 18px;
    stroke-width: 2;
}

.auth-v2-input input {
    width: 100%;
    min-height: 50px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    color: var(--text-primary);
    padding: 0.9rem 2.8rem 0.9rem 2.8rem;
    font-family: var(--font-body);
    font-size: 0.98rem;
}

.auth-v2-input input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(196, 62, 28, 0.12);
}

.auth-v2-password .toggle-password {
    position: absolute;
    left: 0.9rem;
    inset-inline-end: auto;
    right: auto;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    color: var(--text-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0.1rem;
    width: 24px;
    height: 24px;
    line-height: 0;
    z-index: 2;
}

.auth-v2-password .toggle-password i,
.auth-v2-password .toggle-password svg {
    width: 18px;
    height: 18px;
    stroke-width: 2;
}

.auth-v2-password input {
    padding-left: 2.8rem;
}

.auth-v2-utils {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.2rem;
}

.auth-v2-submit {
    width: 100%;
    margin-top: 0.2rem;
    border-radius: 12px;
}

.auth-v2-social {
    margin-top: 1.2rem;
}

.auth-v2-card .social-btns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.auth-v2-card .btn-social {
    min-height: 48px;
    border-radius: 12px;
}

@media (max-width: 1024px) {
    .auth-v2-wrap {
        grid-template-columns: 1fr;
    }

    .auth-v2-brand {
        display: none;
    }

    .auth-v2-form-side {
        padding: 1.2rem;
    }

    .auth-v2-card {
        padding: 1.4rem;
    }
}

@media (max-width: 600px) {
    .auth-v2-topbar {
        gap: 0.7rem;
    }

    .auth-v2-switch {
        width: 100%;
        justify-content: space-between;
    }

    .auth-v2-switch a {
        flex: 1;
        text-align: center;
    }

    .auth-v2-card h3 {
        font-size: 1.65rem;
    }

    .auth-v2-card .social-btns {
        grid-template-columns: 1fr;
    }
}

/* Explore Page */
.explore-page {
    padding-top: var(--nav-height);
}

.explore-page section {
    opacity: 1;
    transform: none;
    transition: none;
}

.explore-hero {
    padding: 4.5rem 0 2.5rem !important;
    background: radial-gradient(circle at 80% 10%, rgba(196, 62, 28, 0.1), transparent 40%);
}

.explore-hero h2 {
    font-size: 3.2rem;
    margin-bottom: 0.8rem;
}

.explore-hero p {
    color: var(--text-secondary);
    max-width: 720px;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.explore-search {
    max-width: 820px;
    position: relative;
    display: flex;
    gap: 0.7rem;
    align-items: center;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 0.7rem;
    box-shadow: var(--card-shadow);
}

.explore-search > i,
.explore-search > svg {
    color: var(--text-secondary);
    margin-inline: 0.45rem 0.2rem;
}

.explore-search input {
    flex: 1;
    border: none;
    background: transparent;
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--text-primary);
}

.explore-search input:focus {
    outline: none;
}

.explore-search .btn {
    border-radius: 12px;
}

.explore-filters {
    padding: 1rem 0 2rem !important;
}

.filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
}

.chip {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    border-radius: 999px;
    padding: 0.45rem 1rem;
    font-family: var(--font-body);
    cursor: pointer;
}

.chip.active,
.chip:hover {
    background: var(--accent-primary);
    color: #fff;
    border-color: var(--accent-primary);
}

.explore-layout {
    padding: 1rem 0 5rem !important;
}

.explore-grid {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 2rem;
    align-items: start;
}

.explore-side {
    display: grid;
    gap: 1rem;
}

.explore-side .sidebar-card ul li a {
    color: var(--accent-primary);
    font-weight: 500;
    font-size: 0.9rem;
}

.explore-stories {
    grid-template-columns: repeat(2, 1fr);
}

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

    .explore-stories {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .explore-hero h2 {
        font-size: 2.2rem;
    }

    .explore-search {
        flex-wrap: wrap;
    }

    .explore-search .btn {
        width: 100%;
    }

    .explore-stories {
        grid-template-columns: 1fr;
    }
}

/* Trending Page */
.trending-page {
    padding-top: var(--nav-height);
}

.trending-page section {
    opacity: 1;
    transform: none;
    transition: none;
}

.trending-hero {
    padding: 4.5rem 0 2.5rem !important;
    background: radial-gradient(circle at 15% 15%, rgba(196, 62, 28, 0.12), transparent 40%);
}

.trending-hero h2 {
    font-size: 3rem;
    margin-bottom: 0.8rem;
}

.trending-hero p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 1.4rem;
}

.trending-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(120px, 190px));
    gap: 0.8rem;
}

.trending-stats div {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 0.8rem;
    text-align: center;
    box-shadow: var(--card-shadow);
}

.trending-stats b {
    display: block;
    color: var(--accent-primary);
    font-size: 1.2rem;
}

.trending-stats span {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.trending-layout {
    padding: 1rem 0 5rem !important;
}

.trending-grid {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 2rem;
    align-items: start;
}

.trending-sidebar {
    display: grid;
    gap: 1rem;
}

.trending-sidebar .sidebar-card ul li a {
    color: var(--accent-primary);
    font-weight: 500;
    font-size: 0.9rem;
}

.trending-stories {
    grid-template-columns: repeat(2, 1fr);
}

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

@media (max-width: 768px) {
    .trending-hero h2 {
        font-size: 2.2rem;
    }

    .trending-stats {
        grid-template-columns: 1fr;
    }

    .trending-stories {
        grid-template-columns: 1fr;
    }
}

/* Writer Dashboard */
.writer-dashboard-page {
    padding-top: var(--nav-height);
}

.writer-dashboard-page section {
    opacity: 1;
    transform: none;
    transition: none;
}

.writer-dashboard-hero {
    padding: 4rem 0 2rem !important;
    background: radial-gradient(circle at 80% 20%, rgba(196, 62, 28, 0.12), transparent 42%);
}

.dashboard-hero-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 1rem;
}

.dashboard-hero-row h2 {
    font-size: 2.6rem;
}

.dashboard-hero-row p {
    color: var(--text-secondary);
}

.dashboard-hero-actions {
    display: flex;
    gap: 0.6rem;
}

.writer-dashboard-body {
    padding: 1.2rem 0 5rem !important;
}

.writer-dashboard-grid {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 1.2rem;
    align-items: start;
}

.dashboard-panel {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 18px;
    box-shadow: var(--card-shadow);
    padding: 1.2rem;
}

.dashboard-menu {
    display: grid;
    gap: 0.4rem;
    margin-top: 0.8rem;
}

.dashboard-menu a {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.55rem 0.7rem;
    border-radius: 10px;
    color: var(--text-secondary);
}

.dashboard-menu a:hover,
.dashboard-menu a.active {
    background: rgba(196, 62, 28, 0.12);
    color: var(--accent-primary);
}

.dashboard-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(120px, 1fr));
    gap: 0.8rem;
    margin-bottom: 1rem;
}

.metric-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    padding: 1rem;
}

.metric-card span {
    color: var(--text-secondary);
    font-size: 0.88rem;
}

.metric-card b {
    display: block;
    font-size: 1.55rem;
    color: var(--accent-primary);
    margin: 0.2rem 0;
}

.metric-card small {
    color: var(--text-secondary);
    font-size: 0.78rem;
}

.dashboard-content-grid {
    display: grid;
    grid-template-columns: 1.35fr 1fr;
    gap: 1rem;
}

.dashboard-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.8rem;
}

.dashboard-panel-head a {
    color: var(--accent-primary);
    font-size: 0.9rem;
    font-weight: 500;
}

.dashboard-table-wrap {
    overflow-x: auto;
}

.dashboard-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 520px;
}

.dashboard-table th,
.dashboard-table td {
    text-align: right;
    border-bottom: 1px solid var(--border-color);
    padding: 0.65rem 0.4rem;
    font-size: 0.92rem;
}

.dashboard-table th {
    color: var(--text-secondary);
    font-weight: 500;
}

.dashboard-table td a:hover {
    color: var(--accent-primary);
}

.status-badge {
    display: inline-flex;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
}

.status-badge.published {
    background: rgba(16, 185, 129, 0.16);
    color: #059669;
}

.status-badge.draft {
    background: rgba(245, 158, 11, 0.18);
    color: #b45309;
}

.dashboard-comments {
    display: grid;
    gap: 0.8rem;
}

.dashboard-comments li {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.8rem;
    background: var(--bg-primary);
}

.dashboard-comments p {
    margin-bottom: 0.35rem;
}

.dashboard-comments small {
    color: var(--text-secondary);
}

@media (max-width: 1100px) {
    .writer-dashboard-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-metrics {
        grid-template-columns: repeat(2, minmax(120px, 1fr));
    }

    .dashboard-content-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .dashboard-hero-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .dashboard-hero-row h2 {
        font-size: 2rem;
    }

    .dashboard-hero-actions {
        width: 100%;
        flex-direction: column;
    }

    .dashboard-hero-actions .btn {
        width: 100%;
        text-align: center;
    }

    .dashboard-metrics {
        grid-template-columns: 1fr;
    }
}

/* Writer Add Story */
.writer-add-story-page {
    padding-top: var(--nav-height);
}

.writer-add-story-page section {
    opacity: 1;
    transform: none;
    transition: none;
}

.writer-add-story-hero {
    padding: 4rem 0 2rem !important;
    background: radial-gradient(circle at 20% 10%, rgba(196, 62, 28, 0.12), transparent 42%);
}

.writer-add-story-hero h2 {
    font-size: 2.6rem;
}

.writer-add-story-hero p {
    color: var(--text-secondary);
}

.writer-add-story-body {
    padding: 1.2rem 0 5rem !important;
}

.writer-add-story-grid {
    display: grid;
    grid-template-columns: 1.4fr 340px;
    gap: 1rem;
    align-items: start;
}

.add-story-form {
    display: grid;
    gap: 0.9rem;
}

.story-stepper {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.6rem;
    margin-bottom: 0.2rem;
}

.step-chip {
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    color: var(--text-secondary);
    border-radius: 12px;
    padding: 0.55rem 0.7rem;
    font-family: var(--font-body);
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
}

.step-chip span {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
}

.step-chip.active {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
    background: rgba(196, 62, 28, 0.08);
}

.step-chip.active span {
    border-color: var(--accent-primary);
    background: var(--accent-primary);
    color: #fff;
}

.form-step {
    display: none;
    gap: 0.9rem;
}

.form-step.active {
    display: grid;
}

.add-story-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
}

.add-story-field {
    display: grid;
    gap: 0.45rem;
}

.add-story-field label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.add-story-field input,
.add-story-field select,
.add-story-field textarea {
    width: 100%;
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    color: var(--text-primary);
    border-radius: 12px;
    padding: 0.8rem 0.9rem;
    font-family: var(--font-body);
    font-size: 0.95rem;
}

.add-story-field textarea {
    resize: vertical;
}

.add-story-field input:focus,
.add-story-field select:focus,
.add-story-field textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(196, 62, 28, 0.1);
}

.story-editor {
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    border-radius: 12px;
    overflow: hidden;
}

.story-editor:focus-within {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(196, 62, 28, 0.1);
}

.story-editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    padding: 0.55rem;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-secondary);
}

.editor-btn {
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    color: var(--text-secondary);
    width: 34px;
    height: 34px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.editor-btn:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.editor-btn i,
.editor-btn svg {
    width: 16px;
    height: 16px;
}

.story-editor-area {
    min-height: 260px;
    padding: 0.9rem;
    color: var(--text-primary);
    line-height: 1.9;
    outline: none;
}

.story-editor-area:empty::before {
    content: attr(data-placeholder);
    color: var(--text-secondary);
}

.story-editor-hidden {
    display: none;
}

.chapters-section-hidden {
    display: none;
}

.chapters-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.6rem;
    gap: 0.8rem;
}

.chapters-list {
    display: grid;
    gap: 0.8rem;
}

.chapter-block {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-secondary);
    padding: 0.8rem;
}

.chapter-block-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.6rem;
}

.remove-chapter-btn {
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    color: var(--text-secondary);
    border-radius: 10px;
    padding: 0.35rem 0.7rem;
    font-family: var(--font-body);
    cursor: pointer;
}

.remove-chapter-btn:hover {
    border-color: #dc2626;
    color: #dc2626;
}

.chapter-editor-wrap {
    margin-top: 0.4rem;
}

.chapter-editor {
    min-height: 180px;
    padding: 0.8rem;
    color: var(--text-primary);
    line-height: 1.85;
    outline: none;
}

.chapter-editor:empty::before {
    content: attr(data-placeholder);
    color: var(--text-secondary);
}

.add-story-options {
    display: grid;
    gap: 0.5rem;
    margin-top: 0.2rem;
}

.add-story-actions {
    display: flex;
    gap: 0.7rem;
    justify-content: flex-end;
    margin-top: 0.2rem;
}

.step-actions {
    display: flex;
    gap: 0.7rem;
    justify-content: flex-end;
    margin-top: 0.2rem;
}

.publish-review {
    margin-top: 0.2rem;
}

.add-story-side {
    display: grid;
    gap: 1rem;
}

@media (max-width: 1100px) {
    .writer-add-story-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .writer-add-story-hero h2 {
        font-size: 2rem;
    }

    .add-story-row {
        grid-template-columns: 1fr;
    }

    .story-stepper {
        grid-template-columns: 1fr;
    }

    .add-story-actions {
        flex-direction: column;
    }

    .add-story-actions .btn {
        width: 100%;
        text-align: center;
    }

    .step-actions {
        flex-direction: column;
    }

    .step-actions .btn {
        width: 100%;
        text-align: center;
    }
}
