:root {
    --bg: #f5f7fb;
    --card: rgba(255, 255, 255, 0.82);
    --text: #172033;
    --muted: #677187;
    --border: rgba(23, 32, 51, 0.1);
    --accent: #2457ff;
    --danger: #d92d20;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(36, 87, 255, 0.18), transparent 36rem),
        linear-gradient(180deg, #ffffff 0%, var(--bg) 55%);
}

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

.topbar {
    width: min(100% - 32px, 980px);
    margin: 20px auto 0;
    padding: 14px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 22px;
    background: var(--card);
    backdrop-filter: blur(18px);
    box-shadow: 0 16px 50px rgba(23, 32, 51, 0.08);
}

.logo {
    font-weight: 800;
    letter-spacing: -0.03em;
}

.stack {
    color: var(--muted);
    font-size: 14px;
}

.container {
    width: min(100% - 32px, 980px);
    margin: 42px auto;
}

.hero {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 24px;
    align-items: center;
    margin-bottom: 24px;
}

.eyebrow {
    margin: 0 0 10px;
    color: var(--accent);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.09em;
}

h1 {
    margin: 0;
    font-size: clamp(36px, 6vw, 64px);
    letter-spacing: -0.06em;
    line-height: 0.96;
}

.description {
    max-width: 650px;
    color: var(--muted);
    font-size: 18px;
    line-height: 1.65;
}

.stats {
    min-width: 150px;
    padding: 22px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 12px;
    border-radius: 26px;
    background: #101828;
    color: white;
    box-shadow: 0 18px 60px rgba(16, 24, 40, 0.22);
}

.stats strong {
    font-size: 34px;
}

.stats span {
    color: rgba(255, 255, 255, 0.7);
    align-self: end;
}

.card,
.task-card,
.empty {
    border: 1px solid var(--border);
    border-radius: 26px;
    background: var(--card);
    backdrop-filter: blur(18px);
    box-shadow: 0 18px 60px rgba(23, 32, 51, 0.08);
}

.card {
    padding: 14px;
    margin-bottom: 18px;
}

.task-form {
    display: flex;
    gap: 12px;
}

input {
    flex: 1;
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 15px 16px;
    font-size: 16px;
    outline: none;
    background: white;
}

input:focus {
    border-color: rgba(36, 87, 255, 0.45);
    box-shadow: 0 0 0 4px rgba(36, 87, 255, 0.12);
}

button {
    border: 0;
    border-radius: 18px;
    padding: 14px 18px;
    color: white;
    background: var(--accent);
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.16s ease, opacity 0.16s ease;
}

button:hover {
    transform: translateY(-1px);
}

.secondary {
    color: var(--text);
    background: #eef2ff;
}

.danger {
    background: #fff0ee;
    color: var(--danger);
}

.task-list {
    display: grid;
    gap: 14px;
}

.task-card {
    padding: 18px;
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: center;
}

.task-card h2 {
    margin: 0 0 6px;
    font-size: 20px;
}

.task-card p,
.empty p {
    margin: 0;
    color: var(--muted);
}

.task-card.done h2 {
    text-decoration: line-through;
    color: var(--muted);
}

.actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.empty {
    padding: 26px;
    text-align: center;
}

.empty h2 {
    margin: 0 0 8px;
}

@media (max-width: 720px) {
    .topbar,
    .hero,
    .task-form,
    .task-card {
        display: grid;
    }

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

    .actions {
        justify-content: stretch;
    }

    .actions form,
    button {
        width: 100%;
    }
}
