:root {
    --background: #07111f;
    --background-soft: #091827;

    --surface: #0c1c30;
    --surface-light: #122942;
    --surface-hover: #173652;

    --cyan: #65d9e8;
    --cyan-soft: #a2edf4;

    --pink: #f3a6c8;
    --pink-soft: #ffd0e2;

    --text: #eaf6fa;
    --text-soft: #a8bcc8;

    --border: rgba(255, 255, 255, 0.08);

    --radius-small: 14px;
    --radius: 20px;
    --radius-large: 28px;

    --shadow:
        0 18px 50px rgba(0, 0, 0, 0.25);

    --nav-height: 78px;
}


* {
    box-sizing: border-box;
}


html {
    min-height: 100%;
    background: var(--background);
}


body {
    margin: 0;

    min-height: 100vh;

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    background:
        radial-gradient(
            circle at 100% 0%,
            rgba(101, 217, 232, 0.12),
            transparent 32%
        ),
        radial-gradient(
            circle at 0% 30%,
            rgba(243, 166, 200, 0.07),
            transparent 25%
        ),
        linear-gradient(
            180deg,
            #07111f 0%,
            #081522 100%
        );

    color: var(--text);
}


button,
input,
select {
    font: inherit;
}


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


.app-shell {
    width: 100%;
    min-height: 100vh;

    padding:
        max(18px, env(safe-area-inset-top))
        18px
        calc(
            var(--nav-height)
            + 34px
            + env(safe-area-inset-bottom)
        );
}


.topbar {
    width: 100%;
    max-width: 1100px;

    margin: 0 auto 32px;

    display: flex;
    justify-content: space-between;
    align-items: center;
}


.topbar h1 {
    margin: 2px 0 0;

    font-size: clamp(23px, 6vw, 32px);
    letter-spacing: -0.04em;
}


.eyebrow {
    margin: 0;

    color: var(--cyan);

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 0.18em;
}


.profile-button {
    width: 45px;
    height: 45px;

    border: 1px solid rgba(101, 217, 232, 0.35);

    border-radius: 50%;

    color: var(--background);

    font-weight: 800;

    background:
        linear-gradient(
            145deg,
            var(--cyan),
            var(--pink)
        );
}


main {
    width: 100%;
    max-width: 1100px;

    margin: auto;
}


.welcome-section {
    margin-bottom: 26px;
}


.current-date {
    margin: 0 0 6px;

    color: var(--pink);

    font-size: 13px;
    font-weight: 700;
}


.welcome-section h2 {
    margin: 0;

    font-size: clamp(30px, 9vw, 52px);

    line-height: 1;

    letter-spacing: -0.055em;
}


.welcome-message {
    margin: 10px 0 0;

    color: var(--text-soft);

    font-size: 15px;
}


.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr;

    gap: 14px;
}


.dashboard-card {
    position: relative;

    overflow: hidden;

    padding: 20px;

    border: 1px solid var(--border);

    border-radius: var(--radius);

    background:
        linear-gradient(
            145deg,
            rgba(18, 41, 66, 0.85),
            rgba(12, 28, 48, 0.95)
        );

    box-shadow: var(--shadow);
}


.card-heading {
    display: flex;

    justify-content: space-between;
    align-items: flex-start;

    gap: 16px;

    margin-bottom: 18px;
}


.card-heading h3 {
    margin: 4px 0 0;

    font-size: 20px;
    letter-spacing: -0.025em;
}


.section-label {
    margin: 0;

    text-transform: uppercase;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 0.16em;
}


.section-label.cyan {
    color: var(--cyan);
}


.section-label.pink {
    color: var(--pink);
}


.task-progress {
    padding: 7px 10px;

    border: 1px solid rgba(101, 217, 232, 0.22);

    border-radius: 999px;

    color: var(--cyan);

    background: rgba(101, 217, 232, 0.08);

    font-size: 12px;
    font-weight: 700;
}


.task-list {
    display: flex;
    flex-direction: column;

    gap: 7px;
}


.task {
    width: 100%;

    display: flex;
    align-items: center;

    gap: 12px;

    padding: 12px;

    border: none;
    border-radius: var(--radius-small);

    color: var(--text);

    text-align: left;

    background: rgba(255, 255, 255, 0.035);
}


.task-checkbox {
    width: 22px;
    height: 22px;

    flex-shrink: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1.5px solid var(--cyan);
    border-radius: 50%;

    color: var(--background);

    font-size: 13px;
    font-weight: 900;
}


.task.completed .task-checkbox {
    background: var(--cyan);
}


.task.completed .task-name {
    color: var(--text-soft);

    text-decoration: line-through;
}


.task-info {
    min-width: 0;

    flex: 1;
}


.task-name {
    display: block;

    font-size: 14px;
    font-weight: 650;
}


.task-category {
    display: block;

    margin-top: 3px;

    color: var(--text-soft);

    font-size: 11px;
}


.text-button {
    margin-top: 13px;

    padding: 7px 0;

    border: none;

    color: var(--cyan);

    background: transparent;

    font-size: 13px;
    font-weight: 700;
}


.upcoming-list {
    display: flex;
    flex-direction: column;

    gap: 10px;
}


.upcoming-item {
    display: grid;

    grid-template-columns: 50px 1fr;

    align-items: center;

    gap: 12px;
}


.upcoming-date {
    padding: 9px 5px;

    border-radius: 12px;

    color: var(--pink);

    text-align: center;

    background: rgba(243, 166, 200, 0.08);

    font-size: 11px;
    font-weight: 800;
}


.upcoming-title {
    margin: 0;

    font-size: 14px;
    font-weight: 650;
}


.upcoming-description {
    margin: 3px 0 0;

    color: var(--text-soft);

    font-size: 11px;
}


.meal-card {
    display: flex;
    align-items: center;

    gap: 14px;

    padding: 13px;

    border-radius: var(--radius-small);

    background: rgba(101, 217, 232, 0.07);
}


.meal-icon {
    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 13px;

    background: rgba(101, 217, 232, 0.11);

    font-size: 25px;
}


.meal-name {
    margin: 0;

    font-size: 15px;
    font-weight: 700;
}


.muted {
    margin: 4px 0 0;

    color: var(--text-soft);

    font-size: 12px;
    line-height: 1.45;
}


.mini-actions {
    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 8px;

    margin-top: 12px;
}


.mini-actions button,
.quick-grid button {
    min-height: 44px;

    border: 1px solid var(--border);
    border-radius: 12px;

    color: var(--text);

    background: rgba(255, 255, 255, 0.035);

    font-size: 12px;
    font-weight: 650;
}


.chores-grid {
    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 8px;
}


.chore-item {
    display: flex;
    flex-direction: column;

    align-items: flex-start;

    gap: 7px;

    min-height: 106px;

    padding: 12px;

    border: 1px solid var(--border);
    border-radius: var(--radius-small);

    color: var(--text);

    text-align: left;

    background: rgba(255, 255, 255, 0.03);
}


.chore-icon {
    font-size: 19px;
}


.chore-item > span:nth-child(2) {
    font-size: 12px;
    font-weight: 700;
}


.chore-item small {
    color: var(--text-soft);

    font-size: 10px;
}


.memory-card {
    padding: 0;
}


.memory-card .card-heading {
    padding: 20px 20px 0;
}


.memory-photo {
    padding: 0 20px;
}


.memory-placeholder {
    aspect-ratio: 16 / 9;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 16px;

    color: rgba(255, 255, 255, 0.38);

    background:
        radial-gradient(
            circle at 30% 20%,
            rgba(243, 166, 200, 0.35),
            transparent 25%
        ),
        radial-gradient(
            circle at 80% 75%,
            rgba(101, 217, 232, 0.38),
            transparent 28%
        ),
        linear-gradient(
            145deg,
            #163451,
            #111d33
        );

    font-size: 12px;
}


.memory-content {
    padding: 16px 20px 20px;
}


.memory-date {
    margin: 0 0 5px;

    color: var(--pink);

    font-size: 11px;
    font-weight: 700;
}


.memory-title {
    margin: 0;

    font-size: 17px;
    font-weight: 750;
}


.quick-grid {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 8px;
}


.mobile-nav {
    position: fixed;

    z-index: 20;

    right: 12px;
    bottom:
        max(
            10px,
            env(safe-area-inset-bottom)
        );
    left: 12px;

    height: var(--nav-height);

    display: grid;

    grid-template-columns:
        1fr
        1fr
        64px
        1fr
        1fr;

    align-items: center;

    padding: 8px;

    border: 1px solid rgba(255, 255, 255, 0.1);

    border-radius: 24px;

    background: rgba(8, 21, 34, 0.92);

    box-shadow:
        0 16px 45px rgba(0, 0, 0, 0.45);

    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}


.nav-item {
    height: 100%;

    display: flex;
    flex-direction: column;

    align-items: center;
    justify-content: center;

    gap: 4px;

    border: none;

    color: var(--text-soft);

    background: transparent;

    font-size: 9px;
}


.nav-item span {
    font-size: 18px;
}


.nav-item.active {
    color: var(--cyan);
}


.nav-add {
    width: 52px;
    height: 52px;

    justify-self: center;

    border: none;
    border-radius: 18px;

    color: var(--background);

    background:
        linear-gradient(
            145deg,
            var(--cyan),
            var(--pink)
        );

    box-shadow:
        0 8px 24px rgba(101, 217, 232, 0.2);

    font-size: 28px;
    font-weight: 400;
}


.modal {
    position: fixed;

    z-index: 100;

    inset: 0;

    display: flex;
    align-items: flex-end;
}


.modal.hidden {
    display: none;
}


.modal-backdrop {
    position: absolute;

    inset: 0;

    background: rgba(0, 0, 0, 0.66);

    backdrop-filter: blur(4px);
}


.modal-sheet {
    position: relative;

    z-index: 2;

    width: 100%;

    padding:
        22px
        20px
        max(
            28px,
            env(safe-area-inset-bottom)
        );

    border:
        1px solid
        rgba(255, 255, 255, 0.1);

    border-bottom: 0;

    border-radius: 26px 26px 0 0;

    background: var(--surface);

    box-shadow:
        0 -15px 60px rgba(0, 0, 0, 0.45);
}


.modal-header {
    display: flex;

    justify-content: space-between;
    align-items: flex-start;

    margin-bottom: 22px;
}


.modal-header h3 {
    margin: 4px 0 0;

    font-size: 23px;
}


.close-button {
    width: 38px;
    height: 38px;

    border: none;
    border-radius: 50%;

    color: var(--text);

    background: var(--surface-light);

    font-size: 25px;
}


form {
    display: flex;
    flex-direction: column;

    gap: 9px;
}


label {
    margin-top: 6px;

    color: var(--text-soft);

    font-size: 11px;
    font-weight: 700;

    text-transform: uppercase;
    letter-spacing: 0.08em;
}


input,
select {
    width: 100%;

    min-height: 51px;

    padding: 0 14px;

    border:
        1px solid
        rgba(255, 255, 255, 0.12);

    border-radius: 13px;

    outline: none;

    color: var(--text);

    background: var(--surface-light);
}


input:focus,
select:focus {
    border-color: var(--cyan);
}


.primary-button {
    min-height: 52px;

    margin-top: 12px;

    border: none;

    border-radius: 14px;

    color: var(--background);

    background:
        linear-gradient(
            100deg,
            var(--cyan),
            var(--pink)
        );

    font-weight: 800;
}


/*
    Fold / Tablet
*/

@media (min-width: 700px) {

    .app-shell {
        padding-inline: 28px;
    }


    .dashboard-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));

        gap: 18px;
    }


    .today-card,
    .memory-card {
        grid-column: span 2;
    }


    .modal {
        align-items: center;
        justify-content: center;
    }


    .modal-sheet {
        max-width: 520px;

        border-radius: 26px;

        padding: 28px;
    }

}


/*
    Desktop eventually
*/

@media (min-width: 1000px) {

    .app-shell {
        padding-bottom: 45px;
    }


    .dashboard-grid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));
    }


    .today-card {
        grid-column: span 2;
    }


    .memory-card {
        grid-column: span 1;
    }


    .mobile-nav {
        width: 460px;

        right: auto;
        left: 50%;

        transform: translateX(-50%);
    }

}
