/* ──────────────────────────────────────────────────────────────
 * Extras — 퍼블리싱 base/theme.css가 다루지 않는 보조 스타일
 *  - 404, search, generic page, skip link, accessibility
 *  - 퍼블리싱 디자인 토큰(--gl-*)을 그대로 재사용
 * ────────────────────────────────────────────────────────────── */

.gl-skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    z-index: 10000;
    padding: 8px 16px;
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
    font-size: 14px;
    border-radius: 0 0 6px 6px;
    transition: top 0.2s ease;
}
.gl-skip-link:focus {
    top: 0;
}

/* ── 404 ── */
.gl-404 {
    padding: clamp(80px, 12vw, 160px) var(--gl-gutter);
    text-align: center;
    background: var(--gl-color-white);
    color: var(--gl-color-gray-900);
}
.gl-404__inner {
    max-width: 720px;
    margin: 0 auto;
}
.gl-404__code {
    font-family: var(--gl-font-serif);
    font-size: clamp(80px, 14vw, 140px);
    font-weight: 800;
    color: var(--gl-color-blue);
    opacity: 0.25;
    line-height: 1;
    margin-bottom: 16px;
}
.gl-404__title {
    font-size: clamp(24px, 3.5vw, 32px);
    font-weight: 700;
    color: var(--gl-color-navy);
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}
.gl-404__text {
    color: var(--gl-color-gray-700);
    font-size: 16px;
    margin-bottom: 32px;
}
.gl-404__searchform {
    max-width: 480px;
    margin: 0 auto 32px;
}
.gl-404__cats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin: 0 0 32px;
    padding: 0;
    list-style: none;
}
.gl-404__cats a {
    padding: 6px 16px;
    background: rgba(13, 46, 61, 0.06);
    border-radius: 100px;
    font-size: 14px;
    color: var(--gl-color-gray-900);
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease;
}
.gl-404__cats a:hover {
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
}
.gl-404__actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}
.gl-404__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
    border: 1px solid var(--gl-color-navy);
    color: var(--gl-color-navy);
    background: transparent;
}
.gl-404__button--primary {
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
}
.gl-404__button--primary:hover {
    background: #091f2e;
    color: var(--gl-color-white);
}
.gl-404__button:hover {
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
}

/* ── Search results extras ── */
.gl-column-list__searchform {
    max-width: 600px;
    margin: 0 auto 32px;
}
.gl-column-list__empty {
    padding: 80px 0;
    text-align: center;
    color: var(--gl-color-gray-700);
    font-size: 16px;
    line-height: 1.7;
}
.gl-column-list__empty p {
    margin: 0 0 12px;
}
.gl-column-list__empty-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin: 24px 0 0;
    padding: 0;
    list-style: none;
}
.gl-column-list__empty-cats a {
    padding: 6px 16px;
    background: rgba(13, 46, 61, 0.06);
    border-radius: 100px;
    font-size: 14px;
    color: var(--gl-color-gray-900);
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease;
}
.gl-column-list__empty-cats a:hover {
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
}

/* ── 검색 폼 (WP get_search_form 출력) ── */
.search-form {
    display: flex;
    width: 100%;
    border: 1px solid rgba(13, 46, 61, 0.18);
    border-radius: 8px;
    overflow: hidden;
    background: var(--gl-color-white);
}
.search-form .search-field {
    flex: 1;
    padding: 12px 16px;
    border: 0;
    font-size: 15px;
    color: var(--gl-color-gray-900);
    outline: none;
}
.search-form .search-submit {
    padding: 12px 22px;
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
    font-size: 14px;
    font-weight: 600;
    border: 0;
    cursor: pointer;
    transition: background 0.2s ease;
}
.search-form .search-submit:hover {
    background: #091f2e;
}

/* ── 일반 페이지 (page.php) ── */
.gl-page-article {
    padding: clamp(48px, 8vw, 96px) var(--gl-gutter);
    background: var(--gl-color-white);
}
.gl-page-article__inner {
    max-width: 880px;
    margin: 0 auto;
    color: var(--gl-color-gray-900);
    line-height: 1.8;
    font-size: 16px;
}

/* ── 페이지네이션 (gl_column_pagination) ── */
.gl-column-list__page {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    margin: 0 2px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    color: var(--gl-color-gray-900);
    background: transparent;
    border: 1px solid rgba(13, 46, 61, 0.16);
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.gl-column-list__page:hover {
    border-color: var(--gl-color-navy);
    color: var(--gl-color-navy);
}
.gl-column-list__page--active {
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
    border-color: var(--gl-color-navy);
    pointer-events: none;
}
.gl-column-list__next {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 36px;
    padding: 0 16px;
    margin-left: 8px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    color: var(--gl-color-navy);
    border: 1px solid var(--gl-color-navy);
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
}
.gl-column-list__next:hover {
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
}
.gl-column-list__pagination {
    margin-top: 48px;
    text-align: center;
}

/* ── Header 카테고리 드롭다운 ── */
.gl-header__nav-item--has-dropdown {
    position: relative;
}
.gl-header__dropdown {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    list-style: none;
    margin: 0;
    padding: 8px 0;
    min-width: 180px;
    background: var(--gl-color-white);
    border: 1px solid rgba(13, 46, 61, 0.12);
    border-radius: 8px;
    box-shadow: 0 12px 32px rgba(13, 46, 61, 0.12);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
    z-index: 1000;
}
.gl-header__nav-item--has-dropdown:hover > .gl-header__dropdown,
.gl-header__nav-item--has-dropdown:focus-within > .gl-header__dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.gl-header__dropdown li a {
    display: block;
    padding: 10px 22px;
    font-size: 14px;
    font-weight: 500;
    color: var(--gl-color-gray-900);
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.15s ease, color 0.15s ease;
}
.gl-header__dropdown li a:hover,
.gl-header__dropdown li a:focus {
    background: rgba(13, 46, 61, 0.04);
    color: var(--gl-color-navy);
}
.gl-header__nav-item--has-dropdown:hover > .gl-header__nav-link--arrow .gl-header__nav-arrow,
.gl-header__nav-item--has-dropdown:focus-within > .gl-header__nav-link--arrow .gl-header__nav-arrow {
    transform: rotate(180deg);
    transition: transform 0.2s ease;
}

/* ── Stretched link: 카드 전체 클릭 가능 ── */
.gl-cases__card,
.gl-subcase__card {
    position: relative;
    transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.gl-cases__card-link,
.gl-subcase__card-link {
    position: absolute;
    inset: 0;
    z-index: 1;
    text-indent: -9999px;
    overflow: hidden;
    color: transparent;
    background: transparent;
}
.gl-cases__card .gl-cases__more {
    position: relative;
    z-index: 2; /* More 버튼은 stretched-link 위로 */
}

/* ── Hover 시 베이지 강조 (퍼블리셔의 --featured와 동일) ── */
.gl-cases__card:hover {
    background: #a99077;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(13, 46, 61, 0.18);
}
.gl-cases__card:hover .gl-cases__badge {
    background: rgba(255, 255, 255, 0.16);
}
.gl-cases__card:hover .gl-cases__date {
    color: #fff;
}
.gl-cases__card:hover .gl-cases__text {
    color: rgba(255, 255, 255, 0.82);
}
.gl-cases__card:hover .gl-cases__office {
    color: #fff;
    border-bottom-color: #fff;
}
.gl-cases__card.gl-cases__card--more:hover .gl-cases__more {
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
}

/* ── About 페이지 subcase 카드도 같은 호버 ── */
.gl-subcase__card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(13, 46, 61, 0.12);
}

/* ── 가로 스크롤 가능 표시: cases 리스트 스크롤바 노출 ──
 *  퍼블리셔가 ::webkit-scrollbar display:none 처리한 걸 부드럽게 덮어씀.
 *  데스크탑 마우스 사용자에게 "여기 가로로 스크롤됨" 시각 신호.
 */
.gl-cases__list {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.35) transparent;
}
.gl-cases__list::-webkit-scrollbar {
    display: block !important;
    height: 8px;
}
.gl-cases__list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.06);
    border-radius: 4px;
}
.gl-cases__list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.35);
    border-radius: 4px;
    transition: background 0.2s ease;
}
.gl-cases__list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.55);
}

/* ── 모바일 드로어 (햄버거 메뉴) ── */
.gl-mobile-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: 88vw;
    max-width: 360px;
    height: 100dvh;
    background: var(--gl-color-white);
    box-shadow: -8px 0 32px rgba(13, 46, 61, 0.18);
    z-index: 1100;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    display: flex;
    flex-direction: column;
}
.gl-mobile-drawer[aria-hidden="false"] {
    transform: translateX(0);
}
.gl-mobile-drawer__overlay {
    position: fixed;
    inset: 0;
    background: rgba(13, 46, 61, 0.5);
    z-index: 1099;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.gl-mobile-drawer__overlay[aria-hidden="false"],
.gl-mobile-drawer__overlay.is-visible {
    opacity: 1;
    pointer-events: auto;
}
.gl-mobile-drawer__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 22px;
    border-bottom: 1px solid rgba(13, 46, 61, 0.08);
    flex-shrink: 0;
}
.gl-mobile-drawer__logo img {
    height: 36px;
    width: auto;
}
.gl-mobile-drawer__close {
    width: 40px;
    height: 40px;
    border: 0;
    background: transparent;
    font-size: 28px;
    line-height: 1;
    color: var(--gl-color-navy);
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.15s ease;
}
.gl-mobile-drawer__close:hover {
    background: rgba(13, 46, 61, 0.06);
}
.gl-mobile-drawer__nav {
    flex: 1;
    padding: 12px 22px;
}
.gl-mobile-drawer__link {
    display: block;
    padding: 16px 0;
    font-size: 17px;
    font-weight: 600;
    color: var(--gl-color-navy);
    text-decoration: none;
    border-bottom: 1px solid rgba(13, 46, 61, 0.08);
    letter-spacing: -0.02em;
}
.gl-mobile-drawer__group {
    border-bottom: 1px solid rgba(13, 46, 61, 0.08);
}
.gl-mobile-drawer__group-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    font-size: 17px;
    font-weight: 600;
    color: var(--gl-color-navy);
    cursor: pointer;
    list-style: none;
    letter-spacing: -0.02em;
}
.gl-mobile-drawer__group-title::-webkit-details-marker { display: none; }
.gl-mobile-drawer__group-title::after {
    content: '▾';
    font-size: 14px;
    color: var(--gl-color-gray-700);
    transition: transform 0.2s ease;
}
.gl-mobile-drawer__group[open] .gl-mobile-drawer__group-title::after {
    transform: rotate(180deg);
}
.gl-mobile-drawer__sublist {
    margin: 0 0 12px;
    padding: 0 0 0 12px;
    list-style: none;
}
.gl-mobile-drawer__sublist li a {
    display: block;
    padding: 10px 0;
    font-size: 15px;
    color: var(--gl-color-gray-900);
    text-decoration: none;
    transition: color 0.15s ease;
}
.gl-mobile-drawer__sublist li a:hover,
.gl-mobile-drawer__sublist li a:focus {
    color: var(--gl-color-navy);
}
.gl-mobile-drawer__cta {
    padding: 16px 22px 24px;
    border-top: 1px solid rgba(13, 46, 61, 0.08);
}
.gl-mobile-drawer__phone {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
    background: var(--gl-color-navy);
    color: var(--gl-color-white);
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    border-radius: 8px;
    letter-spacing: -0.02em;
    transition: background 0.2s ease;
}
.gl-mobile-drawer__phone:hover {
    background: #091f2e;
    color: var(--gl-color-white);
}
body.gl-drawer-open {
    overflow: hidden;
}

/* ── 방문예약 폼 알림 메시지 ── */
.gl-reservation__alert {
    max-width: var(--gl-container-max);
    margin: 0 auto 24px;
    padding: 16px 22px;
    border-radius: 8px;
    font-size: 15px;
    line-height: 1.6;
    text-align: center;
}
.gl-reservation__alert--success {
    background: rgba(67, 163, 221, 0.1);
    border: 1px solid var(--gl-color-blue);
    color: var(--gl-color-navy);
}
.gl-reservation__alert--error {
    background: rgba(220, 53, 69, 0.08);
    border: 1px solid #dc3545;
    color: #b3232f;
}

/* ── Floating kakao (GA4 hook — 채널 활성 시 마크업 추가) ── */
.gl-float-kakao { display: none; }

/* ── Mobile bottom bar (GA4 클래스 hook 유지) ── */
.gl-mobile-bottom-bar {
    display: none;
}
@media (max-width: 768px) {
    .gl-mobile-bottom-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 9999;
        background: var(--gl-color-navy);
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.25);
    }
    .gl-mobile-bottom-btn {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding: 10px 0;
        text-decoration: none;
        font-size: 11px;
        font-weight: 600;
        color: var(--gl-color-white);
    }
    .gl-mobile-bottom-btn--phone   { background: var(--gl-color-navy); }
    .gl-mobile-bottom-btn--kakao   { background: #FEE500; color: #191919; }
    .gl-mobile-bottom-btn--contact { background: var(--gl-color-blue); color: var(--gl-color-white); }
    body { padding-bottom: 64px; }
}
