/* [목적별 진입과 홈의 위계 / Purposeful entry and home hierarchy]
   큰 제목과 여백으로 각 섹션의 행동을 구분합니다.
   Distinguish each section's action through readable headings and space. */
.home-pathways {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 32px;
    padding-block: 36px;
    border-bottom: 1px solid #deded9;
}

.home-pathways > a {
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 72px;
    color: #202220;
}

.home-pathways > a > span {
    flex: 1;
}

.home-pathways strong,
.home-participation strong {
    display: block;
    font-size: 20px;
    font-weight: 650;
    line-height: 1.5;
}

.home-pathways small,
.home-participation small {
    display: block;
    margin-top: 5px;
    font-size: 16px;
    line-height: 1.6;
    color: #63655e;
}

.home-section-label {
    margin-bottom: 18px;
    color: #5d625c;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.6;
}

.home-booking,
#discover-programs,
#sejong-news {
    padding-block: 104px;
}

.home-booking .section-heading h2,
#discover-programs .section-heading h2,
#sejong-news .section-heading h2 {
    font-size: clamp(36px, 4vw, 58px);
    line-height: 1.2;
    letter-spacing: -0.045em;
    font-weight: 650;
    word-break: keep-all;
}

.home-booking .section-description,
#discover-programs .section-description,
#sejong-news .section-description {
    margin-top: 22px;
    font-size: 18px;
    line-height: 1.7;
}

/* [날짜와 프로그램 선택 / Date and program selection]
   달력은 안정된 높이를 유지하고 프로그램 목록만 내부에서 스크롤합니다.
   Keep a stable calendar area while the program list scrolls independently. */
.quick-booking-layout {
    display: grid;
    grid-template-columns: minmax(360px, 0.86fr) minmax(0, 1.14fr);
    gap: 64px;
    margin-top: 44px;
    padding: 40px;
    background: #f5f5f1;
    border-radius: 24px;
}

.quick-calendar,
.quick-booking-choices {
    min-width: 0;
}

.quick-calendar-heading,
.quick-day-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    min-height: 56px;
    margin-bottom: 24px;
}

.quick-calendar-heading h3 {
    font-size: 28px;
    font-weight: 650;
    letter-spacing: -0.025em;
}

.quick-month-controls {
    display: flex;
    align-items: center;
    gap: 4px;
}

.quick-month-controls button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    min-height: 48px;
    padding: 8px;
    border: 1px solid #deded9;
    border-radius: 50%;
    background: #fff;
    font-size: 16px;
    color: #292d29;
}

.quick-calendar-week,
.quick-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
}

.quick-calendar-week span {
    padding-block: 10px;
    text-align: center;
    font-size: 16px;
    color: #646961;
}

.quick-calendar-grid {
    min-height: 336px;
    align-content: start;
}

.quick-date,
.quick-calendar-blank {
    min-height: 56px;
}

.quick-date {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    border: 1px solid transparent;
    border-radius: 50%;
    color: #282d28;
    font-size: 18px;
    font-weight: 500;
}

.quick-date.is-today {
    text-decoration: underline;
    text-underline-offset: 5px;
}

.quick-date.is-selected {
    background: #262b27;
    color: #fff;
}

.quick-date i,
.quick-calendar-key i {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: currentColor;
}

.quick-date i {
    position: absolute;
    left: calc(50% - 2px);
    bottom: 8px;
}

.quick-calendar-key {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: 20px;
    font-size: 16px;
    line-height: 1.6;
    color: #5c635b;
}

.quick-native-date {
    display: none;
}

.quick-day-heading p,
.quick-day-heading > span {
    font-size: 16px;
    color: #61685f;
    line-height: 1.6;
}

.quick-day-heading h3 {
    margin-top: 3px;
    font-size: 26px;
    font-weight: 650;
    line-height: 1.4;
    letter-spacing: -0.025em;
}

.quick-program-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 350px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    padding: 4px;
}

.quick-program {
    display: flex;
    align-items: center;
    gap: 20px;
    width: 100%;
    padding: 16px;
    border: 1px solid #e1e3dc;
    border-radius: 12px;
    background: #fff;
    color: #252a25;
    text-align: left;
}

.quick-program.is-selected {
    border-color: #303a31;
    box-shadow: inset 0 0 0 1px #303a31;
}

.quick-program:disabled {
    opacity: 65%;
    cursor: default;
}

.quick-program img {
    width: 72px;
    height: 96px;
    flex-shrink: 0;
    object-fit: cover;
    border-radius: 4px;
}

.quick-program-copy {
    display: grid;
    flex: 1;
    min-width: 0;
    gap: 3px;
    font-size: 16px;
    line-height: 1.5;
}

.quick-program-copy strong {
    margin-bottom: 4px;
    font-size: 20px;
    font-weight: 650;
    line-height: 1.4;
    word-break: keep-all;
    overflow-wrap: anywhere;
}

.quick-program-category {
    color: #697064;
}

.quick-program-check {
    font-size: 24px;
    width: 24px;
    text-align: center;
}

.quick-selection-fields {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 120px;
    gap: 16px;
    margin-top: 24px;
}

.quick-selection-fields label,
.quick-native-date {
    font-size: 16px;
    line-height: 1.6;
    font-weight: 600;
}

.quick-selection-fields select,
.quick-native-date input {
    display: block;
    width: 100%;
    min-width: 0;
    min-height: 52px;
    margin-top: 8px;
    padding: 12px;
    border: 1px solid #d5d9d0;
    border-radius: 8px;
    background: #fff;
    color: #2f372f;
    font: inherit;
}

.quick-selection-fields select:disabled {
    color: #73776e;
    background: #eceee8;
}

.quick-booking-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 24px;
}

.quick-booking-action p {
    font-size: 16px;
    line-height: 1.5;
    color: #525c50;
}

.quick-booking-action .button {
    flex-shrink: 0;
    min-height: 52px;
    font-size: 18px;
}

.quick-booking-action button:disabled {
    background: #dde1d7;
    color: #61685e;
    cursor: default;
}

.quick-booking-note {
    margin-top: 20px;
    font-size: 16px;
    line-height: 1.7;
    color: #656a61;
}

.quick-empty {
    padding-block: 40px;
    min-height: 260px;
}

.quick-empty h4 {
    font-size: 24px;
    line-height: 1.4;
    font-weight: 650;
    word-break: keep-all;
}

.quick-empty p {
    margin-block: 16px 24px;
    font-size: 18px;
    line-height: 1.7;
}

/* [발견과 지속적인 참여 / Discovery and continued participation] */
#discover-programs {
    border-top: 1px solid #deded9;
}

#discover-programs .program-choice {
    flex-wrap: wrap;
}

#discover-programs .program-choice button {
    min-height: 48px;
}

.home-season-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 32px;
    margin-top: 44px;
    padding: 32px 0;
    border-block: 1px solid #d9dcd4;
}

.home-season-link strong {
    display: block;
    margin-bottom: 10px;
    font-size: 26px;
    line-height: 1.4;
    font-weight: 650;
    letter-spacing: -0.025em;
}

.home-season-link > span > span {
    font-size: 18px;
    line-height: 1.7;
    color: #63695f;
}

.home-season-link > span:last-child {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 18px;
    line-height: 1.6;
    flex-shrink: 0;
}

.home-visit-planner {
    margin-bottom: 28px;
}

.home-news-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
}

.home-news-filters button {
    min-height: 48px;
    padding: 8px 4px;
    border-bottom: 2px solid transparent;
    color: #666d62;
    font-size: 18px;
    line-height: 1.5;
}

.home-news-filters button[aria-pressed="true"] {
    border-color: #252c25;
    color: #252c25;
    font-weight: 650;
}

.home-participation {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 32px;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid #dce0d5;
}

.home-participation a,
.home-institution-links a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 64px;
}

.home-institution-links {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 32px;
    margin-top: 64px;
    padding-top: 24px;
    border-top: 1px solid rgb(255 255 255 / 25%);
}

.home-institution-links a {
    color: #fff;
    font-size: 18px;
    line-height: 1.6;
}

@media (hover: hover) {
    .quick-date:not(.is-selected):hover {
        background: #e4e8df;
    }

    .quick-program:not(:disabled):hover {
        border-color: #737e6e;
    }

    .home-pathways a:hover strong,
    .home-participation a:hover strong {
        color: #5d6c58;
    }
}

@media (max-width: 1100px) {
    .quick-booking-layout {
        gap: 32px;
        padding: 28px;
        grid-template-columns: minmax(340px, 0.9fr) minmax(0, 1.1fr);
    }

    .quick-booking-action {
        flex-direction: column;
        align-items: stretch;
    }

    .quick-booking-action .button {
        justify-content: center;
    }

    .home-pathways,
    .home-participation {
        gap: 20px;
    }
}

@media (max-width: 860px) {
    .quick-booking-layout {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .quick-calendar {
        max-width: 480px;
        width: 100%;
        margin-inline: auto;
    }

    .quick-booking-choices {
        border-top: 1px solid #dce0d5;
        padding-top: 28px;
    }

    .home-pathways > a > svg:first-child {
        display: none;
    }

    .home-season-link {
        align-items: flex-start;
        flex-direction: column;
        gap: 20px;
    }

    .home-institution-links {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px 28px;
    }
}

@media (max-width: 600px) {
    .home-booking,
    #discover-programs,
    #sejong-news {
        padding-block: 64px;
    }

    .home-pathways,
    .home-participation {
        grid-template-columns: 1fr;
        gap: 0;
        padding-block: 12px;
    }

    .home-pathways > a,
    .home-participation > a {
        padding-block: 20px;
    }

    .home-pathways > a + a,
    .home-participation > a + a {
        border-top: 1px solid #e1e3dc;
    }

    .home-pathways > a > svg:first-child {
        display: block;
    }

    .quick-booking-layout {
        margin-top: 32px;
        padding: 24px 16px;
        border-radius: 18px;
    }

    .quick-calendar-heading {
        gap: 8px;
    }

    .quick-calendar-heading h3 {
        font-size: 24px;
    }

    .quick-calendar-grid {
        min-height: 288px;
    }

    .quick-date,
    .quick-calendar-blank {
        min-height: 48px;
    }

    .quick-program {
        padding: 12px;
        gap: 14px;
    }

    .quick-program img {
        width: 60px;
        height: 80px;
    }

    .quick-program-check {
        display: none;
    }

    .quick-program-copy strong {
        font-size: 20px;
    }

    .quick-selection-fields {
        grid-template-columns: minmax(0, 1fr) 88px;
        gap: 12px;
    }

    .quick-selection-fields select {
        padding-inline: 8px;
    }

    .quick-booking-action {
        gap: 16px;
    }

    #discover-programs .program-filter-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    #discover-programs .program-choice {
        gap: 8px;
    }

    #discover-programs .program-choice button {
        min-height: 48px;
        padding-inline: 16px;
        font-size: 16px;
    }

    .home-news-filters {
        gap: 14px;
    }

    .home-news-filters button {
        font-size: 16px;
    }

    .home-institution-links {
        margin-top: 40px;
        grid-template-columns: 1fr;
        gap: 0;
    }
}

/* [좁은 화면의 날짜 입력 / Date input on narrow screens]
   일곱 열이 48px 조작 폭을 확보하지 못할 때 네이티브 날짜 입력을 제공합니다.
   Use the native date input when seven columns cannot retain 48px touch widths. */
@media (max-width: 430px) {
    .quick-native-date {
        display: block;
    }

    .quick-calendar-week,
    .quick-calendar-grid,
    .quick-calendar-key,
    .quick-month-controls {
        display: none;
    }

    .quick-calendar-heading {
        margin-bottom: 16px;
        min-height: 0;
    }
}
