/* 首页、创建 / 加入、登录 / 注册：入场页面的排版。牌桌样式在 app.css。 */
.entry-view { display: block; }
.entry-panel { background: none; border: 0; padding: 0; box-shadow: none; }
body[data-entry-screen] .page-footer { margin-top: 24px; }

/* ---- home ---- */
.hero { display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, 1fr); align-items: center; gap: 40px; min-height: 430px; padding-top: 36px; }
.hero-title { margin: 18px 0 30px; font: 700 64px/1.02 var(--serif); letter-spacing: .015em; text-transform: uppercase; }
.hero-actions { display: flex; gap: 16px; align-items: center; }
.hero-actions .btn { min-width: 214px; min-height: 66px; justify-content: flex-start; padding: 0 26px; font-size: 19px; }
.hero-actions .btn svg { width: 26px; height: 26px; }
.hero-foot { margin: 22px 0 0; display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: 12.5px; letter-spacing: .04em; }
.hero-foot span::before { content: "◆"; font-size: 7px; color: var(--gold); margin-right: 8px; vertical-align: 2px; }
.hero-art { position: relative; height: 400px; border-radius: 18px; overflow: hidden; box-shadow: 0 30px 70px rgba(0, 0, 0, .55), 0 0 0 1px rgba(217, 181, 102, .22); }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: 62% 50%; display: block; transform: scale(1.02); }
.hero-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10, 11, 10, .75), rgba(10, 11, 10, 0) 32%), linear-gradient(0deg, rgba(10, 11, 10, .6), transparent 40%); }
.hero-corner { position: absolute; left: 18px; bottom: 16px; z-index: 2; color: var(--gold-hi); font: 500 12px/1 var(--serif); letter-spacing: .34em; }
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; margin-top: 34px; }
/* Four games across leave no room for the corner art beside the text. */
@media (min-width: 601px) { .feature-emblem { display: none; } }
.feature { position: relative; display: flex; align-items: center; gap: 18px; min-height: 112px; padding: 0 22px; overflow: hidden; text-decoration: none; color: inherit; }
.feature-icon { width: 54px; height: 54px; border-radius: 14px; display: grid; place-items: center; background: linear-gradient(160deg, rgba(217, 181, 102, .22), rgba(217, 181, 102, .05)); border: 1px solid var(--gold-line); flex: none; }
.feature-icon svg { width: 28px; height: 28px; fill: var(--gold); stroke: none; }
.feature-icon svg.stroke { fill: none; stroke: var(--gold); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.feature h3 { margin: 0; font: 600 20px/1.2 var(--sans); letter-spacing: .02em; min-width: 0; }
.feature h3 small { display: block; margin-top: 4px; color: var(--muted); font: 400 12.5px/1.4 var(--sans); letter-spacing: .06em; }
.feature-emblem { position: absolute; right: -6px; top: 50%; transform: translateY(-50%); width: 120px; height: 90px; opacity: .95; pointer-events: none; }
a.feature:hover { border-color: var(--gold); }
.home-lower { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 28px; margin-top: 30px; align-items: start; scroll-margin-top: 80px; }
.room-list-head { display: flex; align-items: baseline; gap: 14px; margin: 0 0 14px; }
.room-list-head h2 { margin: 0; font: 600 22px/1.2 var(--sans); letter-spacing: .02em; }
.room-list-head small { color: var(--muted); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; }
.room-list-refresh { margin-left: auto; min-height: 36px; border: 0; background: none; color: var(--gold); font-size: 13px; display: inline-flex; align-items: center; gap: 6px; padding: 0 4px; }
.room-list-refresh svg { width: 15px; height: 15px; }
.room-list-box { overflow: hidden; }
.room-list-columns { display: grid; grid-template-columns: 170px minmax(0, 1fr) auto; gap: 16px; padding: 12px 18px; color: var(--muted); font-size: 13px; letter-spacing: .04em; border-bottom: 1px solid var(--gold-line); background: rgba(217, 181, 102, .05); }
.room-list-empty { margin: 0; padding: 22px 18px; color: var(--muted); font-size: 13px; line-height: 1.7; }
.room-list-items { margin: 0; padding: 0; list-style: none; }
.room-list-items:empty { display: none; }
.room-row { display: grid; grid-template-columns: 170px minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 14px 18px; border-bottom: 1px solid rgba(255, 255, 255, .06); }
.room-row:last-child { border-bottom: 0; }
.room-row.is-mine { background: rgba(217, 181, 102, .05); }
.room-row-title { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.room-row-title strong { font: 600 20px/1 var(--num); letter-spacing: .14em; color: var(--gold-hi); font-variant-numeric: tabular-nums; }
.room-chip { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 12px; font-size: 11.5px; letter-spacing: .03em; border: 1px solid var(--gold-line); background: var(--glass); color: var(--muted); white-space: nowrap; }
.room-chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--dim); }
.room-chip.is-live { color: var(--gold-hi); background: rgba(217, 181, 102, .1); border-color: rgba(217, 181, 102, .4); }
.room-chip.is-live::before { background: var(--gold); box-shadow: 0 0 8px var(--gold); }
.room-chip.is-waiting { color: var(--green); background: var(--green-bg); border-color: rgba(143, 224, 174, .25); }
.room-chip.is-waiting::before { background: var(--green); box-shadow: 0 0 8px var(--green); }
.room-row-meta { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
.room-row-actions { display: flex; align-items: center; gap: 8px; justify-content: flex-end; }
.room-row-actions button { min-height: 38px; border-radius: 19px; font-size: 14px; background: transparent; }
.room-row-enter { min-width: 84px; padding: 0 18px; border: 1px solid var(--gold); color: var(--gold-hi); }
.room-row-enter:not(:disabled):hover { background: rgba(217, 181, 102, .12); }
.room-row-delete { padding: 0 12px; border: 1px solid transparent; color: var(--dim); font-size: 13px; }
.room-row-delete.is-confirming { color: #e36b5a; border-color: rgba(227, 107, 90, .4); }
.room-list-note { margin: 10px 2px 0; color: var(--dim); font-size: 12px; }
.quick-start { position: relative; overflow: hidden; padding: 26px 28px 24px; min-height: 236px; }
.quick-start img { position: absolute; right: -30px; top: -20px; width: 300px; height: 220px; object-fit: cover; object-position: 88% 55%; opacity: .55; -webkit-mask-image: linear-gradient(225deg, #000 20%, transparent 70%); mask-image: linear-gradient(225deg, #000 20%, transparent 70%); }
.quick-start h2 { position: relative; margin: 0; font: 600 26px/1.2 var(--sans); letter-spacing: .02em; }
.quick-start p { position: relative; margin: 6px 0 22px; color: var(--muted); font-size: 14px; }
.steps { position: relative; display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.step { display: flex; flex-direction: column; align-items: center; gap: 10px; flex: 1; text-align: center; font-size: 14px; }
.step-ring { width: 58px; height: 58px; border-radius: 50%; border: 1.5px solid var(--gold); display: grid; place-items: center; color: var(--gold-hi); background: rgba(217, 181, 102, .06); box-shadow: 0 0 0 6px rgba(217, 181, 102, .06); }
.step-ring svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.step-ring svg.fill { fill: currentColor; stroke: none; }
.step small { display: block; color: var(--muted); font-size: 11.5px; letter-spacing: .04em; }
.step-arrow { align-self: center; margin-top: -26px; color: var(--gold); font-size: 18px; }

/* ---- create / join / login / register ---- */
.form-wrap { display: grid; grid-template-columns: 440px minmax(0, 1fr); gap: 34px; max-width: 1120px; margin: 40px auto 20px; align-items: stretch; }
.form-side { position: relative; overflow: hidden; min-height: 620px; }
.form-side img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 26% 50%; }
.form-side::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8, 9, 8, .15), rgba(8, 9, 8, .9) 78%); }
.form-side.king-side { background: #060606; }
.form-side.king-side img { object-fit: contain; object-position: 50% 0; padding: 18px 18px 0; }
.form-side.king-side::after { background: linear-gradient(180deg, rgba(6, 6, 6, 0) 42%, rgba(6, 6, 6, .94) 70%); }
.form-side-copy { position: absolute; left: 28px; right: 28px; bottom: 26px; z-index: 2; }
.form-side-copy .eyebrow { font-size: 11px; }
.form-side-copy h2 { margin: 12px 0 6px; font: 700 34px/1.05 var(--serif); letter-spacing: .02em; text-transform: uppercase; }
.form-side-copy p { margin: 0 0 18px; color: var(--ivory); opacity: .85; font-size: 14px; }
.mini-steps, .perks { display: flex; flex-direction: column; gap: 10px; font-size: 13px; color: var(--muted); }
.mini-steps b { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: 10px; border-radius: 50%; border: 1px solid var(--gold); color: var(--gold-hi); font: 600 11px/1 var(--num); }
.perks span::before { content: "◆"; font-size: 7px; color: var(--gold); margin-right: 10px; vertical-align: 2px; }
.form-panel { padding: 34px 40px 30px; min-width: 0; }
.phone-hero { display: none; }
.entry-back { display: inline-flex; align-items: center; gap: 6px; padding: 5px 7px; margin: 0 0 14px -7px; min-height: 40px; border: 0; background: none; color: var(--muted); font-size: 13px; }
.entry-back:hover { color: var(--gold); }
.entry-back svg { width: 16px; height: 16px; }
.form-title { display: flex; align-items: baseline; gap: 14px; margin: 0 0 6px; }
.form-title h1 { margin: 0; font: 600 32px/1.1 var(--sans); letter-spacing: .02em; }
.form-title h1:focus { outline: none; }
.form-title small { color: var(--gold); font: 500 12px/1 var(--serif); letter-spacing: .3em; text-transform: uppercase; }
.entry-instruction { margin: 0 0 22px; color: var(--muted); font-size: 14px; line-height: 1.7; }
.entry-tabs { display: none; }
.create-settings { margin: 0 0 18px; border: 1px solid var(--gold-line); border-radius: 12px; overflow: hidden; background: rgba(0, 0, 0, .2); }
.create-settings summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; list-style: none; min-height: 64px; padding: 12px 18px; background: rgba(217, 181, 102, .06); font-size: 15px; font-weight: 600; }
.create-settings summary::-webkit-details-marker { display: none; }
.create-settings summary small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; font-weight: 400; }
.create-settings summary svg { color: var(--gold); transform: rotate(-90deg); transition: transform .15s; }
.create-settings[open] summary svg { transform: rotate(90deg); }
.create-settings .config-fields { padding: 16px 18px 2px; border-top: 1px solid var(--gold-line); }
.create-settings .field { margin-bottom: 14px; }
.create-settings .field input, .create-settings .field select { height: 46px; font-size: 15px; }
.buy-in-field { margin-top: 2px; }
.buy-in-field .field-hint { margin: -8px 0 16px; font-size: 12.5px; color: var(--dim); }
.entry-submit { width: 100%; justify-content: space-between; min-height: 60px; font-size: 18px; margin-top: 4px; }
.entry-footnote, .auth-foot { font-size: 12.5px; margin: 14px 0 0; text-align: center; color: var(--dim); }
.auth-foot { color: var(--muted); font-size: 13px; }
.auth-foot .link-button { margin-left: 6px; }
.resume-panel { display: flex; align-items: center; gap: 14px; padding: 12px 16px; margin: 0 0 22px; border-radius: 12px; border: 1px solid rgba(143, 224, 174, .25); background: rgba(15, 59, 42, .35); }
.resume-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); flex: none; }
.resume-panel p { margin: 0; font-size: 13.5px; flex: 1; }
.resume-panel .btn { flex: none; }

/* ---- responsive ---- */
@media (max-width: 1100px) {
  .hero-title { font-size: 54px; }
  .home-lower { grid-template-columns: minmax(0, 1fr) 360px; }
  .form-wrap { grid-template-columns: 360px minmax(0, 1fr); gap: 24px; }
}
@media (max-width: 900px) {
  .shell { padding: 0 24px; }
  .hero { grid-template-columns: 1fr; gap: 22px; min-height: 0; padding-top: 24px; }
  .hero-art { height: 300px; order: -1; }
  .features { gap: 12px; }
  .feature { padding: 0 16px; min-height: 96px; }
  .feature h3 { font-size: 17px; }
  .feature-emblem { display: none; }
  .home-lower { grid-template-columns: 1fr; gap: 22px; }
  .form-wrap { grid-template-columns: 1fr; gap: 0; margin: 0 auto; max-width: 640px; }
  .form-side { display: none; }
  .form-panel { padding: 0 0 26px; border: 0; border-radius: 0; background: none; box-shadow: none; }
  .phone-hero { display: block; position: relative; height: 180px; margin: 0 -24px 18px; overflow: hidden; }
  .phone-hero img { width: 100%; height: 100%; object-fit: cover; object-position: 60% 45%; display: block; }
  .phone-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 11, 10, .1), rgba(10, 11, 10, .95)); }
  .phone-hero.king-hero { height: 236px; }
  .phone-hero.king-hero img { object-position: 50% 16%; }
  .phone-hero.king-hero::after { background: linear-gradient(180deg, rgba(10, 11, 10, .05), rgba(10, 11, 10, .3) 60%, rgba(10, 11, 10, .97)); }
  .entry-back { margin-top: -6px; }
}
@media (max-width: 600px) {
  .shell { padding: 0 16px; }
  .masthead { height: 60px; gap: 10px; }
  .brand-mark { width: 34px; height: 34px; border-radius: 9px; }
  .brand-mark svg { width: 16px; height: 26px; }
  .brand-name { font-size: 18px; letter-spacing: .08em; }
  .brand-tagline { display: none; }
  .site-nav { display: none; }
  .user-button, .account-menu { min-height: 36px; padding: 0 12px 0 4px; gap: 7px; }
  .user-avatar { width: 28px; height: 28px; font-size: 12px; }
  .user-avatar svg { width: 15px; height: 15px; }
  .user-label { font-size: 13px; }
  .user-label small { display: none; }
  .logout-button { padding: 0 6px; }
  .eyebrow { font-size: 11px; letter-spacing: .34em; }
  .eyebrow::before, .eyebrow::after { width: 28px; }
  .hero { padding-top: 22px; gap: 18px; }
  .hero-title { font-size: 40px; margin: 12px 0 18px; }
  .hero-art { height: 214px; border-radius: 14px; margin-top: 4px; }
  .hero-art img { object-position: 55% 50%; }
  .hero-art::after { background: linear-gradient(0deg, rgba(10, 11, 10, .55), transparent 45%); }
  .hero-actions { gap: 10px; }
  .hero-actions .btn { flex: 1; min-width: 0; min-height: 60px; padding: 0 14px; justify-content: center; gap: 8px; font-size: 17px; }
  .hero-actions .btn svg { width: 22px; height: 22px; }
  .hero-foot { gap: 8px 14px; margin-top: 16px; font-size: 12px; }
  .features { grid-template-columns: repeat(2, 1fr); gap: 8px; margin-top: 22px; }
  .feature { flex-direction: column; align-items: flex-start; min-height: 0; padding: 12px 12px 11px; gap: 10px; border-radius: 12px; }
  .feature-icon { width: 38px; height: 38px; border-radius: 10px; }
  .feature-icon svg { width: 20px; height: 20px; }
  .feature h3 { font-size: 14px; white-space: nowrap; max-width: 100%; }
  .feature h3 small { font-size: 10.5px; margin-top: 3px; letter-spacing: .02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .room-list-head h2 { font-size: 18px; }
  .room-list-columns { display: none; }
  .room-list-box { padding: 10px; background: none; border: 0; box-shadow: none; }
  .room-list-empty { padding: 16px 6px; }
  .room-list-items { display: flex; flex-direction: column; gap: 10px; }
  .room-row { grid-template-columns: minmax(0, 1fr) auto; gap: 6px 12px; padding: 14px 16px; border: 1px solid var(--gold-line); border-radius: 14px; background: linear-gradient(180deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .025)); }
  .room-row:last-child { border-bottom: 1px solid var(--gold-line); }
  .room-row-title strong { font-size: 22px; letter-spacing: .16em; }
  .room-row-meta { grid-column: 1; font-size: 12px; }
  .room-row-actions { grid-column: 2; grid-row: 1 / 3; flex-direction: column; align-items: flex-end; }
  .room-row-enter { min-width: 72px; padding: 0 16px; }
  .room-list-note { font-size: 11.5px; }
  .quick-start { padding: 20px 18px 18px; min-height: 0; }
  .quick-start img { width: 220px; height: 170px; right: -50px; top: -30px; opacity: .4; }
  .quick-start h2 { font-size: 20px; }
  .quick-start p { font-size: 13px; margin-bottom: 16px; }
  .step { font-size: 13px; }
  .step-ring { width: 48px; height: 48px; }
  .step-ring svg { width: 22px; height: 22px; }
  .step small { font-size: 10.5px; }
  .step-arrow { margin-top: -20px; font-size: 15px; }
  .phone-hero { margin: 0 -16px 18px; height: 150px; }
  .form-title h1 { font-size: 26px; }
  .entry-instruction { font-size: 13px; margin-bottom: 18px; }
  .field-row { gap: 10px; }
  .entry-submit { min-height: 56px; font-size: 17px; }
  .resume-panel { flex-wrap: wrap; }
}

/* ---- the account chip in the header (who will sit down) ---- */
.account-chip { display: inline-flex; align-items: center; gap: 9px; min-height: 42px; max-width: 220px; padding: 0 16px 0 6px; border-radius: 21px; border: 1px solid var(--gold); background: rgba(217, 181, 102, .08); color: var(--gold-hi); font-size: 14px; font-weight: 600; white-space: nowrap; }
.account-chip:not(.is-signed-in) { padding-left: 16px; }
.account-chip:not(.is-signed-in)::before { content: ""; width: 18px; height: 18px; flex: none; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21c0-4 3.6-7 8-7s8 3 8 7'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21c0-4 3.6-7 8-7s8 3 8 7'/%3E%3C/svg%3E") center / contain no-repeat; }
.account-chip:not(.is-signed-in)::after { content: " / 注册"; }
.account-chip-face:empty { display: none; }
.account-chip-avatar { width: 30px; height: 30px; }
.account-chip-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-chip:hover { background: rgba(217, 181, 102, .16); }
@media (max-width: 600px) {
  .account-chip { min-height: 36px; max-width: 160px; padding: 0 12px 0 4px; gap: 7px; font-size: 13px; }
  .account-chip:not(.is-signed-in) { padding-left: 12px; }
  .account-chip-avatar { width: 28px; height: 28px; }
}
