/*
Theme Name: 4WNews
Theme URI: http://4wnews.local
Author: Taimoor Ahmed
Author URI: 
Description: A custom NYT-inspired, ultra-lightweight and fast WordPress theme tailored for 4WNews.
Version: 1.3.0
*/

:root {
    --color-bg: #fff;
    --color-text: #121212;
    --color-text-light: #5a5a5a;
    --color-border: #e2e2e2;
    --color-border-dark: #ccc;

    --font-heading: "Georgia", "Times New Roman", Times, serif;
    --font-body: "Georgia", "Times New Roman", Times, serif;
    /* NYT uses serif for body mostly */
    --font-ui: "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;

    --container-width: 1240px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    overflow-x: hidden;
    width: 100%;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-body);
    line-height: 1.5;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button,
input,
select,
textarea {
    font-family: var(--font-ui);
    border-radius: 4px;
}

button {
    cursor: pointer;
    transition: all 0.2s ease;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    margin-top: 0;
    line-height: 1.15;
    color: #000;
    font-weight: 700;
}

a {
    color: inherit;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

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

svg {
    display: inline-block;
    vertical-align: middle;
    max-width: 100%;
}

.container-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

/* Header */
.site-header {
    margin-bottom: 0.5rem;
}

.header-top-bar {
    font-family: var(--font-ui);
    font-size: 0.7rem;
    padding: 10px 0;
    border-bottom: 1px solid var(--color-border);
    text-transform: uppercase;
    font-weight: 700;
    color: #121212;
}

.header-top-left,
.header-top-right {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
}

.header-top-right {
    justify-content: flex-end;
}

.search-icon {
    cursor: pointer;
    display: flex;
    align-items: center;
}

.header-top-center {
    flex: 2;
    text-align: center;
}

.menu-toggle {
    background: none;
    border: none;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.7rem;
}

.edition-links {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.btn-subscribe {
    background: #000;
    color: #fff !important;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.65rem;
    font-family: var(--font-ui);
    font-weight: 700;
    display: inline-flex;
    align-items: center;
}

.header-main {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem 0;
    position: relative;
}

.header-main-left {
    flex: 1;
}

.site-title {
    flex: 2;
    text-align: center;
    font-size: 4.5rem;
    font-weight: normal;
    margin: 0;
    font-family: "Georgia", serif;
    letter-spacing: -0.5px;
}

.site-title img {
    max-width: 100%;
    height: auto;
}

.header-stock-ticker {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    font-family: var(--font-ui);
    font-size: 0.95rem;
    font-weight: 500;
}

.header-stock-ticker .stock-item {
    align-items: center;
    gap: 10px;
    justify-content: flex-end;
}

.header-stock-ticker .stock-symbol {
    color: #111;
}

.header-stock-ticker .stock-down {
    color: #cc0000;
}

.header-stock-ticker .stock-up {
    color: #008000;
}

.header-date-bar {
    font-family: var(--font-ui);
    font-size: 0.8rem;
    font-weight: 700;
    border-top: 1px solid var(--color-border-dark);
    border-bottom: 4px double #000;
    padding: 10px 0;
    display: flex;
    justify-content: space-between;
}

.main-navigation {
    border-bottom: 1px solid #000;
    padding: 12px 0;
}

.main-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.main-navigation a {
    font-family: var(--font-ui);
    font-weight: 700;
    font-size: 0.9rem;
    color: #000;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.main-navigation a:hover {
    text-decoration: underline;
}

/* NYT Grid Layouts */
.nyt-grid {
    display: grid;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.nyt-top-stories {
    grid-template-columns: 2fr 4.5fr 2fr;
}

.top-stories-row {
    border-bottom: 1px solid #000;
    padding-bottom: 2rem;
    margin-bottom: 2rem;
}

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

.nyt-column-with-border {
    padding-right: 1.5rem;
    border-right: 1px solid var(--color-border-dark);
}

.story-item .story-meta {
    font-family: var(--font-ui);
    font-size: 0.75rem;
    color: var(--color-text-light);
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    display: block;
}

.story-item h2,
.story-item h3 {
    margin-bottom: 0.5rem;
}

.story-item p {
    color: #333;
    font-size: 1rem;
    margin-bottom: 0;
}

.story-item-main h2 {
    font-size: 2.8rem;
    margin-bottom: 1rem;
}

.story-item-main p {
    font-size: 1.15rem;
}

.story-item-main .story-image {
    margin-bottom: 1rem;
}

.story-item-main .story-image img {
    width: 100%;
    height: auto;
    display: block;
}

.story-item-small h3 {
    font-size: 1.2rem;
}

.story-item-small img {
    width: 100%;
    height: auto;
    margin-bottom: 0.5rem;
}

/* Section specific */
.section-headline {
    font-family: var(--font-ui);
    font-size: 0.8rem;
    text-transform: uppercase;
    font-weight: 700;
    border-top: 2px solid #000;
    padding-top: 5px;
    margin-bottom: 1.5rem;
}

.nyt-4-col {
    grid-template-columns: repeat(4, 1fr);
}

.nyt-3-col {
    grid-template-columns: repeat(3, 1fr);
}

/* Dividers */
hr {
    border: 0;
    height: 1px;
    background: var(--color-border-dark);
    margin: 1.5rem 0;
}

/* Sections */
.nyt-section-header {
    border-top: 1px solid #000;
    padding-top: 5px;
    margin: 2.5rem 0 1.5rem;
    font-family: var(--font-ui);
    font-size: 0.85rem;
    font-weight: 700;
    color: #000;
    text-transform: uppercase;
}

.nyt-section-header.thick-top {
    border-top: 2px solid #000;
}

/* Post Meta (Read time, Author, etc) */
.nyt-meta-read {
    font-family: var(--font-ui);
    font-size: 0.65rem;
    color: var(--color-text-light);
    text-transform: uppercase;
    font-weight: 600;
    margin-top: 0.5rem;
    display: block;
}

.nyt-author {
    font-family: var(--font-ui);
    font-size: 0.75rem;
    color: #111;
    text-transform: uppercase;
    margin-bottom: 0.2rem;
    display: block;
}

/* Opinion Format */
.opinion-block {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.opinion-block-content {
    flex: 1;
    padding-right: 15px;
}

.opinion-block img.avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

/* 3-Col Horizontal Cards Format (eg. In Case You Missed It / What to Watch) */
.story-item-horizontal {
    display: flex;
    flex-direction: column;
}

.story-item-horizontal img {
    width: 100%;
    height: auto;
    object-fit: cover;
    margin-bottom: 0.75rem;
}

.story-item-horizontal.wide {
    flex-direction: row;
    align-items: flex-start;
    gap: 15px;
}

.story-item-horizontal.wide img {
    width: 50%;
    margin-bottom: 0;
}

/* Videos Horizontal list */
.video-stories {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
}

.video-item {
    position: relative;
}

.video-item img {
    width: 100%;
    height: auto;
    display: block;
    margin-bottom: 0.5rem;
}

.video-item .play-btn {
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.video-item h4 {
    font-size: 0.95rem;
}

/* Sports Feature */
.sports-feature {
    display: grid;
    grid-template-columns: 1fr 1.5fr 1fr;
    gap: 1.5rem;
}

/* Utils */
.text-center {
    text-align: center;
}

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

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

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

/* Single Article */
.article-title {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    font-family: var(--font-heading);
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-ui);
    padding-bottom: 2rem;
    border-bottom: 1px solid #eee;
    margin-bottom: 2rem;
}

.article-content {
    font-size: 1.15rem;
    line-height: 1.7;
    color: #222;
    max-width: 800px;
    margin: 0 auto;
}

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

/* Responsive basics */
@media (max-width: 992px) {
    .nyt-top-stories {
        grid-template-columns: 1fr 2fr;
    }

    .nyt-top-stories .nyt-column:last-child {
        display: none;
    }

    .nyt-4-col {
        grid-template-columns: repeat(2, 1fr);
    }

    .site-title {
        font-size: 3.5rem;
    }

    .header-stock-ticker {
        font-size: 0.85rem;
    }

    /* Mobile: single scrollable row category nav, like NYT */
    .main-navigation ul {
        flex-wrap: nowrap;
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        padding: 0 16px;
        gap: 1.2rem;
    }

    .main-navigation ul::-webkit-scrollbar {
        display: none;
    }

    .main-navigation li {
        flex-shrink: 0;
    }

    .main-navigation a {
        font-size: 0.92rem;
        white-space: nowrap;
    }
}

@media (max-width: 768px) {
    .header-stock-ticker {
        position: static;
        text-align: center;
        margin-top: 1rem;
    }

    .header-stock-ticker .stock-item {
        justify-content: center;
    }

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

    .nyt-column-with-border {
        border-right: none;
        padding-right: 0;
    }

    .nyt-4-col,
    .nyt-3-col {
        grid-template-columns: 1fr;
    }

    .header-top-bar {
        padding: 8px 0;
    }

    .header-top-left {
        gap: 0;
        /* drop gap — use individual margins instead */
        flex-shrink: 0;
        /* don't let the container itself compress */
        min-width: 0;
    }

    /* Prevent hamburger from shrinking */
    .header-top-left .menu-toggle {
        flex-shrink: 0;
        white-space: nowrap;
    }

    /* Keep search icon fixed size and add explicit left spacing */
    .header-top-left .search-icon {
        flex-shrink: 0;
        margin-left: 14px;
        min-width: 28px;
    }

    .header-top-bar span {
        display: none;
        /* Hide 'SECTIONS' text on very small screens */
    }

    .header-top-bar .menu-toggle span {
        display: inline;
        /* Keep 'SECTIONS' if needed or hide it */
    }

    .header-main {
        flex-direction: column;
        padding: 1rem 0;
        width: 100%;
        overflow: hidden;
    }

    .site-title {
        font-size: 2.2rem;
        margin: 5px 0;
        width: 100%;
        display: block;
    }

    .header-top-bar .edition-links {
        display: none;
    }

    .site-title {
        font-size: 2.2rem;
        margin: 10px 0;
        width: 100%;
    }

    .site-title img {
        max-height: 150px !important;
        max-width: 90% !important;
        margin: 0 auto;
    }

    .article-title {
        font-size: 2.2rem;
    }

    .article-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
        padding-bottom: 1.5rem;
    }

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

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

    .sports-feature {
        grid-template-columns: 1fr;
    }

    .search-form {
        gap: 10px;
    }

    .search-field {
        padding: 10px 15px;
        font-size: 1rem;
    }

    .search-submit {
        padding: 10px 20px;
    }

    .btn-close-premium {
        width: 34px;
        height: 34px;
        flex-shrink: 0;
    }

    .game-tile {
        border-right: none;
        border-bottom: 1px solid #e2e2e2;
        padding-bottom: 20px;
        padding-right: 0;
    }

    /* Sections Drawer Mobile */
    .sections-drawer {
        max-width: 100% !important;
    }

    .drawer-header {
        padding: 12px 16px;
        justify-content: space-between;
        background: #fff;
    }

    .drawer-logo {
        flex: 1;
        text-align: center;
        margin-left: 0;
        padding-right: 40px;
    }

    .drawer-logo img {
        max-height: 40px !important;
        margin: 0 auto;
    }

    /* Hamburger & Search icon — properly sized on mobile */
    .menu-toggle {
        gap: 5px;
        font-size: 0.72rem;
    }

    .menu-toggle svg {
        width: 28px !important;
        height: 28px !important;
        flex-shrink: 0;
    }

    .search-icon svg {
        width: 24px !important;
        height: 24px !important;
    }

    .drawer-layout {
        flex-direction: column !important;
        overflow: visible !important;
    }

    /* Transform left nav into a horizontally scrollable tab carousel */
    .drawer-nav-left {
        width: 100% !important;
        height: auto !important;
        border-right: none !important;
        border-bottom: 1px solid #e0e0e0 !important;
        padding: 0 !important;
        background: #fafafa !important;
        position: static !important;
        overflow: visible !important;
    }

    .drawer-nav-left ul {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    .drawer-nav-left ul::-webkit-scrollbar {
        display: none !important;
    }

    .drawer-nav-left li {
        flex: 0 0 33.333% !important;
        /* exactly 3 visible at once */
        padding: 14px 8px !important;
        text-align: center !important;
        font-size: 0.68rem !important;
        font-weight: 700 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.5px !important;
        border-right: 1px solid #e0e0e0 !important;
        border-bottom: 3px solid transparent !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        cursor: pointer;
        white-space: nowrap;
        min-width: 0 !important;
        overflow: visible !important;
    }

    .drawer-nav-left li:last-child {
        border-right: none !important;
    }

    .drawer-nav-left li .arrow {
        display: none !important;
    }

    .drawer-nav-left li.active {
        border-bottom: 3px solid #000 !important;
        background: #fff !important;
        color: #000;
    }

    .drawer-content-right {
        padding: 25px 20px;
        flex: 1;
        overflow-y: auto;
    }

    .drawer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .drawer-pane h2 {
        font-size: 1.6rem;
        margin-bottom: 20px;
        padding-bottom: 12px;
    }

    .drawer-col li a {
        font-size: 1rem;
        padding: 8px 0;
        display: block;
    }

    .story-item-horizontal.wide {
        flex-direction: column;
    }

    .story-item-horizontal.wide img {
        width: 100%;
        margin-bottom: 10px;
    }
}

/* Footer Styles */
.nyt-footer {
    border-top: 1px solid var(--color-border);
    border-bottom: 2px solid #000;
    padding: 1rem 0 3rem;
    margin-top: 3rem;
    font-family: var(--font-ui);
}

.footer-top {
    border-bottom: 3px double var(--color-border-dark);
    padding-bottom: 1.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 3rem;
}

.footer-logo {
    font-size: 1.5rem;
    display: inline-block;
    margin: 0;
    flex-shrink: 0;
}

.footer-logo a {
    color: #000;
}

.footer-tagline {
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.7;
    color: #444;
    margin: 0;
    flex: 1;
}

.footer-main-nav {
    display: grid;
    grid-template-columns: repeat(5, 1fr) 1.5fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-col h3 {
    font-family: var(--font-ui);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #000;
    margin-bottom: 1rem;
}

.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

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

.footer-col ul li a {
    font-size: 0.75rem;
    color: #333;
    font-weight: 700;
}

.footer-col ul li a:hover {
    text-decoration: underline;
}

/* Account Column Formatting */
.footer-col-account {
    border-left: 1px solid var(--color-border);
    padding-left: 2rem;
}

.footer-col-account .bold-links li {
    margin-bottom: 0.8rem;
}

.footer-col-account .bold-links li a {
    font-weight: 700;
    font-size: 0.85rem;
    color: #000;
    display: flex;
    align-items: center;
}

.footer-col-account .sub-links li a {
    font-size: 0.7rem;
    color: #555;
}

.pt-1 {
    padding-top: 1rem;
}

.border-top-light {
    border-top: 1px solid var(--color-border);
}

.footer-legal {
    text-align: center;
    border-top: 1px solid var(--color-border);
    padding-top: 1.5rem;
    margin-top: 2rem;
}

.footer-legal ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
}

.footer-legal ul li,
.footer-legal ul li a {
    font-size: 0.65rem;
    color: #777;
}

.footer-legal ul li a:hover {
    color: #333;
}

@media (max-width: 992px) {
    .footer-main-nav {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer-col-account {
        border-left: none;
        padding-left: 0;
    }
}

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

    .footer-top {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1.25rem;
    }

    .footer-tagline {
        font-size: 0.92rem;
        text-align: center;
    }

    .footer-logo {
        display: flex;
        justify-content: center;
    }
}

/* Site Overlay */
.site-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.site-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Sections Drawer (Premium NYT) */
.sections-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    max-width: 900px;
    height: 100vh;
    background: #fff;
    z-index: 10001;
    transform: translateX(-100%);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
    box-shadow: 15px 0 50px rgba(0, 0, 0, 0.3);
}

.sections-drawer.active {
    transform: translateX(0);
}

.drawer-header {
    display: flex;
    align-items: center;
    padding: 20px 40px;
    border-bottom: 1px solid #eee;
}

.btn-close-premium {
    background: #fff;
    border: 1px solid #e5e5e5;
    cursor: pointer;
    padding: 0;
    color: #1a1a1b;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 50% !important;
    width: 40px;
    height: 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    z-index: 100;
}

.btn-close-premium:hover {
    background: #f8f8f8;
    transform: scale(1.05) rotate(90deg);
    border-color: #1a1a1b;
    color: #000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.btn-close-premium svg {
    display: block;
    width: 24px;
    height: 24px;
}

.drawer-logo {
    font-family: var(--font-heading);
    font-size: 2rem;
    margin-left: 20px;
}

.drawer-layout {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* Left Navigation */
.drawer-nav-left {
    width: 240px;
    border-right: 1px solid #eee;
    padding: 20px 0;
    background: #fcfcfc;
    overflow-y: auto;
}

.drawer-nav-left ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.drawer-nav-left li {
    padding: 15px 40px;
    font-family: var(--font-ui);
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
    border-right: 3px solid transparent;
}

.drawer-nav-left li:hover,
.drawer-nav-left li.active {
    background: #fff;
    border-right: 3px solid #000;
}

.drawer-nav-left li .arrow {
    opacity: 0.3;
    font-size: 1.25rem;
}

.drawer-nav-left li.active .arrow {
    opacity: 1;
}

/* Right Content Area */
.drawer-content-right {
    flex: 1;
    padding: 40px 60px;
    overflow-y: auto;
    background: #fff;
}

.drawer-pane {
    display: none;
    animation: fadeIn 0.3s ease-out;
}

.drawer-pane.active {
    display: block;
}

.drawer-pane h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #000;
}

.drawer-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.drawer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.drawer-col li {
    margin-bottom: 15px;
}

.drawer-col li a {
    font-family: var(--font-ui);
    font-size: 1.1rem;
    color: #333;
    text-decoration: none;
}

.drawer-col li a:hover {
    text-decoration: underline;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Search Overlay */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 140px;
    background: #fff;
    z-index: 10005;
    transform: translateY(-100%);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.search-overlay.active {
    transform: translateY(0);
}

.search-overlay .container {
    height: 100%;
    display: flex;
    align-items: center;
}

.search-form {
    width: 100%;
    display: flex;
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
}

.search-field {
    flex: 1;
    border: 1px solid #ccc;
    padding: 12px 20px;
    font-size: 1.1rem;
    font-family: var(--font-ui);
    outline: none;
}

.search-submit {
    background: #121212;
    color: #fff;
    padding: 12px 30px;
    border: none;
    border-radius: 4px;
    font-weight: 700;
    cursor: pointer;
    font-family: var(--font-ui);
    font-size: 0.95rem;
}

.search-submit:hover {
    background: #333;
}

/* Auth Modal & AJAX */
.auth-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    z-index: 10010;
    display: none;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
}

.auth-modal.active {
    display: flex;
}

.auth-container {
    width: 100%;
    max-width: 400px;
    padding: 40px 20px;
    text-align: center;
}

.auth-logo {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: 30px;
    display: block;
}

.auth-title {
    font-family: var(--font-ui);
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.auth-input {
    border: 1px solid #ccc;
    padding: 12px;
    font-family: var(--font-ui);
    font-size: 1rem;
    width: 100%;
    box-sizing: border-box;
}

.auth-submit {
    background: #121212;
    color: #fff;
    border: none;
    padding: 14px;
    font-family: var(--font-ui);
    font-weight: 700;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.2s;
}

.auth-submit:hover {
    background: #333;
}

.auth-toggle {
    margin-top: 20px;
    font-family: var(--font-ui);
    font-size: 0.9rem;
    color: #555;
}

.auth-toggle a {
    color: #000;
    font-weight: 700;
    text-decoration: underline;
    cursor: pointer;
}

.close-auth {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 2.5rem;
    cursor: pointer;
    line-height: 1;
}

.auth-switch-signup {
    display: none;
}

.auth-modal.signup-mode .auth-switch-signup {
    display: block;
}

.auth-modal.signup-mode .auth-switch-login {
    display: none;
}

.auth-msg {
    padding: 12px;
    margin-bottom: 20px;
    font-family: var(--font-ui);
    font-size: 0.9rem;
    text-align: left;
}

.auth-msg.error {
    background: #fff1f1;
    color: #d00;
    border: 1px solid #ffdcdc;
}

.auth-msg.success {
    background: #f1fff1;
    color: #008a00;
    border: 1px solid #dcffdc;
}

body.drawer-open {
    overflow: hidden !important;
}

/* Games Section */

.nyt-games-header {
    margin-bottom: 20px;
    font-family: var(--font-ui);
}

.games-label {
    font-weight: 700;
    font-size: 1.1rem;
    margin-right: 5px;
}

.games-sublabel {
    font-style: italic;
    color: #666;
    font-size: 0.9rem;
}

.nyt-games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.game-tile {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-right: 1px solid #e2e2e2;
    padding-right: 20px;
}

.game-tile.border-none {
    border-right: none;
}

.game-info h4 {
    margin: 0 0 5px;
    font-family: var(--font-heading);
    font-size: 1.1rem;
}

.game-info p {
    margin: 0;
    font-size: 0.85rem;
    color: #444;
    line-height: 1.3;
}

.game-icon {
    width: 60px;
    height: 60px;
    flex-shrink: 0;
    margin-left: 20px;
}

/* Specific Icons CSS */
.wordle-icon {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
}

.wordle-icon div {
    background: #e2e2e2;
    border: 1px solid #ccc;
}

.wordle-icon div.active {
    background: #6aaa64;
    border-color: #6aaa64;
}

.connections-icon {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.connections-icon div {
    height: 10px;
    border-radius: 2px;
}

.c-1 {
    background: #f9df6d;
}

.c-2 {
    background: #a0c35a;
}

.c-3 {
    background: #ba81c5;
}

.c-4 {
    background: #74aaeb;
}

.bee-icon svg {
    width: 100%;
    height: 100%;
}

/* Living Section */
.nyt-living-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 30px;
    margin-top: 20px;
}

.living-cat-title {
    font-family: var(--font-ui);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    margin-bottom: 12px;
    border-bottom: 2px solid transparent;
}

.living-thumb {
    margin-bottom: 12px;
}

.living-thumb img {
    width: 100%;
    height: auto;
    aspect-ratio: 4/3;
    object-fit: cover;
    display: block;
}

.living-story-main h4 {
    font-family: var(--font-heading);
    font-size: 1rem;
    line-height: 1.2;
    margin: 0 0 15px;
    font-weight: 700;
}

.living-sub-stories p {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    margin: 0 0 10px;
    line-height: 1.2;
    border-top: 1px solid #efefef;
    padding-top: 10px;
}

.living-sub-stories p:first-of-type {
    border-top: none;
}

.py-2 {
    padding-top: 2rem;
    padding-bottom: 2rem;
}

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