/* =========================================================
   페이지별 스타일 (aurora main/store/giftbox/members/attendance/play + laura 구성)
   모든 색은 base.css 의 테마 변수를 사용합니다.
   ========================================================= */

.page.narrow { max-width: 920px; }
.center { text-align: center; }
.wide-col { grid-column: 1 / -1; }

/* ---------------- 메인 ---------------- */
.home { max-width: 1240px; margin: 0 auto; padding: 24px 40px 40px 92px; }
.home-header { display: flex; align-items: center; margin-bottom: 14px; }
.home-logo {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    min-width: 250px; height: 150px; margin: 0 34px 0 30px; text-align: center; text-decoration: none;
}
.home-logo .logo-orn { color: var(--accent); letter-spacing: .6em; font-size: .8rem; padding-left: .6em; }
.home-logo .logo-main {
    font-family: "Cinzel Decorative", serif; font-size: 2.15rem; font-weight: 700; line-height: 1.2;
    letter-spacing: .05em; color: var(--ink-strong);
    text-shadow: 0 1px 0 color-mix(in srgb, var(--panel) 85%, transparent), 0 0 18px color-mix(in srgb, var(--accent) 40%, transparent);
}
.home-logo .logo-sub { font-family: "Gowun Batang", serif; font-size: .95rem; letter-spacing: .45em; color: var(--ink-soft); padding-left: .45em; }
.home-nav ul { display: flex; list-style: none; padding: 0; margin: 70px 0 0; gap: 28px; flex-wrap: wrap; }
.home-nav a {
    text-decoration: none;
    color: var(--accent-strong);
    font-family: "Cinzel Decorative", serif;
    font-size: 1.35rem;
    transition: color .2s, transform .2s, text-shadow .2s;
    display: inline-block;
}
.home-nav a:hover { color: var(--accent); transform: translateY(-2px); text-shadow: 0 0 8px color-mix(in srgb, var(--accent) 45%, transparent); }

.home-dashboard { display: flex; gap: 20px; }
.home-left { flex: 0 0 280px; }
.home-right { flex: 1; display: flex; flex-direction: column; gap: 12px; min-width: 0; }

.frame-panel {
    background: var(--glass);
    border: 4px solid var(--line-strong);
    border-radius: 8px;
    box-shadow: var(--shadow);
    padding: 18px 20px;
    position: relative;
    overflow: hidden;
}

.ranking-frame { padding-top: 14px; min-height: 420px; background-image: url("../img/ui/val_back.png"); background-size: 100% 100%; }
.crown { text-align: center; margin: 10px 0 18px; }
.crown img { width: 140px; opacity: .85; }
.ranking-label { font-size: .72rem; font-weight: 700; letter-spacing: 2px; margin: 4px 0 3px 5px; }
.ranking-label.top { color: var(--accent); }
.ranking-label.bottom { color: var(--ink-faint); }
.ranking-item { display: flex; align-items: center; gap: 8px; padding: 5px 12px; background: linear-gradient(to right, color-mix(in srgb, var(--inset) 85%, transparent), transparent); }
.rank-num { font-size: .8rem; font-weight: 700; min-width: 16px; text-align: center; }
.top-rank, .top-points { color: var(--accent); }
.bottom-rank, .bottom-points { color: var(--ink-faint); }
.rank-name { flex: 1; font-size: .86rem; font-weight: 700; color: var(--ink); text-decoration: none; font-family: "Gowun Batang", serif; }
.rank-name:hover { color: var(--accent); }
.rank-points { font-size: .8rem; font-weight: 700; font-family: "Cinzel Decorative", serif; }
.ranking-divider { text-align: center; color: var(--line-strong); letter-spacing: 4px; margin: 6px 0; }

.weather-bar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 14px;
    padding: 2px 20px;
    font-weight: 700;
    color: var(--ink-soft);
    background: linear-gradient(to right, transparent, color-mix(in srgb, var(--pill) 30%, transparent) 40%, color-mix(in srgb, var(--pill) 55%, transparent));
}
.weather-loc { font-size: 1.25rem; color: var(--accent); font-family: "Cinzel Decorative", serif; }
.star { width: 26px; }

.home-middle { display: flex; gap: 14px; }
.notice-panel { flex: .9; min-height: 300px; }
.panel-heading { margin: 0 0 14px; text-align: center; font-family: "Cinzel Decorative", serif; letter-spacing: 5px; color: var(--ink-soft); font-size: 1.15rem; }
.notice-items { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.notice-items a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 12px;
    background: linear-gradient(to right, color-mix(in srgb, var(--inset) 85%, transparent), transparent);
    text-decoration: none;
    color: var(--ink);
    font-size: .88rem;
    font-weight: 700;
}
.notice-items a:hover { color: var(--accent); }
.star-icon { color: var(--accent); }
.notice-title { flex: 1; }
.notice-date { font-size: .72rem; color: var(--ink-faint); font-weight: 400; }

.info-stack { flex: 1; display: flex; flex-direction: column; gap: 14px; }
.map-panel { flex: 1; min-height: 140px; background-size: 100% 100%; display: flex; align-items: flex-end; justify-content: flex-end; }
.map-text { text-align: right; color: #fffcf7; font-family: "Gowun Batang", serif; text-shadow: 0 1px 4px rgba(0, 0, 0, .55); }
.map-text h4 { margin: 0 0 3px; font-size: 1.15rem; }
.map-text p { margin: 0; font-size: .86rem; }

.quest-panel {
    flex: 1;
    min-height: 140px;
    background-image: var(--q-bg);
    background-size: 100% 100%;
    display: flex;
    align-items: flex-end;
    transition: background-image .5s ease;
}
.quest-panel:hover { background-image: var(--q-bg-hover); }
.quest-bottom { width: 100%; display: flex; justify-content: space-between; align-items: flex-end; }
.quest-note { color: #fffcf7; text-shadow: 0 1px 4px rgba(0, 0, 0, .6); font-family: "Gowun Batang", serif; font-weight: 700; }
.quest-action {
    background: var(--panel);
    color: var(--ink);
    padding: 6px 16px;
    border-radius: 20px;
    text-decoration: none;
    font-family: "Cinzel Decorative", serif;
    font-weight: 700;
    font-size: .85rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, .15);
}
.quest-action:hover { background: var(--accent); color: var(--on-accent); }

.specialties { padding: 12px 18px; background-image: url("../img/ui/item_back.png"); background-size: 100% 100%; }
.specialties-header { text-align: center; font-size: .85rem; color: var(--ink-soft); font-weight: 700; margin-bottom: 8px; }
.slots-container { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.item-slot { width: 54px; height: 54px; background: var(--inset); border: 1px solid var(--line-strong); border-radius: 4px; display: flex; align-items: center; justify-content: center; box-shadow: inset 0 2px 4px rgba(0, 0, 0, .05); transition: transform .15s; }
.item-slot:hover { transform: translateY(-3px); }
.item-slot img { width: 85%; height: 85%; object-fit: contain; }

.floating-login { position: fixed; right: 20px; bottom: 20px; width: 240px; padding: 22px 20px; z-index: 1000; }
.floating-login form { display: flex; flex-direction: column; gap: 8px; }
.login-input-group { display: flex; align-items: center; background: var(--panel-3); border: 1px solid var(--line-strong); border-radius: 6px; padding: 9px 12px; }
.login-input-group:focus-within { border-color: var(--accent-strong); background: var(--panel); }
.login-input-group i { color: var(--ink-faint); margin-right: 10px; width: 15px; text-align: center; }
.mini-input { border: 0; outline: 0; width: 100%; background: transparent; color: var(--ink-strong); font-family: inherit; font-size: .85rem; }
.login-options { text-align: center; font-size: .8rem; }
.login-options a { color: var(--ink-faint); text-decoration: none; }

/* ---------------- 공지 / 세계관 ---------------- */
.notice-list { display: flex; flex-direction: column; gap: 14px; }
.notice-card { padding: 20px 24px; background: var(--glass); }
.notice-card header { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; margin-bottom: 8px; }
.notice-card h2 { margin: 0; font-size: 1.1rem; color: var(--ink-strong); }
.notice-card time { color: var(--ink-faint); font-size: .8rem; }
.notice-card p { margin: 0; line-height: 1.75; font-family: "Gowun Batang", serif; }
.notice-card.pinned { border-color: var(--accent); }
.pin { color: var(--accent); margin-right: 6px; }

.lore { padding: 24px 28px; margin-bottom: 16px; background: var(--glass); }
.lore h2 { margin: 0 0 10px; font-size: 1.1rem; color: var(--ink-strong); }
.lore p { margin: 0; line-height: 1.9; font-family: "Gowun Batang", serif; }
.faction-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 16px; }
.faction { padding: 18px 20px; background: var(--glass); }
.faction h3 { margin: 6px 0 8px; color: var(--ink-strong); }
.faction p { margin: 0; font-size: .88rem; line-height: 1.7; font-family: "Gowun Batang", serif; }
.timeline { list-style: none; margin: 14px 0 0 6px; padding: 0 0 0 22px; border-left: 1px solid var(--line-strong); display: flex; flex-direction: column; gap: 16px; }
.timeline li { position: relative; display: flex; flex-direction: column; gap: 3px; }
.timeline li::before { content: ""; position: absolute; left: -27px; top: 6px; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); }
.timeline b { font-family: "Cinzel Decorative", serif; color: var(--accent-strong); font-size: .85rem; }
.timeline span { font-family: "Gowun Batang", serif; line-height: 1.7; }

/* 상점 스타일은 static/css/store.css 로 옮겼다 (책장 진열 · 상세 창 · NPC 대사 상자로 다시 만들었다). */
/* 선물함 스타일은 static/css/gift.css 로 옮겼다 (고드릭 디자인으로 다시 만들었다). */

/* ---------------- 보급 ---------------- */
.supply-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px 20px 20px 90px; }
/* 배경 이미지(attendance_back.png)에는 '보급 신청' 제목과 두루마리가 그려져 있다.
   글자는 두루마리 안쪽에, 버튼은 두루마리 아래 빈 공간에 둔다. */
.att-card { position: relative; width: min(800px, 92vw); aspect-ratio: 800 / 462; background-size: 100% 100%; border-radius: 14px; box-shadow: var(--shadow); text-align: center; animation: boxPopUp .5s ease-out; }
.att-content { position: absolute; left: 20%; right: 20%; top: 35%; height: 35%; display: flex; flex-direction: column; justify-content: center; color: #5a4d3a; }
.att-header p { margin: 0; font-weight: 700; font-size: .98rem; line-height: 1.45; }
.att-info { margin: 10px 0 0; }
.att-info h4 { margin: 0 0 2px; font-family: "Cinzel Decorative", "Noto Sans KR", serif; letter-spacing: 3px; font-size: .95rem; }
.att-info p { margin: 2px 0; font-size: .9rem; }
.small { font-size: .82rem; opacity: .85; }
.att-btn { position: absolute; left: 0; right: 0; bottom: 6%; margin: 0 auto; width: max-content; padding: 11px 54px; background: #5a4d3a; color: #fcfbf6; border: 0; border-radius: 28px; font: 700 1.05rem "Cinzel Decorative", "Noto Sans KR", serif; letter-spacing: 3px; cursor: pointer; transition: transform .2s, background .2s; }
.att-btn:hover:not(:disabled) { background: #7a6a52; transform: translateY(-2px); }
.att-btn:disabled { opacity: .55; cursor: not-allowed; }
@media (max-width: 620px) {
    .att-card { aspect-ratio: auto; background-size: cover; background-position: center top; padding: 110px 18px 26px; }
    .att-content { position: static; height: auto; }
    .att-btn { position: static; margin: 18px auto 0; }
}
.reward-row { display: flex; justify-content: center; gap: 14px; margin: 14px 0; }
.reward { display: flex; flex-direction: column; align-items: center; gap: 6px; background: var(--panel-3); border: 1px solid var(--line); border-radius: 10px; padding: 12px; min-width: 88px; }
.reward img { width: 40px; height: 40px; object-fit: contain; }
.reward span { font-size: .78rem; font-weight: 700; color: var(--ink); }
.supply-extra { color: var(--accent-strong); font-weight: 700; min-height: 1.2em; }
.reward-row[hidden] { display: none; }

/* ---------------- 멤버 ---------------- */
.filter-group { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.filter-btn { padding: 6px 15px; border-radius: 20px; border: 1px solid var(--line-strong); background: var(--panel); color: var(--ink-soft); font: 700 .82rem "Noto Sans KR", sans-serif; cursor: pointer; transition: all .2s; }
.filter-btn:hover { border-color: var(--accent-strong); }
.filter-btn.active { background: var(--ink-strong); color: var(--panel); border-color: var(--ink-strong); }
[data-theme="laura"] .filter-btn.active { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }

.members-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 26px 20px; }
.member-card { position: relative; text-align: center; }
.member-card[hidden] { display: none; }
.card-top-title { font-size: .78rem; color: var(--accent-strong); font-weight: 700; margin-bottom: 6px; min-height: 1.2em; }
.title-dropdown-wrap { margin-bottom: 6px; }
.title-select { font: inherit; font-size: .75rem; padding: 3px 6px; background: var(--panel); border: 1px solid var(--line-strong); color: var(--ink); border-radius: 6px; }
.member-link { position: relative; display: block; text-decoration: none; color: inherit; aspect-ratio: 292 / 414; transition: transform .2s; }
.member-link:hover { transform: translateY(-5px); }
.member-img-box { position: absolute; inset: 10% 11% 24% 11%; display: flex; align-items: center; justify-content: center; overflow: hidden; background: var(--inset); }
.member-img { width: 100%; height: 100%; object-fit: cover; }
.member-img.placeholder { width: 40%; height: auto; opacity: .55; }
.card-frame { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: fill; pointer-events: none; }
.member-info { position: absolute; left: 0; right: 0; bottom: 4%; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.diamond-deco { font-size: .55rem; color: var(--accent); letter-spacing: 3px; }
.member-title { font-size: .72rem; color: var(--ink-soft); font-family: "Gowun Batang", serif; }
.member-name { font-weight: 700; font-size: 1.02rem; color: var(--ink-strong); font-family: "Hahmlet", "Noto Sans KR", serif; }

/* ---------------- 프로필 ---------------- */
.profile-grid { display: grid; grid-template-columns: 300px 1fr; gap: 22px; align-items: start; }
.profile-side { padding: 22px; text-align: center; position: sticky; top: 96px; }
.profile-portrait { aspect-ratio: 3 / 4; background: var(--inset); border: 2px solid var(--line-strong); border-radius: 8px; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.profile-portrait img { width: 100%; height: 100%; object-fit: cover; }
.profile-portrait img.placeholder { width: 32%; height: auto; opacity: .5; }
.profile-title { margin-top: 14px; color: var(--accent-strong); font-weight: 700; font-size: .85rem; min-height: 1.2em; }
.profile-name { margin: 2px 0; font-family: "Hahmlet", "Noto Sans KR", serif; color: var(--ink-strong); font-size: 1.6rem; }
.profile-en { font-family: "Cinzel Decorative", serif; color: var(--ink-faint); letter-spacing: 2px; font-size: .85rem; }
.profile-catch { margin-top: 10px; font-family: "Gowun Batang", serif; color: var(--ink-soft); }
.profile-quote { margin: 12px 0 0; padding: 10px 12px; background: color-mix(in srgb, var(--pill) 35%, transparent); border-radius: 8px; font-family: "Gowun Batang", serif; font-size: .9rem; }
.profile-keywords { margin-top: 12px; display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.profile-keywords span { font-size: .78rem; background: var(--panel-3); border: 1px solid var(--line); border-radius: 12px; padding: 2px 10px; }
.profile-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.profile-block { padding: 22px 26px; background: var(--glass); }
.block-title { margin: 0 0 14px; font-family: "Cinzel Decorative", serif; letter-spacing: 3px; font-size: 1rem; color: var(--ink-strong); }
.block-title small { font-family: "Noto Sans KR", sans-serif; letter-spacing: 0; font-weight: 400; color: var(--ink-faint); margin-left: 10px; }
.info-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 18px; margin: 0 0 6px; }
.info-grid dt { font-size: .74rem; color: var(--ink-faint); font-weight: 700; }
.info-grid dd { margin: 2px 0 0; color: var(--ink-strong); font-weight: 700; }
.sub-title { margin: 16px 0 4px; font-size: .86rem; color: var(--accent-strong); }
.prose { margin: 0; line-height: 1.8; font-family: "Gowun Batang", serif; }
.stat-bars { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 26px; }
.stat-bars li { display: grid; grid-template-columns: 96px 1fr 28px; align-items: center; gap: 10px; font-size: .84rem; }
.stat-label em { font-style: normal; color: var(--ink-faint); font-size: .7rem; margin-left: 4px; }
.stat-track { height: 8px; background: var(--inset); border-radius: 4px; overflow: hidden; }
.stat-fill { display: block; height: 100%; background: var(--accent); border-radius: 4px; }

/* 인벤토리 (프로필 · 인벤토리 페이지 공용) */
.inv-wallet { display: flex; gap: 14px; margin-bottom: 18px; font-weight: 700; color: var(--ink-strong); }
.inv-big-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 14px; }
.inv-big-grid.mini { grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); }
.inv-slot { position: relative; background: var(--panel-3); border: 2px solid var(--line); border-radius: 10px; padding: 12px 6px 8px; cursor: pointer; text-align: center; font: inherit; color: inherit; transition: transform .15s, border-color .15s; }
.inv-slot.static { cursor: default; }
.inv-slot:hover { transform: translateY(-3px); border-color: var(--accent); }
.inv-slot img { width: 54px; height: 54px; object-fit: contain; }
.inv-qty { position: absolute; top: 6px; right: 6px; background: var(--accent-strong); color: var(--on-accent); border-radius: 10px; font-size: .68rem; font-weight: 700; padding: 0 6px; }
.inv-name { display: block; margin-top: 6px; font-size: .74rem; font-weight: 700; color: var(--ink); word-break: keep-all; }
.transfer-btn { margin-top: 6px; font-size: .68rem; padding: 2px 10px; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--panel); color: var(--ink-soft); cursor: pointer; }
.transfer-btn:hover { background: var(--accent-strong); color: var(--on-accent); }
.modal-img { width: 90px; height: 90px; margin: 0 auto 10px; background: var(--panel-3); border: 1px solid var(--line); border-radius: 12px; display: flex; align-items: center; justify-content: center; }
.modal-img img { width: 76%; height: 76%; object-fit: contain; }
.im-qty { color: var(--ink-soft); font-size: .86rem; }

/* 조사(챕터 고르기 · 플레이 화면)는 고드릭 디자인이라 static/css/play.css 에 있습니다. */

/* ---------------- 인증 ---------------- */
.auth-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px 20px 20px 90px; }
.auth-box { width: min(400px, 92vw); padding: 36px 34px; text-align: center; }
.signup-title { margin: 0; font-family: "Cinzel Decorative", serif; color: var(--ink-strong); letter-spacing: 3px; }
.signup-subtitle { margin: 6px 0 22px; color: var(--ink-soft); font-family: "Gowun Batang", serif; }
.input-section { display: flex; align-items: center; background: var(--panel-3); border: 1px solid var(--line-strong); border-radius: 6px; padding: 10px 14px; margin-bottom: 10px; }
.input-section:focus-within { border-color: var(--accent-strong); background: var(--panel); }
.input-section i { color: var(--ink-faint); margin-right: 12px; width: 16px; text-align: center; }
.input-section input { flex: 1; border: 0; outline: 0; background: transparent; color: var(--ink-strong); font: inherit; font-size: .92rem; }
.auth-box form .btn { margin-top: 8px; }
.demo-note { margin-top: 18px; padding: 12px 14px; border: 1px dashed var(--line-strong); border-radius: 8px; font-size: .8rem; color: var(--ink-soft); text-align: center; }
.demo-note code { padding: 1px 6px; border-radius: 4px; background: var(--panel-3); color: var(--ink-strong); }
.demo-chips { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 8px; }
.auto-login { display: flex; align-items: center; gap: 8px; margin: 2px 2px 14px; font-size: .84rem; color: var(--ink-soft); cursor: pointer; }
.auto-login input { accent-color: var(--accent-strong); }
.bottom-links { display: flex; justify-content: center; gap: 22px; margin-top: 18px; font-size: .82rem; }
.bottom-links a { color: var(--ink-faint); text-decoration: none; }
.bottom-links a:hover { color: var(--ink-strong); }
.auth-errors { list-style: none; margin: 0 0 16px; padding: 10px 12px; background: color-mix(in srgb, var(--danger) 14%, transparent); border: 1px solid var(--danger); border-radius: 6px; color: var(--danger); font-size: .86rem; }
.auth-errors.center { text-align: center; }

/* ---------------- 에디터 ---------------- */
.page-editor { overflow: hidden; }
.editor-container { position: fixed; inset: 0; padding-left: 70px; display: flex; flex-direction: column; background: var(--panel-2); }
.editor-menu { padding: 10px 16px; display: flex; gap: 14px; align-items: center; border-bottom: 1px solid var(--line); }
.btn-add { background: var(--ink-strong); color: var(--panel); border: 0; border-radius: 6px; padding: 8px 16px; font: 700 .8rem "Cinzel Decorative", sans-serif; cursor: pointer; }
.editor-map-title { color: var(--ink-soft); font-weight: 700; }
.editor-wrapper { flex: 1; position: relative; }
#drawflow { width: 100%; height: 100%; }

@media (max-width: 980px) {
    .home { padding: 20px 14px 30px 70px; }
    .home-dashboard, .home-middle, .profile-grid { flex-direction: column; grid-template-columns: 1fr; }
    .home-left { flex-basis: auto; }
    .faction-grid, .info-grid, .stat-bars { grid-template-columns: 1fr; }
    .profile-side { position: static; }
}
