/* ===== Okey Helper · Metin2Community ===== */

:root {
  --bg: #0b0d14;
  --bg-2: #11141f;
  --panel: rgba(22, 26, 40, 0.82);
  --panel-border: rgba(255, 255, 255, 0.07);
  --text: #eef0f6;
  --muted: #8b91a8;
  --gold: #f5c542;
  --gold-2: #d99a1e;
  --silver: #c9d1e0;
  --bronze: #c98a4b;
  --accent: #6d7cff;
  --danger: #ff5c7a;
  --ok: #4ade80;

  --card-r: #e0433f;
  --card-r-2: #9c1f1c;
  --card-b: #3f7fe0;
  --card-b-2: #1d3f8f;
  --card-y: #f2c230;
  --card-y-2: #a8780a;

  --radius: 16px;
  --radius-s: 10px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Cinzel", "Inter", serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
}
button { font: inherit; color: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }

/* fundal */
.bg-glow {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(900px 500px at 15% -10%, rgba(245, 197, 66, 0.14), transparent 60%),
    radial-gradient(800px 500px at 90% 10%, rgba(109, 124, 255, 0.14), transparent 60%),
    radial-gradient(700px 500px at 50% 110%, rgba(224, 67, 63, 0.10), transparent 60%),
    var(--bg);
}
.fx-canvas {
  position: fixed; inset: 0; z-index: 50; pointer-events: none;
  width: 100%; height: 100%;
}
body.no-fx .fx-canvas { display: none; }

/* ===== topbar ===== */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 12px 16px;
  padding-top: max(12px, env(safe-area-inset-top));
  position: sticky; top: 0; z-index: 20;
  background: linear-gradient(to bottom, rgba(11, 13, 20, 0.95), rgba(11, 13, 20, 0.7));
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--panel-border);
}
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-logo { width: 46px; height: 46px; display: grid; place-items: center; filter: drop-shadow(0 0 10px rgba(90,170,255,0.45)); }
.brand-logo img { width: 46px; height: 46px; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; min-width: 0; }
.brand-name { font-family: var(--font-display); font-weight: 800; font-size: 17px; letter-spacing: 0.02em; white-space: nowrap; }
.brand-accent { color: var(--gold); }
.brand-sub { font-size: 12px; color: var(--muted); }
.topbar-actions { display: flex; gap: 8px; }

/* ===== butoane ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 18px; border-radius: 12px; border: 1px solid var(--panel-border);
  background: rgba(255,255,255,0.05); font-weight: 600; font-size: 15px;
  transition: transform 0.12s ease, background 0.15s ease, opacity 0.15s ease, box-shadow 0.2s ease;
  user-select: none;
}
.btn:hover:not(:disabled) { background: rgba(255,255,255,0.09); }
.btn:active:not(:disabled) { transform: translateY(1px) scale(0.99); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }
.btn-icon { padding: 10px; width: 42px; height: 42px; border-radius: 12px; }
.btn-small { padding: 8px 12px; font-size: 13px; }
.btn-ghost { background: transparent; }
.btn-primary { background: linear-gradient(135deg, #6d7cff, #4f5fe6); border-color: transparent; color: #fff;
  box-shadow: 0 6px 18px rgba(109,124,255,0.35); }
.btn-primary:hover:not(:disabled) { background: linear-gradient(135deg, #7c8aff, #5a6aee); }
.btn-gold { background: linear-gradient(135deg, var(--gold), var(--gold-2)); border-color: transparent; color: #1a1300;
  box-shadow: 0 6px 18px rgba(245,197,66,0.35); }
.btn-gold:hover:not(:disabled) { filter: brightness(1.06); }
.btn-discord { background: #5865f2; border-color: transparent; color: #fff; padding: 10px 14px; }
.btn-discord:hover { background: #6a75f5; }
.btn-settings { padding: 10px 14px; background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.12); }
.btn-settings:hover { background: rgba(255,255,255,0.11); }
.btn-settings svg { transition: transform 0.4s ease; }
.btn-settings:hover svg { transform: rotate(60deg); }
@media (max-width: 480px) {
  .btn-discord span, .btn-settings span { display: none; }
  .btn-discord, .btn-settings { width: 42px; padding: 10px; }
}

/* ===== layout ===== */
.layout {
  display: grid; gap: 16px; padding: 16px;
  max-width: 1180px; margin: 0 auto;
  grid-template-columns: 1fr;
}
@media (min-width: 900px) {
  .layout { grid-template-columns: minmax(0, 1fr) 320px; padding: 24px; gap: 20px; }
  .side { position: sticky; top: 84px; align-self: start; display: flex; flex-direction: column; gap: 20px; }
}
.play { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.side { display: flex; flex-direction: column; gap: 16px; }

.card-panel {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}
.panel-title {
  font-size: 12px; text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--muted); font-weight: 600; margin-bottom: 12px;
}

/* ===== scorebar ===== */
.scorebar { display: flex; align-items: center; gap: 16px; }
.scorebar-left { display: flex; flex-direction: column; min-width: 90px; }
.scorebar-label { font-size: 12px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--muted); font-weight: 600; }
.score { font-family: var(--font-display); font-size: 44px; font-weight: 800; line-height: 1; color: var(--gold);
  text-shadow: 0 0 24px rgba(245,197,66,0.35); font-variant-numeric: tabular-nums; }
.score.bump { animation: bump 0.45s cubic-bezier(.2,1.6,.4,1); }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.22); } 100% { transform: scale(1); } }
body.no-fx .score.bump { animation: none; }
.scorebar-right { flex: 1; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.chest-badge { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start;
  padding: 6px 12px; border-radius: 999px; font-weight: 600; font-size: 13px;
  background: rgba(255,255,255,0.05); border: 1px solid var(--panel-border); transition: all 0.3s; }
.chest-badge.chest-gold { color: var(--gold); border-color: rgba(245,197,66,0.4); background: rgba(245,197,66,0.1); box-shadow: 0 0 18px rgba(245,197,66,0.25); }
.chest-badge.chest-silver { color: var(--silver); border-color: rgba(201,209,224,0.4); background: rgba(201,209,224,0.08); }
.chest-badge.chest-bronze { color: var(--bronze); }
.progress-track { position: relative; height: 8px; border-radius: 999px; background: rgba(255,255,255,0.08); overflow: visible; }
.progress-fill { height: 100%; border-radius: 999px; width: 0%;
  background: linear-gradient(90deg, var(--bronze), var(--silver) 70%, var(--gold));
  transition: width 0.6s cubic-bezier(.2,.8,.2,1); }
body.no-fx .progress-fill { transition: none; }
.progress-mark { position: absolute; top: -3px; width: 2px; height: 14px; background: rgba(255,255,255,0.35); border-radius: 2px; }
.progress-labels { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: 4px;
  font-variant-numeric: tabular-nums; }
.progress-labels span:nth-child(2) { margin-left: auto; margin-right: 6%; }
.score-next { font-size: 13px; color: var(--muted); min-height: 16px; }

/* ===== sugestie ===== */
.suggestion {
  border-radius: var(--radius-s); padding: 12px 14px; margin-bottom: 12px;
  background: linear-gradient(135deg, rgba(109,124,255,0.14), rgba(109,124,255,0.04));
  border: 1px solid rgba(109,124,255,0.35); position: relative; overflow: hidden;
}
.suggestion.is-discard { background: linear-gradient(135deg, rgba(255,92,122,0.14), rgba(255,92,122,0.04)); border-color: rgba(255,92,122,0.35); }
.suggestion.is-waiting { background: rgba(255,255,255,0.03); border-color: var(--panel-border); }
.suggestion-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.suggestion-title { font-size: 12px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--muted); font-weight: 600; }
.suggestion-status { font-size: 11px; color: var(--muted); }
.suggestion-status.pending::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px;
  border: 2px solid var(--accent); border-top-color: transparent; animation: spin 0.8s linear infinite; vertical-align: -1px; }
@keyframes spin { to { transform: rotate(360deg); } }
.suggestion-status.exact { color: var(--ok); }
.suggestion-text { font-size: 17px; font-weight: 600; line-height: 1.35; }
.suggestion-odds { font-size: 13px; color: var(--muted); margin-top: 4px; font-variant-numeric: tabular-nums; }
.auto-bar { position: relative; height: 22px; margin-top: 10px; border-radius: 999px; background: rgba(255,255,255,0.08); overflow: hidden; }
.auto-bar-fill { position: absolute; inset: 0; width: 0%; background: linear-gradient(90deg, var(--accent), #9aa5ff); }
.auto-bar-text { position: relative; display: block; text-align: center; font-size: 12px; font-weight: 600; line-height: 22px; }

.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.actions-secondary { grid-column: 1 / -1; display: flex; gap: 10px; }
.actions-secondary .btn { flex: 1; }
.pick-info { margin-top: 10px; font-size: 13px; color: var(--muted); min-height: 16px; text-align: center; }
.pick-info strong { color: var(--text); }

/* ===== statistici ===== */
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.stat { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 10px; background: rgba(255,255,255,0.04); border: 1px solid var(--panel-border); }
.stat-label { font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); }
.stat-value { font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat-value small { font-size: 12px; color: var(--muted); font-weight: 500; }
.stat.gold .stat-value { color: var(--gold); }
.stat.silver .stat-value { color: var(--silver); }
.stat.bronze .stat-value { color: var(--bronze); }
.stats .btn { width: 100%; }

/* ===== ghid ===== */
.guide-body p { font-size: 13.5px; line-height: 1.55; color: #c9cddb; margin: 0 0 10px; }
.scoring { width: 100%; border-collapse: collapse; margin-top: 6px; }
.scoring td { padding: 6px 0; border-top: 1px solid var(--panel-border); font-size: 13px; font-weight: 600; }
.scoring td:last-child { text-align: right; color: var(--gold); font-variant-numeric: tabular-nums; }
.mini-cards { display: inline-flex; gap: 4px; }
.mini-cards i { font-style: normal; width: 22px; height: 28px; border-radius: 4px; display: grid; place-items: center; font-size: 12px; font-weight: 800; color: #fff; }
.mini-cards i.r { background: var(--card-r); } .mini-cards i.b { background: var(--card-b); } .mini-cards i.y { background: var(--card-y); color: #2b1d00; }

/* ===== footer ===== */
.footer { text-align: center; font-size: 12px; color: var(--muted); padding: 24px 16px calc(24px + env(safe-area-inset-bottom)); }
.footer .sep { margin: 0 8px; }

/* ===== modal ===== */
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(5,6,10,0.7); backdrop-filter: blur(6px); }
.modal-card {
  position: relative; width: min(440px, 100%); background: #151928; border: 1px solid var(--panel-border);
  border-radius: 18px; padding: 20px; box-shadow: 0 30px 60px rgba(0,0,0,0.6);
  animation: modalin 0.25s cubic-bezier(.2,.9,.3,1.1) both;
}
@keyframes modalin { from { transform: translateY(16px) scale(0.97); opacity: 0; } }
body.no-fx .modal-card { animation: none; }
.modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.modal-head h2 { margin: 0; font-family: var(--font-display); font-size: 20px; }

.setting { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-top: 1px solid var(--panel-border); cursor: pointer; }
.setting-text { display: flex; flex-direction: column; gap: 2px; }
.setting-name { font-weight: 600; font-size: 15px; }
.setting-hint { font-size: 12px; color: var(--muted); }
.setting-range { flex-direction: column; align-items: stretch; }
.setting-range input[type="range"] { width: 100%; accent-color: var(--accent); margin-top: 6px; }
.setting-range[hidden] { display: none; }

.switch { position: relative; width: 48px; height: 28px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch-slider { position: absolute; inset: 0; border-radius: 999px; background: rgba(255,255,255,0.12); transition: background 0.2s; }
.switch-slider::before { content: ""; position: absolute; width: 22px; height: 22px; left: 3px; top: 3px; border-radius: 50%; background: #fff; transition: transform 0.2s; }
.switch input:checked + .switch-slider { background: var(--accent); }
.switch input:checked + .switch-slider::before { transform: translateX(20px); }

.lang-group { display: flex; gap: 6px; }
.lang-btn { padding: 8px 12px; border-radius: 8px; border: 1px solid var(--panel-border); background: transparent; font-weight: 700; font-size: 13px; }
.lang-btn.active { background: var(--gold); color: #1a1300; border-color: transparent; }

.done-card { text-align: center; display: flex; flex-direction: column; gap: 12px; align-items: center; }
.done-card h2 { margin: 0; font-family: var(--font-display); }
.done-card p { margin: 0; color: #c9cddb; line-height: 1.5; }
.done-chest { font-size: 64px; line-height: 1; animation: chestpop 0.6s cubic-bezier(.2,1.6,.4,1) both; }
@keyframes chestpop { from { transform: scale(0.3) rotate(-10deg); opacity: 0; } }
body.no-fx .done-chest { animation: none; }
.done-card .btn-gold { width: 100%; }

/* ===== toast ===== */
.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px);
  background: #1c2134; border: 1px solid var(--panel-border); color: var(--text); padding: 10px 16px; border-radius: 12px;
  font-size: 14px; font-weight: 600; opacity: 0; pointer-events: none; z-index: 120; transition: all 0.25s; box-shadow: var(--shadow);
  max-width: calc(100% - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ===== CTK: hub button, footer ===== */
.btn-hub { padding: 10px 14px; background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.12); }
@media (max-width: 560px) { .btn-hub span { display: none; } .btn-hub { width: 42px; padding: 10px; } }
.footer { display: flex; flex-direction: column; gap: 6px; }
.disclaimer { font-size: 11px; color: rgba(139,145,168,0.7); max-width: 720px; margin: 0 auto; line-height: 1.5; }
.progress-labels.ctk span:nth-child(2) { margin: 0 0 0 10%; }
.progress-labels.ctk span:nth-child(3) { margin-left: auto; margin-right: 14%; }
.score-ceiling { font-size: 12px; color: var(--muted); margin-top: 4px; }
.score-ceiling.bad { color: var(--danger); }
.score-ceiling.good { color: var(--ok); }
.chest-badge.chest-none { color: var(--muted); }
.actions.two { grid-template-columns: 1fr 1fr; }

/* ===== grila ===== */
.grid-wrap { position: relative; }
.grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 14px; max-width: 520px; margin-left: auto; margin-right: auto; }
@media (min-width: 520px) { .grid { gap: 10px; } }
.cell { position: relative; aspect-ratio: 240 / 300; border: none; background: transparent; padding: 0; border-radius: 10px;
  perspective: 600px; transition: transform 0.18s ease; }
.cell:hover { transform: translateY(-3px) scale(1.03); z-index: 2; }
.cell-inner { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform 0.55s cubic-bezier(.2,.8,.2,1); border-radius: 10px; }
.cell.revealed .cell-inner { transform: rotateY(180deg); }
body.no-fx .cell-inner { transition: none; }
.face { position: absolute; inset: 0; backface-visibility: hidden; border-radius: 10px; overflow: hidden; box-shadow: 0 4px 12px rgba(0,0,0,0.5); }
.face img { width: 100%; height: 100%; object-fit: cover; display: block; user-select: none; -webkit-user-drag: none; }
.face.front { transform: rotateY(180deg); }
.cell.unscored .face.front img { filter: brightness(0.45) saturate(0.6); }
.cell.catchable .face.front { outline: 2px solid rgba(74,222,128,0.8); outline-offset: -2px; }
.cell.catchable .face.front img { filter: brightness(0.7); }
.cell.catchable:hover .face.front img { filter: brightness(0.95); }

.cell-p5 { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--font-display); font-weight: 800;
  font-size: clamp(14px, 3.6vw, 24px); color: #fff; text-shadow: 0 2px 6px rgba(0,0,0,0.8); pointer-events: none; z-index: 3; }
.cell.maybe5 .face.back::after { content: ""; position: absolute; inset: 0; background: rgba(224,67,63, calc(0.18 + var(--p5, 0) * 0.5)); }
.cell.maybe5 .cell-p5 { color: #ffb3ad; }
.cell.must5 .face.back { outline: 3px dashed #ff5c7a; outline-offset: -3px; }
.cell.must5 .face.back::after { content: ""; position: absolute; inset: 0; background: rgba(255,92,122,0.55); }
.cell.must5 .cell-p5 { font-size: clamp(22px, 6vw, 40px); color: #fff; }
.cell.mustK .face.back::after { content: ""; position: absolute; inset: 0; background: rgba(245,197,66,0.45); }
.cell.mustK .cell-p5 { color: var(--gold); font-size: clamp(22px, 6vw, 40px); }
.cell.not5 .face.back { outline: 2px solid rgba(74,222,128,0.35); outline-offset: -2px; }
.cell.safe5 .face.back { outline: 3px solid var(--ok); outline-offset: -3px; box-shadow: 0 0 16px rgba(74,222,128,0.5); }
.cell.safe5 .face.back::after { content: ""; position: absolute; inset: 0; background: rgba(74,222,128,0.18); }

.cell.hint { z-index: 2; }
.cell.hint::before { content: ""; position: absolute; inset: -4px; border-radius: 14px; border: 3px solid var(--gold);
  box-shadow: 0 0 22px rgba(245,197,66,0.7), inset 0 0 12px rgba(245,197,66,0.3); animation: hintpulse 1.4s ease-in-out infinite; pointer-events: none; z-index: 4; }
.cell.hint .cell-badge { position: absolute; top: -9px; left: 50%; transform: translateX(-50%); background: var(--gold); color: #1a1300;
  font-size: 10px; font-weight: 800; letter-spacing: 0.08em; padding: 2px 8px; border-radius: 999px; z-index: 5; box-shadow: 0 2px 8px rgba(0,0,0,0.5); }
.cell.hint .cell-badge::before { content: "AICI"; }
html[lang="en"] .cell.hint .cell-badge::before { content: "HERE"; }
.cell:not(.hint) .cell-badge { position: absolute; top: 4px; right: 6px; font-size: 12px; color: #fff; text-shadow: 0 0 6px #6d7cff, 0 0 10px #6d7cff; z-index: 4; pointer-events: none; }
@keyframes hintpulse { 0%,100% { opacity: 0.55; transform: scale(1); } 50% { opacity: 1; transform: scale(1.03); } }
body.no-fx .cell.hint::before { animation: none; opacity: 0.9; }
.cell.picking { transform: translateY(-3px) scale(1.06); z-index: 3; }
.cell.picking .face { box-shadow: 0 0 0 3px var(--accent), 0 8px 24px rgba(109,124,255,0.5); }
.cell.flip .cell-inner { animation: none; }

/* ===== picker ===== */
.picker { position: absolute; z-index: 30; width: min(340px, 100%); background: #171b2b; border: 1px solid rgba(255,255,255,0.14); border-radius: 14px;
  padding: 12px; box-shadow: 0 20px 50px rgba(0,0,0,0.6); animation: modalin 0.18s ease both; }
body.no-fx .picker { animation: none; }
.picker-title { font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); font-weight: 600; margin-bottom: 10px; }
.picker-values { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; margin-bottom: 10px; }
.picker.mode-catch .picker-values, .picker.mode-catch .picker-flash { display: none; }
.pv { border: none; background: transparent; padding: 0; border-radius: 8px; position: relative; aspect-ratio: 240/300; overflow: hidden;
  box-shadow: 0 3px 8px rgba(0,0,0,0.5); transition: transform 0.12s; }
.pv img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pv b { display: none; }
.pv:hover:not(.off) { transform: translateY(-3px) scale(1.06); }
.pv.off { opacity: 0.2; filter: grayscale(1); cursor: not-allowed; }
.picker-flash { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; background: rgba(109,124,255,0.1); border: 1px solid rgba(109,124,255,0.3); cursor: pointer; margin-bottom: 10px; }
.picker-flash input { position: absolute; opacity: 0; width: 0; height: 0; }
.picker-flash span:last-child { display: flex; flex-direction: column; line-height: 1.2; }
.picker-flash strong { font-size: 14px; }
.picker-flash small { font-size: 11px; color: var(--muted); }
.switch-mini { width: 38px; height: 22px; border-radius: 999px; background: rgba(255,255,255,0.14); position: relative; flex-shrink: 0; transition: background 0.2s; }
.switch-mini::before { content: ""; position: absolute; width: 16px; height: 16px; left: 3px; top: 3px; border-radius: 50%; background: #fff; transition: transform 0.2s; }
.picker-flash input:checked + .switch-mini { background: #f5c542; }
.picker-flash input:checked + .switch-mini::before { transform: translateX(16px); }
.picker-catch-body { font-size: 15px; font-weight: 600; margin-bottom: 10px; }
.picker-catch-btns { display: flex; gap: 8px; margin-bottom: 8px; }
.picker-catch-btns .btn { flex: 1; }
.picker-cancel { width: 100%; }

/* ===== legenda ===== */
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 12px; font-size: 11.5px; color: var(--muted); }
.lg { display: inline-flex; align-items: center; gap: 6px; }
.lg::before { content: ""; width: 12px; height: 12px; border-radius: 3px; flex-shrink: 0; }
.lg-hint::before { border: 2px solid var(--gold); box-shadow: 0 0 6px rgba(245,197,66,0.7); }
.lg-five::before { background: rgba(224,67,63,0.5); }
.lg-must::before { border: 2px dashed #ff5c7a; background: rgba(255,92,122,0.5); }
.lg-safe::before { border: 2px solid var(--ok); background: rgba(74,222,128,0.2); }
.lg-dim::before { background: #444; }

/* ===== mana ===== */
.hand-now { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.hand-card { width: 72px; aspect-ratio: 240/300; border-radius: 8px; overflow: hidden; box-shadow: 0 6px 16px rgba(0,0,0,0.5), 0 0 0 2px rgba(245,197,66,0.5); flex-shrink: 0; }
.hand-card img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hand-value { font-family: var(--font-display); font-size: 36px; font-weight: 800; color: var(--gold); line-height: 1; }
.hand-hint { font-size: 12px; color: var(--muted); margin-top: 4px; }
.hand-seq { display: grid; grid-template-columns: repeat(12, 1fr); gap: 3px; }
.hs { aspect-ratio: 240/300; border-radius: 4px; overflow: hidden; opacity: 0.85; }
.hs img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hs.done { opacity: 0.22; filter: grayscale(1); }
.hs.now { opacity: 1; outline: 2px solid var(--gold); outline-offset: 1px; transform: scale(1.12); }

/* ===== sansa de aur ===== */
.gold-row { display: flex; align-items: center; gap: 14px; }
.gold-pct { font-family: var(--font-display); font-size: 40px; font-weight: 800; line-height: 1; min-width: 96px; transition: color 0.3s; }
.gold-pct.hi { color: var(--ok); } .gold-pct.mid { color: var(--gold); } .gold-pct.lo { color: var(--danger); }
.gold-pct.pending { opacity: 0.5; }
.gold-bars { flex: 1; display: flex; flex-direction: column; gap: 5px; }
.gbar { display: grid; grid-template-columns: 48px 1fr 40px; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.gbar i { display: block; height: 6px; border-radius: 999px; background: rgba(255,255,255,0.08); overflow: hidden; }
.gbar b { display: block; height: 100%; width: 0; border-radius: 999px; transition: width 0.5s ease; }
.gbar:nth-child(1) b { background: var(--gold); } .gbar:nth-child(2) b { background: var(--silver); } .gbar:nth-child(3) b { background: var(--bronze); }
.gbar em { font-style: normal; text-align: right; font-variant-numeric: tabular-nums; color: var(--text); }
.gold-panel .hint { margin-top: 8px; }

/* ===== ramase ===== */
.remaining { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.rem { display: flex; flex-direction: column; align-items: center; gap: 3px; font-variant-numeric: tabular-nums; }
.rem img { width: 100%; aspect-ratio: 240/300; object-fit: cover; border-radius: 5px; }
.rem b { font-size: 15px; } .rem small { font-size: 10px; color: var(--muted); margin-top: -3px; }
.rem.zero { opacity: 0.3; filter: grayscale(1); }

/* credit */
.site-by { margin-top: 14px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,0.06); font-size: 12.5px; color: var(--muted); letter-spacing: 0.04em; }
.site-by span { font-family: var(--font-display); font-weight: 800; font-size: 14px; letter-spacing: 0.06em;
  background: linear-gradient(90deg, #f5c542, #ffe38a 45%, #d99a1e); -webkit-background-clip: text; background-clip: text; color: transparent;
  text-shadow: none; filter: drop-shadow(0 0 8px rgba(245,197,66,0.35)); }

.footer-links { margin-top: 10px; font-size: 12.5px; }
.footer-links a { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.footer-links a:hover { color: var(--gold); }
