:root {
    color-scheme: light;
    --page-background: #f7f6ef;
    --paper: #fffef9;
    --ink: #294337;
    --muted: #6a796d;
    --green: #426b50;
    --green-hover: #335a40;
    --mint: #e8efdf;
    --line: #e2e4d7;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--page-background);
    color: var(--ink);
    font-family: "Avenir Next", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

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

button {
    font: inherit;
}

button:focus-visible, a:focus-visible {
    outline: 3px solid #81a889;
    outline-offset: 5px;
}

.icon-library {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}

.icon {
    width: 20px;
    height: 20px;
    flex: none;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.site-header {
    border-bottom: 1px solid var(--line);
    background: var(--paper);
}

.header-inner {
    max-width: 1200px;
    margin: auto;
    padding: 23px 36px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--ink);
    text-decoration: none;
    white-space: nowrap;
}

.brand-mark {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    background: #f4e6d4;
    color: #9a5b32;
}

.brand-mark .icon {
    width: 25px;
    height: 25px;
}

.brand-wordmark {
    display: inline-flex;
    align-items: baseline;
    gap: 7px;
    letter-spacing: -0.6px;
}

.brand-name {
    color: var(--green);
    font-size: 24px;
    font-weight: 850;
}

.brand-subtitle {
    color: var(--muted);
    font-size: 16px;
    font-weight: 650;
}

.account-area {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
}

.child-avatar {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--mint);
    color: var(--green);
    font-weight: 800;
}

.child-name {
    font-weight: 600;
}

.account-divider {
    width: 1px;
    height: 18px;
    margin: 0 10px;
    background: var(--line);
}

.parent-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--muted);
}

.parent-label .icon {
    width: 16px;
    height: 16px;
}

.home-main {
    max-width: 1200px;
    margin: auto;
    padding: 42px 36px 32px;
}

.course-list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin: 0 0 25px;
    padding: 0;
    list-style: none;
}

.course-item {
    min-width: 0;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--paper);
}

.course-content {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    min-height: 64px;
    padding: 15px 17px;
    color: inherit;
    text-decoration: none;
}

.course-content[href]:hover {
    background: #e8efdf66;
    border-radius: 15px;
}

.course-item.is-selected {
    background: var(--mint);
    border-color: #a8bea0;
}

.course-symbol {
    display: grid;
    place-items: center;
    min-width: 34px;
    height: 34px;
    color: var(--green);
    font-size: 25px;
    font-weight: 800;
    letter-spacing: -1px;
}

.course-symbol .icon {
    width: 25px;
    height: 25px;
}

.course-item strong {
    display: block;
    font-size: 14px;
    font-weight: 750;
}

.picture-stage {
    display: grid;
    grid-template-columns: 1.25fr 1fr;
    min-height: 450px;
    overflow: hidden;
    border: 1px solid #dedfcd;
    border-radius: 29px;
    background: var(--paper);
    box-shadow: 0 12px 36px #354d3208;
}

.alphabet-art {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 450px;
    padding: 38px 24px 100px;
    background: #e9eedf;
    overflow: hidden;
}

.alphabet-pair {
    display: flex;
    align-items: end;
    justify-content: center;
    gap: 32px;
    text-align: center;
}

.alphabet-pair > div {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.alphabet-capital, .alphabet-small {
    display: block;
    font-size: clamp(120px, 15vw, 176px);
    font-weight: 750;
    line-height: 1.1;
}

.alphabet-capital {
    color: #a66a4c;
}

.alphabet-small {
    color: var(--green);
}

.letter-caption {
    margin-top: 10px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 650;
}

.alphabet-mentor {
    position: absolute;
    left: 24px;
    bottom: 18px;
    width: 78px;
    height: 84px;
    border: 4px solid var(--paper);
    border-radius: 50%;
    object-fit: cover;
    object-position: 2% center;
}

.stage-picture {
    position: relative;
    min-width: 0;
    background: #f3f0d9;
}

.stage-picture img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 450px;
    object-fit: cover;
    object-position: 24% center;
}

.stage-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: 36px 38px;
}

.lesson-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 32px;
    font-size: 12px;
}

.lesson-label {
    padding: 6px 11px;
    border-radius: 9px;
    background: #edf2e6;
    color: var(--green);
    font-weight: 750;
}

.lesson-time {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--muted);
}

.lesson-time .icon {
    width: 15px;
    height: 15px;
}

.lesson-title {
    margin: 0 0 32px;
    font-size: clamp(32px, 3.6vw, 43px);
    line-height: 1.35;
    letter-spacing: -1.5px;
    font-weight: 800;
    word-break: keep-all;
}

.start-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 19px;
    align-self: flex-start;
    min-height: 56px;
    padding: 14px 24px;
    border: 0;
    border-radius: 15px;
    background: var(--green);
    color: var(--paper);
    box-shadow: 0 4px 0 #294b32;
    cursor: pointer;
    text-decoration: none;
    font-weight: 750;
    font-size: 16px;
    transition: background-color 120ms, transform 120ms, box-shadow 120ms;
}

.start-button:hover {
    background: var(--green-hover);
}

.start-button:active {
    transform: translateY(2px);
    box-shadow: 0 2px 0 #294b32;
}

@media (max-width: 900px) {
    .header-inner {
        padding: 21px 26px;
    }

    .home-main {
        padding: 32px 26px;
    }

    .course-content {
        padding: 13px 11px;
        gap: 8px;
    }

    .picture-stage {
        grid-template-columns: 1.1fr 1fr;
        min-height: 410px;
    }

    .stage-picture img {
        min-height: 410px;
        object-position: 18% center;
    }

    .stage-content {
        padding: 28px;
    }

    .start-button {
        gap: 12px;
        padding: 14px 18px;
        font-size: 15px;
    }
}

@media (max-width: 640px) {
    .header-inner {
        padding: 18px;
        gap: 12px;
    }

    .brand {
        gap: 8px;
    }

    .brand-mark {
        width: 34px;
        height: 34px;
        border-radius: 12px;
    }

    .brand-mark .icon {
        width: 22px;
        height: 22px;
    }

    .brand-name {
        font-size: 21px;
    }

    .brand-subtitle {
        font-size: 13px;
    }

    .brand-wordmark {
        gap: 5px;
    }

    .child-name, .account-divider {
        display: none;
    }

    .account-area {
        gap: 12px;
    }

    .parent-label {
        font-size: 12px;
    }

    .home-main {
        padding: 27px 18px 24px;
    }

    .course-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 20px;
    }

    .course-content {
        padding: 11px 13px;
    }

    .course-item strong {
        font-size: 13px;
    }

    .picture-stage {
        grid-template-columns: 1fr;
        border-radius: 23px;
    }

    .alphabet-art {
        min-height: 280px;
        padding: 24px 20px 76px;
    }

    .alphabet-capital, .alphabet-small {
        font-size: 120px;
    }

    .alphabet-pair {
        gap: 28px;
    }

    .alphabet-mentor {
        left: 18px;
        bottom: 12px;
        width: 60px;
        height: 66px;
    }

    .stage-picture img {
        height: 265px;
        min-height: 0;
        object-position: 24% 45%;
    }

    .stage-content {
        padding: 24px;
    }

    .lesson-meta {
        margin-bottom: 23px;
    }

    .lesson-title {
        margin-bottom: 24px;
        font-size: 34px;
    }

    .start-button {
        width: 100%;
        font-size: 16px;
    }

}

@media (prefers-reduced-motion: reduce) {
    .start-button {
        transition: none;
    }
}
