/* ═══════════════════════════════════════════════════
   DESIGN TOKENS & CSS VARIABLES
═══════════════════════════════════════════════════ */
:root {
    /* Colors — Light Mode */
    --bg: #f2efe9;
    --bg-card: #ffffff;
    --bg-header: #0d1117;
    --bg-nav: #161b22;
    --text-1: #0d1117;
    --text-2: #57606a;
    --text-3: #8b949e;
    --text-inv: #f0f6fc;
    --accent: #e63946;
    --accent-dk: #c1121f;
    --accent-lt: #fdf0f1;
    --border: #e0dcd5;
    --shadow-sm: 0 1px 8px rgba(0, 0, 0, 0.07);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.10);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.14);
    --radius-lg: 14px;
    --radius-md: 10px;
    --radius-sm: 7px;
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
    --dur: 0.22s;

    /* Typography */
    --font-ui: 'Syne', sans-serif;
    --font-read: 'Lora', serif;
    --font-body: 'DM Sans', sans-serif;

    /* Misc */
    --ad-bg: #f7f5f0;
    --trend: #fff8f2;
}

/* Dark Mode Overrides */
[data-theme="dark"] {
    --bg: #0d1117;
    --bg-card: #161b22;
    --bg-header: #010409;
    --bg-nav: #010409;
    --text-1: #e6edf3;
    --text-2: #8b949e;
    --text-3: #57606a;
    --border: #30363d;
    --shadow-sm: 0 1px 8px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.55);
    --accent-lt: #1f1215;
    --ad-bg: #161b22;
    --trend: #161b22;
}

/* ═══════════════════════════════════════════════════
   RESET
═══════════════════════════════════════════════════ */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%
}

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text-1);
    line-height: 1.6;
    min-height: 100vh;
    transition: background .3s, color .3s
}

img {
    max-width: 100%;
    display: block
}

a {
    text-decoration: none;
    color: inherit
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
    line-height: 1
}

ul {
    list-style: none
}

/* ═══════════════════════════════════════════════════
   HEADER
═══════════════════════════════════════════════════ */
#hdr {
    background: var(--bg-header);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 0 rgba(255, 255, 255, .05);
}

.hdr-inner {
    display: flex;
    align-items: center;
    gap: 12px;
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 20px;
    height: 58px;
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-inv);
    font-family: var(--font-ui);
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: -.5px;
    cursor: pointer;
    flex-shrink: 0;
}

.logo-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    display: inline-block;
    animation: blink 2.2s ease-in-out infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
        transform: scale(1)
    }

    50% {
        opacity: .6;
        transform: scale(1.35)
    }
}

/* Search */
.srch-wrap {
    flex: 1;
    max-width: 400px;
    position: relative
}

#srch {
    width: 100%;
    padding: 8px 38px 8px 14px;
    border-radius: 22px;
    border: 1.5px solid rgba(255, 255, 255, .1);
    background: rgba(255, 255, 255, .06);
    color: var(--text-inv);
    font-family: var(--font-body);
    font-size: .875rem;
    outline: none;
    transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}

#srch::placeholder {
    color: rgba(255, 255, 255, .38)
}

#srch:focus {
    border-color: var(--accent);
    background: rgba(255, 255, 255, .1)
}

.srch-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, .45);
    font-size: .95rem;
    padding: 4px;
    transition: color var(--dur);
}

.srch-btn:hover {
    color: var(--accent)
}

/* Dark Toggle */
.dark-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    color: rgba(255, 255, 255, .65);
    font-family: var(--font-ui);
    font-size: .78rem;
    font-weight: 600;
    padding: 5px 10px;
    border-radius: 22px;
    transition: background var(--dur), color var(--dur);
    white-space: nowrap;
}

.dark-btn:hover {
    background: rgba(255, 255, 255, .07);
    color: var(--text-inv)
}

.sw {
    width: 34px;
    height: 18px;
    border-radius: 9px;
    background: rgba(255, 255, 255, .15);
    position: relative;
    transition: background .25s;
    flex-shrink: 0;
}

.sw.on {
    background: var(--accent)
}

.sw::after {
    content: '';
    position: absolute;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #fff;
    top: 2.5px;
    left: 2.5px;
    transition: transform .25s;
}

.sw.on::after {
    transform: translateX(16px)
}

/* Key button */
.key-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, .6);
    font-family: var(--font-ui);
    font-size: .78rem;
    font-weight: 600;
    padding: 5px 10px;
    border-radius: 22px;
    border: 1px solid rgba(255, 255, 255, .12);
    transition: all var(--dur);
    white-space: nowrap;
}

.key-btn:hover {
    color: var(--text-inv);
    border-color: rgba(255, 255, 255, .3)
}

/* ═══════════════════════════════════════════════════
   FILTERS NAV
═══════════════════════════════════════════════════ */
#filters {
    background: var(--bg-nav);
    border-top: 1px solid rgba(255, 255, 255, .04);
}

.flt-inner {
    display: flex;
    align-items: center;
    gap: 6px;
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 20px;
    height: 48px;
    overflow-x: auto;
    scrollbar-width: none;
}

.flt-inner::-webkit-scrollbar {
    display: none
}

.flt-lbl {
    font-family: var(--font-ui);
    font-size: .68rem;
    font-weight: 700;
    color: rgba(255, 255, 255, .35);
    text-transform: uppercase;
    letter-spacing: 1px;
    white-space: nowrap;
    flex-shrink: 0;
}

.flt-sep {
    width: 1px;
    height: 16px;
    background: rgba(255, 255, 255, .08);
    flex-shrink: 0;
    margin: 0 6px;
}

.flt-btn {
    padding: 4px 13px;
    border-radius: 15px;
    font-family: var(--font-ui);
    font-size: .78rem;
    font-weight: 600;
    color: rgba(255, 255, 255, .55);
    white-space: nowrap;
    flex-shrink: 0;
    border: 1.5px solid transparent;
    transition: color var(--dur), background var(--dur), border-color var(--dur);
}

.flt-btn:hover {
    color: rgba(255, 255, 255, .88);
    background: rgba(255, 255, 255, .06)
}

.flt-btn.on {
    color: #fff;
    background: var(--accent);
    border-color: var(--accent)
}

/* ═══════════════════════════════════════════════════
   TOP AD BANNER
═══════════════════════════════════════════════════ */
.ad-top {
    background: var(--ad-bg);
    border-bottom: 1px solid var(--border);
    text-align: center;
    padding: 10px 16px;
}

.ad-slot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--ad-bg);
    border: 1px dashed var(--border);
    border-radius: var(--radius-sm);
    padding: 10px 20px;
    font-size: .72rem;
    color: var(--text-3);
    font-family: var(--font-ui);
    width: 100%;
    max-width: 728px;
    min-height: 60px;
}

/* ═══════════════════════════════════════════════════
   DEMO BANNER
═══════════════════════════════════════════════════ */
#demo-bar {
    display: none;
    background: linear-gradient(90deg, #d4620a, #f4a261);
    color: #fff;
    padding: 9px 20px;
    text-align: center;
    font-family: var(--font-ui);
    font-size: .82rem;
    font-weight: 600;
}

#demo-bar a {
    color: #fff;
    text-decoration: underline;
    text-decoration-style: dotted
}

/* ═══════════════════════════════════════════════════
   MAIN WRAPPER
═══════════════════════════════════════════════════ */
#wrap {
    max-width: 1300px;
    margin: 0 auto;
    padding: 28px 20px 80px
}

/* ═══════════════════════════════════════════════════
   TRENDING
═══════════════════════════════════════════════════ */
#trending {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    background: var(--trend);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 18px;
    margin-bottom: 26px;
}

.trend-lbl {
    display: flex;
    align-items: center;
    gap: 5px;
    font-family: var(--font-ui);
    font-size: .75rem;
    font-weight: 800;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: .6px;
    white-space: nowrap;
    flex-shrink: 0;
}

.trend-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px
}

.tag {
    padding: 4px 13px;
    border-radius: 18px;
    background: var(--bg-card);
    border: 1.5px solid var(--border);
    font-family: var(--font-ui);
    font-size: .78rem;
    font-weight: 600;
    color: var(--text-2);
    cursor: pointer;
    transition: all var(--dur) var(--ease);
}

.tag:hover,
.tag.on {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    transform: translateY(-1px);
}

/* ═══════════════════════════════════════════════════
   SECTION HEADING
═══════════════════════════════════════════════════ */
.sec-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.sec-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-ui);
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-1);
}

.sec-title::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 18px;
    border-radius: 2px;
    background: var(--accent);
}

.sec-count {
    font-size: .78rem;
    color: var(--text-3);
    font-family: var(--font-body)
}

/* ═══════════════════════════════════════════════════
   NEWS GRID
═══════════════════════════════════════════════════ */
#grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(296px, 1fr));
    gap: 20px;
}

/* First card spans full width */
#grid .card:first-child {
    grid-column: 1/-1
}

@media(min-width:860px) {
    #grid .card:first-child {
        display: grid;
        grid-template-columns: 1.1fr 1fr;
    }

    #grid .card:first-child .cimg {
        height: 100%;
        min-height: 270px
    }

    #grid .card:first-child .cimg img {
        height: 100%;
        object-fit: cover
    }

    #grid .card:first-child .ctitle {
        font-size: 1.55rem;
        line-height: 1.25
    }
}

/* ═══════════════════════════════════════════════════
   NEWS CARD
═══════════════════════════════════════════════════ */
.card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    transition: box-shadow var(--dur) var(--ease),
        transform var(--dur) var(--ease),
        border-color var(--dur) var(--ease);
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
    border-color: transparent;
}

/* Card image */
.cimg {
    position: relative;
    overflow: hidden;
    height: 196px;
    background: var(--border);
    flex-shrink: 0;
}

.cimg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s var(--ease);
}

.card:hover .cimg img {
    transform: scale(1.05)
}

/* Category badge */
.cbadge {
    position: absolute;
    top: 11px;
    left: 11px;
    background: var(--accent);
    color: #fff;
    font-family: var(--font-ui);
    font-size: .65rem;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: 9px;
    text-transform: uppercase;
    letter-spacing: .5px;
}

/* Card body */
.cbody {
    padding: 17px;
    display: flex;
    flex-direction: column;
    flex: 1
}

.cmeta {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 9px;
}

.csrc {
    font-family: var(--font-ui);
    font-size: .7rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: .4px;
}

.cdot {
    color: var(--text-3);
    font-size: .55rem
}

.ctime {
    font-size: .7rem;
    color: var(--text-3)
}

.ctitle {
    font-family: var(--font-read);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-1);
    line-height: 1.38;
    margin-bottom: 9px;
    transition: color var(--dur);
}

.card:hover .ctitle {
    color: var(--accent)
}

.cdesc {
    font-size: .865rem;
    color: var(--text-2);
    line-height: 1.65;
    margin-bottom: 15px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Card footer */
.cfooter {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
}

.rm-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--accent);
    color: #fff;
    font-family: var(--font-ui);
    font-size: .78rem;
    font-weight: 700;
    padding: 7px 17px;
    border-radius: 18px;
    transition: background var(--dur), transform var(--dur);
}

.rm-btn:hover {
    background: var(--accent-dk);
    transform: translateX(2px)
}

.rm-btn svg {
    transition: transform .2s
}

.rm-btn:hover svg {
    transform: translateX(3px)
}

.shr-btn {
    color: var(--text-3);
    font-size: 1rem;
    padding: 6px;
    border-radius: 50%;
    transition: all var(--dur);
}

.shr-btn:hover {
    background: var(--accent-lt);
    color: var(--accent)
}

/* ═══════════════════════════════════════════════════
   IN-FEED AD
═══════════════════════════════════════════════════ */
.ad-feed {
    grid-column: 1/-1;
    background: var(--ad-bg);
    border: 1px dashed var(--border);
    border-radius: var(--radius-lg);
    padding: 18px;
    text-align: center;
}

.ad-lbl {
    font-family: var(--font-ui);
    font-size: .62rem;
    color: var(--text-3);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

/* ═══════════════════════════════════════════════════
   STATES: LOADING / ERROR / EMPTY
═══════════════════════════════════════════════════ */
/* Loading skeleton */
.skeletons {
    grid-column: 1/-1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(296px, 1fr));
    gap: 20px;
}

.skel-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border);
}

.skel-img {
    height: 196px;
    background: linear-gradient(90deg, var(--border) 25%, var(--bg) 50%, var(--border) 75%);
    background-size: 200% 100%;
    animation: shim 1.6s ease-in-out infinite;
}

.skel-body {
    padding: 17px
}

.skel-ln {
    height: 11px;
    border-radius: 5px;
    margin-bottom: 9px;
    background: linear-gradient(90deg, var(--border) 25%, var(--bg) 50%, var(--border) 75%);
    background-size: 200% 100%;
    animation: shim 1.6s ease-in-out infinite;
}

.skel-ln.w100 {
    width: 100%
}

.skel-ln.w70 {
    width: 70%
}

.skel-ln.w50 {
    width: 50%
}

@keyframes shim {
    0% {
        background-position: 200% 0
    }

    100% {
        background-position: -200% 0
    }
}

/* Error state */
#err {
    display: none;
    grid-column: 1/-1;
    text-align: center;
    padding: 60px 20px;
}

.err-ico {
    font-size: 2.8rem;
    margin-bottom: 14px
}

.err-ttl {
    font-family: var(--font-ui);
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-1);
    margin-bottom: 7px;
}

.err-msg {
    font-size: .875rem;
    color: var(--text-2);
    max-width: 380px;
    margin: 0 auto 18px;
    line-height: 1.6;
}

.retry-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--accent);
    color: #fff;
    font-family: var(--font-ui);
    font-weight: 700;
    font-size: .85rem;
    padding: 9px 22px;
    border-radius: 22px;
    transition: background var(--dur);
}

.retry-btn:hover {
    background: var(--accent-dk)
}

/* No results */
#nores {
    display: none;
    grid-column: 1/-1;
    text-align: center;
    padding: 60px 20px;
}

.nores-ico {
    font-size: 2.8rem;
    margin-bottom: 14px
}

.nores-ttl {
    font-family: var(--font-ui);
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--text-1);
    margin-bottom: 7px;
}

.nores-sub {
    font-size: .875rem;
    color: var(--text-3)
}

/* ═══════════════════════════════════════════════════
   LOAD MORE
═══════════════════════════════════════════════════ */
#lm-wrap {
    text-align: center;
    margin-top: 36px;
    display: none
}

#lm-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-card);
    color: var(--text-1);
    border: 2px solid var(--border);
    font-family: var(--font-ui);
    font-size: .88rem;
    font-weight: 700;
    padding: 11px 30px;
    border-radius: 28px;
    transition: all var(--dur) var(--ease);
}

#lm-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-2px)
}

/* ═══════════════════════════════════════════════════
   ARTICLE PAGE (SPA)
═══════════════════════════════════════════════════ */
#art-page {
    display: none;
    max-width: 760px;
    margin: 0 auto;
    padding: 30px 20px 80px;
    animation: fadein .32s var(--ease);
}

@keyframes fadein {
    from {
        opacity: 0;
        transform: translateY(12px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--text-2);
    font-family: var(--font-ui);
    font-size: .83rem;
    font-weight: 600;
    padding: 7px 16px;
    border-radius: 18px;
    border: 1.5px solid var(--border);
    background: var(--bg-card);
    margin-bottom: 26px;
    transition: all var(--dur);
}

.back-btn:hover {
    color: var(--accent);
    border-color: var(--accent)
}

.art-cat {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    font-family: var(--font-ui);
    font-size: .68rem;
    font-weight: 700;
    padding: 3px 12px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: .5px;
    margin-bottom: 14px;
}

.art-title {
    font-family: var(--font-read);
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    font-weight: 700;
    color: var(--text-1);
    line-height: 1.25;
    margin-bottom: 16px;
}

.art-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 22px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border);
}

.art-src {
    background: var(--accent-lt);
    color: var(--accent);
    font-family: var(--font-ui);
    font-size: .75rem;
    font-weight: 700;
    padding: 3px 11px;
    border-radius: 8px;
}

.art-date,
.art-auth {
    font-size: .8rem;
    color: var(--text-3)
}

.art-img {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    border-radius: var(--radius-lg);
    margin-bottom: 26px;
    border: 1px solid var(--border);
}

/* Article Ad Slot */
.art-ad {
    background: var(--ad-bg);
    border: 1px dashed var(--border);
    border-radius: var(--radius-lg);
    padding: 22px;
    text-align: center;
    margin: 26px 0;
}

/* Article body */
.art-body {
    font-family: var(--font-read);
    font-size: 1.03rem;
    line-height: 1.85;
    color: var(--text-1);
}

.art-body p {
    margin-bottom: 1.35em
}

.art-lead {
    font-size: 1.15rem;
    font-weight: 600;
    padding-bottom: 1.2em;
    margin-bottom: 1.2em;
    border-bottom: 2px solid var(--border);
}

.art-notice {
    background: var(--ad-bg);
    border-left: 4px solid var(--accent);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    padding: 13px 17px;
    margin: 22px 0;
    font-size: .86rem;
    color: var(--text-2);
    font-family: var(--font-body);
}

.src-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--bg-card);
    color: var(--text-1);
    border: 1.5px solid var(--border);
    padding: 10px 20px;
    border-radius: 22px;
    font-family: var(--font-ui);
    font-size: .83rem;
    font-weight: 700;
    margin-top: 22px;
    transition: all var(--dur);
}

.src-link:hover {
    border-color: var(--accent);
    color: var(--accent)
}

/* ═══════════════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════════════ */
#ftr {
    background: var(--bg-header);
    color: rgba(255, 255, 255, .45);
    padding: 28px 20px;
    text-align: center;
    font-family: var(--font-ui);
    font-size: .78rem;
}

.ftr-logo {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-inv);
    margin-bottom: 7px
}

/* ═══════════════════════════════════════════════════
   SCROLL TO TOP
═══════════════════════════════════════════════════ */
#s2t {
    position: fixed;
    bottom: 22px;
    right: 22px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 4px 14px rgba(230, 57, 70, .38);
    opacity: 0;
    pointer-events: none;
    z-index: 50;
    transition: opacity .3s, transform .3s;
}

#s2t.vis {
    opacity: 1;
    pointer-events: all
}

#s2t:hover {
    transform: translateY(-3px)
}

/* ═══════════════════════════════════════════════════
   API KEY MODAL
═══════════════════════════════════════════════════ */
#modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .72);
    z-index: 200;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(5px);
}

#modal.open {
    display: flex
}

.modal-box {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 30px;
    max-width: 460px;
    width: 100%;
    border: 1px solid var(--border);
    box-shadow: 0 24px 64px rgba(0, 0, 0, .32);
}

.modal-ttl {
    font-family: var(--font-ui);
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-1);
    margin-bottom: 8px;
}

.modal-sub {
    font-size: .84rem;
    color: var(--text-2);
    margin-bottom: 18px;
    line-height: 1.55;
}

.modal-input {
    width: 100%;
    padding: 10px 13px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg);
    color: var(--text-1);
    font-family: var(--font-body);
    font-size: .88rem;
    outline: none;
    margin-bottom: 14px;
    transition: border-color .2s;
}

.modal-input:focus {
    border-color: var(--accent)
}

.modal-acts {
    display: flex;
    gap: 9px;
    flex-wrap: wrap
}

.btn-p {
    flex: 1;
    background: var(--accent);
    color: #fff;
    font-family: var(--font-ui);
    font-weight: 700;
    font-size: .85rem;
    padding: 10px 18px;
    border-radius: 22px;
    text-align: center;
    transition: background var(--dur);
}

.btn-p:hover {
    background: var(--accent-dk)
}

.btn-s {
    flex: 1;
    background: var(--bg);
    color: var(--text-2);
    font-family: var(--font-ui);
    font-weight: 600;
    font-size: .85rem;
    padding: 10px 18px;
    border-radius: 22px;
    text-align: center;
    border: 1.5px solid var(--border);
    transition: all var(--dur);
}

.btn-s:hover {
    border-color: var(--accent);
    color: var(--accent)
}

/* ═══════════════════════════════════════════════════
   TOAST
═══════════════════════════════════════════════════ */
#toast {
    position: fixed;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%) translateY(14px);
    background: #24292f;
    color: #fff;
    font-family: var(--font-ui);
    font-size: .82rem;
    font-weight: 600;
    padding: 9px 20px;
    border-radius: 22px;
    opacity: 0;
    pointer-events: none;
    z-index: 300;
    transition: all .28s var(--ease);
    white-space: nowrap;
}

#toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0)
}

/* ═══════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════ */
@media(max-width:700px) {
    .hdr-inner {
        padding: 0 13px;
        height: 52px
    }

    .logo-text {
        display: none
    }

    .key-btn .kb-txt {
        display: none
    }

    .dark-btn .dk-txt {
        display: none
    }

    #wrap {
        padding: 18px 13px 60px
    }

    #grid {
        grid-template-columns: 1fr;
        gap: 15px
    }

    #grid .card:first-child {
        grid-column: 1;
        display: flex;
        flex-direction: column
    }

    #grid .card:first-child .cimg {
        height: 196px
    }
}

@media(max-width:460px) {
    .srch-wrap {
        display: none
    }
}