:root {
    --bg: #0d0d1a;
    --surface: #17172a;
    --surface-2: #1f1f35;
    --surface-3: #26263f;
    --border: #34344d;
    --text: #e9e9f0;
    --muted: #b7b7c7;
    --pink: #e91e63;
    --pink-dark: #c2185b;
    --red: #ff5252;
    --green: #00e676;
    --green-dark: #00c853;
    --amber: #f5a623;
    --radius: 12px;
    --shadow: 0 8px 24px rgba(0, 0, 0, .24);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: 'Poppins', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.65;
    text-rendering: optimizeLegibility;
}

a {
    color: #ff8bb1;
}

a:hover,
a:focus-visible {
    color: #fff;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
summary:focus-visible {
    outline: 3px solid rgba(255, 82, 82, .55);
    outline-offset: 3px;
}

.container {
    width: min(1200px, 100%);
    margin: 0 auto;
    padding: 16px;
}

.last-updated {
    width: min(1200px, calc(100% - 32px));
    margin: 16px auto 0;
    padding: 11px 16px;
    border: 1px solid rgba(233, 30, 99, .35);
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(233, 30, 99, .96), rgba(198, 24, 91, .96));
    color: #fff;
    text-align: center;
    font-size: .98rem;
    font-weight: 600;
    letter-spacing: .2px;
    box-shadow: 0 5px 18px rgba(233, 30, 99, .22);
}

.page-title {
    margin: 28px auto 20px;
    max-width: 980px;
    color: var(--red);
    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1.2;
    text-align: center;
}

h2 {
    margin: 42px 0 16px;
    color: var(--red);
    font-size: clamp(1.55rem, 3vw, 2rem);
    line-height: 1.25;
    text-align: center;
}

h3 {
    margin-top: 0;
}

p {
    margin: 14px 0;
    font-size: 1rem;
}

.lead {
    max-width: 960px;
    margin: 0 auto 24px;
    color: #dedee8;
    font-size: 1.04rem;
}

.note,
.how-to,
.toc,
.methodology,
.summary-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.toc {
    margin: 24px 0 30px;
    padding: 18px 20px;
    border-left: 4px solid var(--amber);
}

.toc strong {
    display: block;
    margin-bottom: 8px;
    color: #fff;
    font-size: 1.05rem;
}

.toc a {
    display: inline-block;
    margin: 4px 8px 4px 0;
    padding: 5px 10px;
    color: #f5f5fb;
    text-decoration: none;
    border-radius: 7px;
    background: rgba(255, 255, 255, .055);
    transition: background-color .2s ease, color .2s ease, transform .2s ease;
}

.toc a:hover,
.toc a:focus-visible {
    color: #fff;
    background: rgba(233, 30, 99, .22);
    transform: translateY(-1px);
}

.quick-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin: 22px 0 10px;
}

.summary-card {
    padding: 16px;
    text-align: center;
}

.summary-card strong {
    display: block;
    color: #fff;
    font-size: 1.3rem;
}

.summary-card span {
    color: var(--muted);
    font-size: .9rem;
}

.section {
    margin: 44px 0;
}

.note,
.how-to,
.methodology {
    padding: 18px 20px;
}

.note {
    margin: 18px 0;
    border-left: 4px solid var(--amber);
}

.methodology {
    margin-top: 18px;
}

.methodology p:last-child,
.how-to ol:last-child,
.faq details:last-child {
    margin-bottom: 0;
}

.status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-height: 27px;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: .8rem;
    font-weight: 700;
    white-space: nowrap;
}

.status.ok {
    background: #188b4d;
    color: #fff;
}

.table-wrap {
    overflow-x: auto;
    margin: 22px 0;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

table {
    width: 100%;
    min-width: 680px;
    margin: 0;
    border-collapse: collapse;
    background: var(--surface);
}

caption {
    padding: 12px 0;
    color: var(--muted);
    text-align: left;
    caption-side: bottom;
    font-size: .9rem;
}

th,
td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    text-align: center;
    vertical-align: middle;
}

th {
    background: var(--pink);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
}

tbody tr {
    transition: background-color .18s ease;
}

tbody tr:hover {
    background: var(--surface-2);
}

tbody tr:last-child td {
    border-bottom: 0;
}

.code {
    color: #fff;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', monospace;
    font-size: .94rem;
    font-weight: 700;
    overflow-wrap: anywhere;
}

.reward {
    color: #e4e4ee;
}

.copy-btn {
    min-width: 92px;
    padding: 9px 15px;
    border: 0;
    border-radius: 7px;
    background: var(--green);
    color: #001509;
    cursor: pointer;
    font: inherit;
    font-size: .95rem;
    font-weight: 700;
    transition: background-color .2s ease, transform .2s ease, box-shadow .2s ease;
}

.copy-btn:hover {
    background: var(--green-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 230, 118, .18);
}

.copy-btn:active {
    transform: translateY(0);
}

.how-to ol {
    margin: 0;
    padding-left: 22px;
}

.how-to li + li {
    margin-top: 9px;
}

.feature-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 20px 0;
}

.feature-list article {
    padding: 18px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.feature-list h3 {
    margin-bottom: 8px;
    color: #fff;
    font-size: 1.08rem;
}

.feature-list p {
    margin-bottom: 0;
    color: var(--muted);
}

.faq details {
    margin: 10px 0;
    padding: 13px 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 9px;
}

.faq summary {
    cursor: pointer;
    color: #fff;
    font-weight: 700;
}

.faq p {
    color: var(--muted);
}

.share-buttons {
    margin: 48px 0 20px;
    text-align: center;
}

.share-buttons h3 {
    color: #fff;
}

.share-btn {
    display: inline-block;
    margin: 7px;
    padding: 11px 21px;
    background: var(--pink);
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 700;
    transition: background-color .2s ease, transform .2s ease;
}

.share-btn:hover,
.share-btn:focus-visible {
    background: var(--pink-dark);
    color: #fff;
    transform: translateY(-2px);
}

.cta {
    margin: 42px 0;
    padding: 24px 20px;
    border-radius: var(--radius);
    background: linear-gradient(135deg, #e91e63, #ff5252);
    color: #fff;
    text-align: center;
    box-shadow: 0 7px 20px rgba(233, 30, 99, .26);
}

.cta p {
    margin: 5px 0 0;
}

.footer-note {
    margin: 34px 0 0;
    color: var(--muted);
    font-size: .88rem;
    text-align: center;
}

@media (max-width: 900px) {
    .quick-summary,
    .feature-list {
        grid-template-columns: 1fr 1fr;
    }

    .table-wrap {
        overflow: visible;
        box-shadow: none;
    }

    table,
    thead,
    tbody,
    th,
    td,
    tr {
        display: block;
    }

    table {
        min-width: 0;
        background: transparent;
    }

    thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    tbody tr {
        margin-bottom: 14px;
        padding: 4px 0;
        background: var(--surface-2);
        border: 1px solid var(--border);
        border-radius: 10px;
        box-shadow: 0 4px 14px rgba(0, 0, 0, .15);
    }

    tbody tr:hover {
        background: var(--surface-3);
    }

    td {
        position: relative;
        display: grid;
        grid-template-columns: 38% minmax(0, 1fr);
        gap: 12px;
        padding: 11px 14px;
        border-bottom: 1px solid rgba(52, 52, 77, .75);
        text-align: right;
    }

    td::before {
        content: attr(data-label);
        color: var(--red);
        font-weight: 700;
        text-align: left;
    }

    td:last-child {
        border-bottom: 0;
    }

    td[data-label="Code"] {
        text-align: left;
    }

    .copy-btn {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 12px;
    }

    .last-updated {
        width: calc(100% - 24px);
        margin-top: 12px;
        font-size: .92rem;
    }

    .page-title {
        margin-top: 24px;
        font-size: 2rem;
    }

    .quick-summary,
    .feature-list {
        grid-template-columns: 1fr;
    }

    .toc,
    .note,
    .how-to,
    .methodology {
        padding: 15px;
    }

    .toc a {
        display: block;
        margin: 5px 0;
    }

    p,
    .lead {
        font-size: .97rem;
    }

    td {
        grid-template-columns: 34% minmax(0, 1fr);
        font-size: .93rem;
    }

    .share-btn {
        display: block;
        width: min(340px, 90%);
        margin: 9px auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition-duration: .01ms !important;
    }
}


/* --- additions: status tags, inline code, breadcrumb, related links --- */
.tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-height: 27px;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: .8rem;
    font-weight: 700;
    white-space: nowrap;
}

.tag.ok {
    background: #188b4d;
    color: #fff;
}

.tag.bad {
    background: #8a2b3a;
    color: #fff;
}

td code,
.note code {
    color: #fff;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', monospace;
    font-size: .94rem;
    font-weight: 700;
    overflow-wrap: anywhere;
}

.breadcrumb {
    max-width: 980px;
    margin: 18px auto 0;
    color: var(--muted);
    font-size: .9rem;
    text-align: center;
}

.breadcrumb a {
    text-decoration: none;
}

.related .feature-list h3 a {
    color: #fff;
    text-decoration: none;
}

.related .feature-list h3 a:hover,
.related .feature-list h3 a:focus-visible {
    color: var(--red);
}
