/* ============================================================
   onedone.me — the page-a-day pad
   A warm paper sheet catching morning light in a cool room.
   Display: Newsreader (italic = the day's voice) · UI: Hanken Grotesk
   Honey is spent in one place: the "done" tick.
   ============================================================ */

:root {
    /* the room — cool, quiet daylight */
    --room:   #e7ebed;
    --ink:    #2b2620;
    --muted:  #6e6656;
    --faint:  #a49a86;

    /* the paper — warm, catching the light */
    --card:      #f5efe2;
    --card-2:    #efe7d6;   /* binding / shade */
    --card-line: #e2d9c6;
    --card-ink:  #2b2620;

    /* the one accent: honey / first light */
    --honey:     #cf9646;
    --honey-ink: #9a6717;
    --honey-soft: rgba(207, 150, 70, 0.16);

    --strike: #b9ae98;
    --error:  #b0472f;
    --shadow: 0 34px 60px -30px rgba(60, 50, 30, 0.40);
    --shadow-lift: 0 10px 26px -16px rgba(60, 50, 30, 0.45);
}

@media (prefers-color-scheme: dark) {
    :root {
        --room:   #13151a;
        --ink:    #e8e3d6;
        --muted:  #9a9384;
        --faint:  #625c4e;

        --card:      #211f18;
        --card-2:    #1a1812;
        --card-line: #33301f;
        --card-ink:  #ece6d6;

        --honey:     #e0ad5c;
        --honey-ink: #e6bd76;
        --honey-soft: rgba(224, 173, 92, 0.18);

        --strike: #5c564a;
        --shadow: 0 44px 80px -34px rgba(0, 0, 0, 0.8);
        --shadow-lift: 0 12px 30px -16px rgba(0, 0, 0, 0.7);
    }
}

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

html { scroll-behavior: smooth; }

body {
    font-family: 'Hanken Grotesk', system-ui, -apple-system, sans-serif;
    background-color: var(--room);
    /* faint morning light pooling toward the pad */
    background-image: radial-gradient(70% 55% at 50% 32%, var(--honey-soft) 0%, transparent 68%);
    color: var(--ink);
    line-height: 1.6;
    font-size: 17px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

::selection { background: var(--honey-soft); color: var(--honey-ink); }
a { color: var(--ink); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--honey-ink); }
:focus-visible { outline: 2px solid var(--honey); outline-offset: 3px; border-radius: 5px; }

/* ---------- Wordmark ---------- */
.wordmark {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Newsreader', serif;
    font-size: 1.35rem;
    font-weight: 500;
    color: var(--ink);
    letter-spacing: -0.01em;
}
.wordmark:hover { color: var(--ink); }
.wordmark em { font-style: italic; }
.mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px; height: 22px;
    border: 1.5px solid var(--honey);
    border-radius: 7px;
    color: var(--honey);
    flex-shrink: 0;
}
.mark svg { width: 14px; height: 14px; }

/* ---------- Header ---------- */
.site-header {
    max-width: 1080px; width: 100%;
    margin: 0 auto;
    padding: 1.75rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.header-cta {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--muted);
    padding: 0.5rem 1rem;
    border: 1px solid var(--faint);
    border-radius: 999px;
    transition: color 0.2s ease, border-color 0.2s ease;
}
.header-cta:hover { color: var(--ink); border-color: var(--ink); }

/* ---------- Layout ---------- */
main { flex: 1; width: 100%; margin: 0 auto; padding: 1rem 1.5rem 4rem; }

/* ---------- Hero ---------- */
.hero {
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
    padding-top: 2.5rem;
}

.eyebrow {
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--honey-ink);
    margin-bottom: 1.1rem;
    animation: rise 0.6s ease both;
}

h1 {
    font-family: 'Newsreader', serif;
    font-weight: 400;
    font-size: clamp(2.5rem, 8vw, 3.4rem);
    line-height: 1.05;
    letter-spacing: -0.015em;
    color: var(--ink);
    margin-bottom: 2.5rem;
    animation: rise 0.6s 0.05s ease both;
}
h1 em { font-style: italic; }

/* ---------- The pad ---------- */
.pad {
    position: relative;
    margin: 0 auto 2.5rem;
    max-width: 400px;
    animation: rise 0.7s 0.12s ease both;
}
/* two sheets peeking beneath — the rest of the pad */
.pad::before,
.pad::after {
    content: '';
    position: absolute;
    left: 0; right: 0; bottom: 0;
    height: 96%;
    background: var(--card);
    border: 1px solid var(--card-line);
    border-radius: 3px 3px 12px 12px;
    z-index: 0;
}
.pad::before { transform: translate(-6px, 12px) rotate(-1.4deg); opacity: 0.55; }
.pad::after  { transform: translate(5px, 7px) rotate(1deg);   opacity: 0.8; }

.sheet {
    position: relative;
    z-index: 1;
    background: var(--card);
    border: 1px solid var(--card-line);
    border-radius: 3px 3px 14px 14px;
    padding: 1.35rem 1.35rem 1rem;
    box-shadow: var(--shadow);
    transform-origin: top center;
    color: var(--card-ink);
}
/* bound top edge */
.sheet::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 8px;
    background: var(--card-2);
    border-radius: 3px 3px 0 0;
}
/* perforation: holes punched through to the room */
.perf {
    position: absolute;
    top: 15px; left: 10px; right: 10px;
    height: 6px;
    background-image: radial-gradient(circle at center, var(--room) 0 2.4px, transparent 2.8px);
    background-size: 13px 6px;
    background-repeat: repeat-x;
    background-position: center;
    opacity: 0.9;
}

.sheet-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin: 0.6rem 0 0.95rem;
}
.date {
    font-family: 'Newsreader', serif;
    font-style: italic;
    font-size: 1rem;
    color: var(--honey-ink);
}
.sheet-tag {
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: var(--faint);
}

/* the tickable action */
.task {
    display: flex;
    align-items: flex-start;
    gap: 0.95rem;
    width: 100%;
    text-align: left;
    background: transparent;
    border: none;
    padding: 0.25rem 0;
    cursor: pointer;
    font: inherit;
    color: inherit;
}
.box {
    flex-shrink: 0;
    width: 30px; height: 30px;
    margin-top: 0.1rem;
    border: 2px solid var(--honey);
    border-radius: 8px;
    color: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.25s ease, background 0.25s ease, color 0.25s ease, transform 0.2s ease;
    /* breathing ring — an affordance that says "tap me" */
    animation: breathe 2.6s ease-in-out 1s infinite;
}
.box svg { width: 19px; height: 19px; }
.box .tick {
    stroke-dasharray: 40;
    stroke-dashoffset: 40;
    transition: stroke-dashoffset 0.42s ease 0.06s;
}
.task:hover .box { transform: scale(1.06); animation: none; }
.sheet.is-done .box { animation: none; }

@keyframes breathe {
    0%   { box-shadow: 0 0 0 0 var(--honey-soft); }
    70%  { box-shadow: 0 0 0 9px rgba(207, 150, 70, 0); }
    100% { box-shadow: 0 0 0 0 rgba(207, 150, 70, 0); }
}

.task-text {
    font-family: 'Newsreader', serif;
    font-style: italic;
    font-weight: 400;
    font-size: clamp(1.2rem, 4.4vw, 1.42rem);
    line-height: 1.32;
    color: var(--card-ink);
    transition: color 0.35s ease;
}
.task-text.swap { animation: swap 0.42s ease; }

/* done */
.sheet.is-done .box { border-color: var(--honey); background: var(--honey); color: var(--card); }
.sheet.is-done .box .tick { stroke-dashoffset: 0; }
.sheet.is-done .task-text {
    color: var(--strike);
    text-decoration: line-through;
    text-decoration-color: var(--strike);
    text-decoration-thickness: 1.5px;
}

.sheet-foot {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1rem;
    padding-top: 0.8rem;
    border-top: 1px dashed var(--card-line);
    min-height: 1.6rem;
}
.done-note {
    font-size: 0.9rem;
    color: var(--honey-ink);
    text-align: left;
    opacity: 0;
    transform: translateY(3px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}
.sheet.is-done .done-note { opacity: 1; transform: none; }

.next {
    flex-shrink: 0;
    margin-left: auto;
    background: transparent;
    border: none;
    color: var(--faint);
    font: inherit;
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    cursor: pointer;
    padding: 0.2rem 0;
    opacity: 0.6;
    transition: color 0.2s ease, opacity 0.2s ease;
}
.next:hover { color: var(--muted); opacity: 1; }

/* tear-off / settle animation */
.sheet.tearing { animation: tearoff 0.44s ease forwards; }
.sheet.settling { animation: settle 0.42s ease; }
@keyframes tearoff {
    to { transform: translateY(-26px) rotate(-2.2deg); opacity: 0; }
}
@keyframes settle {
    from { transform: translateY(-10px); opacity: 0; }
    to   { transform: none; opacity: 1; }
}

/* ---------- Pitch + form ---------- */
.pitch {
    font-size: 1.05rem;
    color: var(--muted);
    max-width: 27rem;
    margin: 0 auto 1.75rem;
    animation: rise 0.7s 0.18s ease both;
}

#waitlist-form { max-width: 400px; margin: 0 auto; animation: rise 0.7s 0.22s ease both; }
.form-group { display: flex; gap: 0.55rem; }
input[type="email"] {
    flex: 1; min-width: 0;
    padding: 0.85rem 1.2rem;
    font-size: 1rem;
    font-family: 'Hanken Grotesk', sans-serif;
    background: var(--card);
    border: 1px solid var(--card-line);
    border-radius: 11px;
    color: var(--card-ink);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
input[type="email"]:focus {
    outline: none;
    border-color: var(--honey);
    box-shadow: 0 0 0 4px var(--honey-soft);
}
input[type="email"]::placeholder { color: var(--faint); }

button[type="submit"] {
    padding: 0.85rem 1.5rem;
    font-size: 1rem;
    font-family: 'Hanken Grotesk', sans-serif;
    font-weight: 600;
    background: var(--ink);
    color: var(--room);
    border: none;
    border-radius: 11px;
    cursor: pointer;
    white-space: nowrap;
    transition: transform 0.2s ease, opacity 0.2s ease;
    box-shadow: var(--shadow-lift);
}
button[type="submit"]:hover { transform: translateY(-2px); }
button[type="submit"]:disabled { opacity: 0.55; cursor: wait; transform: none; }

.form-message { font-size: 0.92rem; min-height: 1.3rem; margin-top: 0.85rem; }
.form-message.success { color: var(--honey-ink); }
.form-message.error { color: var(--error); }

.values {
    margin-top: 1.5rem;
    font-size: 0.82rem;
    letter-spacing: 0.05em;
    color: var(--faint);
    animation: rise 0.7s 0.26s ease both;
}

/* ---------- FAQ ---------- */
.faq { max-width: 660px; margin: 5.5rem auto 3rem; }
.faq > h2 {
    font-family: 'Newsreader', serif;
    font-weight: 400;
    font-size: clamp(1.7rem, 4vw, 2.2rem);
    letter-spacing: -0.015em;
    text-align: center;
    color: var(--ink);
    margin-bottom: 2rem;
}
.faq-item { border-bottom: 1px solid var(--faint); }
.faq-item summary {
    font-size: 1.05rem;
    font-weight: 500;
    color: var(--ink);
    cursor: pointer;
    padding: 1.2rem 0;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    transition: color 0.2s ease;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { color: var(--honey-ink); }
.faq-item summary::after {
    content: '';
    width: 9px; height: 9px;
    border-right: 2px solid var(--faint);
    border-bottom: 2px solid var(--faint);
    transform: rotate(45deg);
    transition: transform 0.3s ease, border-color 0.2s ease;
    flex-shrink: 0; margin-right: 3px;
}
.faq-item[open] summary::after { transform: rotate(-135deg); border-color: var(--honey); }
.faq-item p { color: var(--muted); font-size: 1rem; padding: 0 0 1.35rem; max-width: 92%; }

/* ---------- Footer ---------- */
footer {
    border-top: 1px solid var(--faint);
    padding: 2.5rem 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}
footer p { color: var(--faint); font-size: 0.85rem; }
footer a { color: var(--muted); }
footer a:hover { color: var(--honey-ink); }

/* ---------- Motion ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes swap { 0% { opacity: 0; transform: translateY(6px); } 100% { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; }
    html { scroll-behavior: auto; }
    .sheet.tearing { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 560px) {
    .site-header { padding: 1.25rem 1.5rem; }
    .header-cta { display: none; }
    .sheet-foot { flex-wrap: wrap; }
    .form-group { flex-direction: column; }
    button[type="submit"] { width: 100%; }
}
