/* ============================================================
   TICKR — NEOBRUTALISM STYLE
   Real‑time clock & elapsed seconds, with NexQR's signature look
   ============================================================ */

/* ---------- RESET & BASE ---------- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --black: #000000;
    --white: #ffffff;
    --offwhite: #f5f3ee;
    --cream: #faf9f6;
    --yellow: #ffe600;
    --yellow-bright: #ffed4a;
    --blue: #0044ff;
    --blue-light: #1a6bff;
    --pink: #ff1493;
    --pink-light: #ff3fa4;
    --red: #ff0000;
    --orange: #ff6b00;
    --green: #00cc44;
    --gray: #e8e6e0;
    --dark: #1a1a1a;
    --border-w: 4px;
    --shadow-offset: 8px;
    --radius: 0px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    background: var(--cream);
    color: var(--black);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: var(--black);
    text-decoration: none;
}

/* ---------- TYPOGRAPHY ---------- */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.section-tag {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    background: var(--black);
    color: var(--white);
    padding: 0.4rem 1.2rem;
    border: 3px solid var(--black);
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(2rem, 5vw, 3.4rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 0.75rem;
}

.section-desc {
    font-size: 1.1rem;
    opacity: 0.75;
    max-width: 580px;
    margin: 0 auto 2rem;
    font-weight: 500;
}

/* ---------- UTILITY ---------- */
.section-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- SCROLL PROGRESS ---------- */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 6px;
    background: var(--yellow);
    width: 0%;
    z-index: 9999;
    border-bottom: 3px solid var(--black);
    transition: width 0.1s ease;
}

/* ---------- NAV ---------- */
#nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.8rem 2rem;
    background: var(--yellow);
    border-bottom: var(--border-w) solid var(--black);
    box-shadow: 0 6px 0 var(--black);
    transition: padding 0.2s ease, box-shadow 0.2s ease;
}

#nav.scrolled {
    padding: 0.4rem 2rem;
    box-shadow: 0 3px 0 var(--black);
}

.nav-logo-wrapper {
    font-size: 1.5rem;
}

.nav-logo {
    font-weight: 900;
    font-size: 1.6rem;
    letter-spacing: -0.04em;
    color: var(--black);
    display: flex;
    align-items: center;
    gap: 0.1rem;
}

.nav-logo span {
    background: var(--black);
    color: var(--yellow);
    padding: 0 0.2rem;
    transform: rotate(-2deg);
    display: inline-block;
}

.nav-cta {
    font-weight: 800;
    font-size: 0.9rem;
    background: var(--black);
    color: var(--white);
    padding: 0.6rem 1.4rem;
    border: 3px solid var(--black);
    box-shadow: 4px 4px 0 var(--black);
    transition: all 0.1s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-cta:hover {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0 var(--black);
}

/* ---------- HERO ---------- */
.hero {
    position: relative;
    padding: 10rem 1.5rem 5rem;
    text-align: center;
    background: var(--offwhite);
    border-bottom: var(--border-w) solid var(--black);
    overflow: hidden;
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#hero-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0.15;
    z-index: 0;
}

.hero-bg-blob {
    position: absolute;
    width: 500px;
    height: 500px;
    background: var(--yellow);
    border-radius: 50%;
    top: -200px;
    right: -150px;
    border: var(--border-w) solid var(--black);
    z-index: 0;
    opacity: 0.25;
}

.hero>*:not(canvas):not(.hero-bg-blob) {
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-block;
    background: var(--black);
    color: var(--white);
    font-weight: 800;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.4rem 1.2rem;
    border: 3px solid var(--black);
    margin-bottom: 1.5rem;
    box-shadow: 4px 4px 0 var(--black);
}

.hero h2 {
    font-size: clamp(2.8rem, 8vw, 5.2rem);
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.04em;
    max-width: 900px;
    margin: 0 auto 1rem;
}

.hero h2 em {
    font-style: normal;
    background: var(--yellow);
    padding: 0 0.3rem;
    box-shadow: 4px 4px 0 var(--black);
    border: 3px solid var(--black);
    display: inline-block;
    transform: rotate(-1deg);
}

.hero-sub {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 2.5rem;
    opacity: 0.7;
    font-weight: 500;
}

/* ---------- CLOCK SECTION ---------- */
.clock-section {
    padding: 5rem 0 4rem;
    background: var(--white);
    border-bottom: var(--border-w) solid var(--black);
}

.clock-card {
    max-width: 820px;
    margin: 2rem auto 0;
    background: var(--white);
    padding: 2.5rem 2.5rem 2rem;
    border: var(--border-w) solid var(--black);
    box-shadow: 10px 10px 0 var(--black);
    position: relative;
}

/* Digital Clock */
.clock-digital {
    font-family: 'Inter', 'Courier New', monospace;
    font-size: clamp(3.2rem, 10vw, 5.6rem);
    font-weight: 900;
    letter-spacing: 0.04em;
    background: var(--black);
    color: var(--yellow);
    padding: 0.2rem 0.8rem;
    border: var(--border-w) solid var(--black);
    box-shadow: 6px 6px 0 var(--black);
    text-align: center;
    margin-bottom: 0.6rem;
    line-height: 1.2;
}

.clock-date {
    font-size: 1.1rem;
    font-weight: 700;
    background: var(--offwhite);
    padding: 0.5rem 1rem;
    border: var(--border-w) solid var(--black);
    box-shadow: 4px 4px 0 var(--black);
    text-align: center;
    margin-bottom: 0.8rem;
}

.device-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    opacity: 0.6;
    margin-bottom: 1.8rem;
}

/* Year Selector */
.year-selector {
    margin: 1.2rem 0 1.8rem;
}

.selector-label {
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

#yearSelect {
    font-family: var(--font);
    font-weight: 800;
    font-size: 1.1rem;
    padding: 0.7rem 1.2rem;
    background: var(--offwhite);
    border: var(--border-w) solid var(--black);
    box-shadow: 4px 4px 0 var(--black);
    cursor: pointer;
    width: 100%;
    max-width: 300px;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.2rem;
    padding-right: 3rem;
}

#yearSelect:focus {
    outline: none;
    box-shadow: 2px 2px 0 var(--black);
    transform: translate(2px, 2px);
}

/* Delta Seconds */
.delta-seconds {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: var(--border-w) solid var(--black);
}

.delta-seconds strong {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 1rem;
    font-weight: 800;
}

.delta-value {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 900;
    background: var(--yellow);
    padding: 0.3rem 1rem;
    border: var(--border-w) solid var(--black);
    box-shadow: 6px 6px 0 var(--black);
    display: inline-block;
    margin: 0.8rem 0 0.4rem;
    word-break: break-word;
}

.delta-note {
    font-weight: 600;
    opacity: 0.7;
    font-size: 0.9rem;
    margin-bottom: 0.6rem;
}

.delta-note strong {
    background: var(--black);
    color: var(--white);
    padding: 0.1rem 0.4rem;
    font-weight: 800;
}

.tool-note {
    font-size: 0.85rem;
    opacity: 0.6;
    font-weight: 500;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3rem;
    margin-top: 1.2rem;
    padding-top: 1rem;
    border-top: 3px dashed var(--gray);
}

.tool-note i {
    margin-right: 0.3rem;
}

.tool-note small {
    font-weight: 400;
    opacity: 0.7;
}

/* ---------- DONATION (in clock card) ---------- */
.donation-options {
    margin-top: 2rem;
    padding-top: 1.8rem;
    border-top: var(--border-w) solid var(--black);
    text-align: center;
}

.donation-label {
    font-weight: 800;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.donation-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    justify-content: center;
}

.donate-btn {
    padding: 0.6rem 1.6rem;
    font-weight: 700;
    font-size: 0.85rem;
    border: var(--border-w) solid var(--black);
    box-shadow: 4px 4px 0 var(--black);
    transition: all 0.1s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    font-family: var(--font);
    cursor: pointer;
}

.donate-btn:hover {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0 var(--black);
}

.donate-btn:first-child {
    background: var(--orange);
    color: #fff;
}

.donate-btn:nth-child(2) {
    background: #13c3ff;
    color: #fff;
}

.donate-btn:nth-child(3) {
    background: var(--black);
    color: var(--white);
}

.donation-note {
    margin-top: 0.8rem;
    font-size: 0.8rem;
    opacity: 0.6;
}

/* ---------- FEATURES ---------- */
.features-section {
    padding: 5rem 0 4rem;
    background: var(--offwhite);
    border-bottom: var(--border-w) solid var(--black);
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.why-card {
    background: var(--white);
    padding: 2rem 1.8rem;
    border: var(--border-w) solid var(--black);
    box-shadow: 8px 8px 0 var(--black);
    transition: all 0.15s ease;
}

.why-card:hover {
    transform: translate(-3px, -3px);
    box-shadow: 12px 12px 0 var(--black);
}

.why-icon {
    font-size: 2.2rem;
    background: var(--yellow);
    width: 4rem;
    height: 4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: var(--border-w) solid var(--black);
    box-shadow: 4px 4px 0 var(--black);
    margin-bottom: 1.2rem;
}

.why-card h3 {
    font-size: 1.25rem;
    font-weight: 900;
    margin-bottom: 0.4rem;
}

.why-card p {
    font-weight: 500;
    opacity: 0.7;
    font-size: 0.95rem;
}

/* ---------- HOW IT WORKS ---------- */
.how-section {
    padding: 5rem 0 4rem;
    background: var(--white);
    border-bottom: var(--border-w) solid var(--black);
}

.how-grid-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
    gap: 1.5rem;
    margin-top: 2rem;
}

.how-card {
    flex: 1;
    min-width: 200px;
    max-width: 300px;
    background: var(--offwhite);
    padding: 2rem 1.8rem;
    border: var(--border-w) solid var(--black);
    box-shadow: 8px 8px 0 var(--black);
    text-align: center;
    transition: all 0.15s ease;
}

.how-card:hover {
    transform: translate(-3px, -3px);
    box-shadow: 12px 12px 0 var(--black);
}

.how-emoji {
    font-size: 2.4rem;
    display: block;
    margin: 0.5rem auto;
    background: var(--yellow);
    width: 4rem;
    height: 4rem;
    line-height: 4rem;
    text-align: center;
    border: var(--border-w) solid var(--black);
    box-shadow: 4px 4px 0 var(--black);
}

.how-card h3 {
    font-size: 1.1rem;
    font-weight: 900;
    margin: 0.8rem 0 0.3rem;
}

.how-card p {
    font-weight: 500;
    opacity: 0.7;
    font-size: 0.9rem;
}

/* ---------- FAQ ---------- */
.faq-section {
    padding: 5rem 0 4rem;
    background: var(--offwhite);
    border-bottom: var(--border-w) solid var(--black);
}

.faq-list {
    max-width: 740px;
    margin: 2rem auto 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.faq-item {
    background: var(--white);
    border: var(--border-w) solid var(--black);
    box-shadow: 6px 6px 0 var(--black);
    overflow: hidden;
}

.faq-q {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 1.5rem;
    font-weight: 800;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.15s ease;
    user-select: none;
}

.faq-q:hover {
    background: var(--yellow);
}

.faq-icon {
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--black);
    color: var(--white);
    border: 3px solid var(--black);
    font-size: 0.8rem;
    transition: transform 0.2s ease;
}

.faq-item.open .faq-icon {
    transform: rotate(45deg);
}

.faq-a {
    padding: 0 1.5rem 1.2rem;
    font-weight: 500;
    opacity: 0.8;
    line-height: 1.6;
    display: none;
}

.faq-item.open .faq-a {
    display: block;
}

/* ---------- FOOTER ---------- */
footer {
    padding: 2.5rem 1.5rem;
    background: var(--black);
    color: var(--white);
    text-align: center;
    border-top: var(--border-w) solid var(--black);
    font-weight: 500;
    font-size: 0.9rem;
}

footer a {
    color: var(--yellow);
    font-weight: 700;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    transition: border-color 0.15s ease;
}

footer a:hover {
    border-bottom-color: var(--yellow);
}

footer i.fa-heart {
    color: var(--pink);
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 768px) {
    #nav {
        padding: 0.6rem 1rem;
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    #nav.scrolled {
        padding: 0.4rem 1rem;
    }

    .nav-logo {
        font-size: 1.3rem;
    }

    .nav-cta {
        font-size: 0.75rem;
        padding: 0.4rem 1rem;
    }

    .hero {
        padding: 8rem 1rem 3rem;
        min-height: 60vh;
    }

    .hero h2 {
        font-size: clamp(2rem, 10vw, 3rem);
    }

    .hero-sub {
        font-size: 1rem;
    }

    .clock-card {
        padding: 1.5rem;
    }

    .clock-digital {
        font-size: clamp(2.4rem, 8vw, 3.8rem);
    }

    .delta-value {
        font-size: clamp(1.6rem, 4vw, 2.6rem);
    }

    #yearSelect {
        max-width: 100%;
    }

    .why-grid {
        grid-template-columns: 1fr;
    }

    .how-grid-inner {
        flex-direction: column;
        align-items: center;
    }

    .how-card {
        max-width: 100%;
        width: 100%;
    }

    .donation-buttons {
        flex-direction: column;
        align-items: center;
    }

    .donate-btn {
        width: 100%;
        justify-content: center;
    }

    .faq-q {
        font-size: 0.9rem;
        padding: 1rem;
    }

    .faq-a {
        padding: 0 1rem 1rem;
        font-size: 0.9rem;
    }

    .section-title {
        font-size: 1.8rem;
    }
}

@media (max-width: 480px) {
    .hero h2 em {
        display: inline;
        transform: none;
        box-shadow: 3px 3px 0 var(--black);
    }

    .clock-digital {
        font-size: clamp(2rem, 7vw, 3rem);
        padding: 0.1rem 0.4rem;
    }

    .clock-date {
        font-size: 0.9rem;
    }

    .delta-value {
        font-size: 1.4rem;
        padding: 0.2rem 0.6rem;
    }

    .section-tag {
        font-size: 0.65rem;
        padding: 0.3rem 0.8rem;
    }
}

/* ---------- SCROLLBAR ---------- */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: var(--offwhite);
    border-left: 3px solid var(--black);
}

::-webkit-scrollbar-thumb {
    background: var(--yellow);
    border: 3px solid var(--black);
    box-shadow: inset 0 0 0 2px var(--black);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--yellow-bright);
}

/* ---------- SELECTION ---------- */
::selection {
    background: var(--yellow);
    color: var(--black);
}