/* Ortak oyun ekranları, sinematik, telsiz ve gerilim efektleri. style.css'in üstüne gelir. */
[hidden] { display: none !important; }
.muted { color: var(--ink-3); }
.dossier .muted { color: #7a6c50; font-size: 14px; }
.btn.icon { padding: 7px 10px; }
.btn.wide { width: 100%; margin-top: 14px; padding: 14px; font-size: 16px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.end { justify-content: flex-end; margin-top: 20px; }
.row.center { justify-content: center; margin-top: 22px; }
code { font-family: var(--type); background: rgba(255,255,255,0.06); padding: 3px 8px; border-radius: 6px; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; }
input, select { font: inherit; color: var(--ink); background: var(--bg-2); border: 1px solid var(--line); border-radius: 8px; padding: 11px 12px; }
input::placeholder { color: var(--ink-3); }

/* Rain, vignette and lightning over every screen */
body::before {
  content: ""; position: fixed; inset: -50% 0 0; pointer-events: none; z-index: 1; opacity: 0.13;
  background-image: repeating-linear-gradient(104deg, transparent 0 9px, rgba(200,210,230,0.55) 9px 10px, transparent 10px 23px);
  background-size: 100% 220px; animation: rain 0.55s linear infinite;
}
@keyframes rain { to { transform: translateY(220px); } }
#app { position: relative; z-index: 2; }
.vignette, #app::after { content: ""; position: fixed; inset: 0; pointer-events: none; background: radial-gradient(120% 90% at 50% 40%, transparent 55%, rgba(0,0,0,0.65)); z-index: -1; }
body.flash #app::before { content: ""; position: fixed; inset: 0; z-index: 90; pointer-events: none; background: #dfe6ff; animation: flash 1.1s ease-out forwards; }
@keyframes flash { 0% { opacity: 0; } 4% { opacity: .5; } 9% { opacity: .05; } 14% { opacity: .35; } 100% { opacity: 0; } }

/* Home */
.hero h1 { text-shadow: 0 0 40px rgba(200,52,44,0.25); }
.hero .stamp { text-transform: none; letter-spacing: 0.12em; }
.joinbox { display: flex; gap: 10px; justify-content: center; margin: 30px auto 0; flex-wrap: wrap; max-width: 560px; }
.joinbox input { flex: 1; min-width: 140px; }
.joinbox #joincode { font-family: var(--type); font-size: 20px; letter-spacing: 0.35em; text-align: center; max-width: 170px; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; padding: 3px; margin-bottom: 14px; background: var(--bg-2); }
.seg button { border: 0; background: none; color: var(--ink-2); padding: 8px 16px; border-radius: 8px; font-weight: 600; }
.seg button.on { background: var(--panel); color: var(--ink); box-shadow: 0 2px 8px rgba(0,0,0,.4); }
.arch .area { color: var(--amber); font-size: 13px; }
.field { display: grid; gap: 6px; margin-top: 16px; font-size: 13px; color: var(--ink-2); }

/* Lobby */
.lobby { text-align: center; padding: 70px 0; }
.lobby .where { font-family: var(--type); color: var(--amber); }
.lobby > p { color: var(--ink-2); margin: 20px 0 10px; }
.code { display: flex; gap: 12px; justify-content: center; margin: 6px 0 16px; }
.code span { width: 76px; height: 96px; display: grid; place-items: center; font-family: var(--serif); font-size: 58px; font-weight: 800; background: var(--paper); color: var(--paper-ink); border-radius: 10px; box-shadow: 0 20px 40px -20px rgba(0,0,0,.9); }
.code span:nth-child(odd) { transform: rotate(-2deg); } .code span:nth-child(even) { transform: rotate(2deg); }
.lobby-how { margin: 30px auto 0; max-width: 520px; display: grid; gap: 8px; justify-items: center; }
.lobby-how p { margin: 4px 0; color: var(--ink-2); }
.waiting { margin-top: 34px; color: var(--ink-3); display: inline-flex; gap: 6px; align-items: center; }
.waiting i { width: 7px; height: 7px; border-radius: 50%; background: var(--amber); animation: blink 1.2s infinite; }
.waiting i:nth-child(2) { animation-delay: .2s; } .waiting i:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 50% { opacity: .2; } }

/* Game header */
.gtop { display: flex; align-items: center; gap: 12px; padding: 14px 22px; flex-wrap: wrap; }
.brand.small { font-size: 17px; }
.gcase { display: grid; line-height: 1.25; border-left: 1px solid var(--line); padding-left: 12px; }
.gcase b { font-family: var(--serif); font-size: 17px; }
.gcase span { font-size: 12px; color: var(--ink-3); }
.clock { display: grid; grid-template-columns: auto 140px; gap: 2px 10px; align-items: center; }
.clock .now { font-family: var(--type); font-size: 22px; grid-row: span 2; }
.clock small { font-size: 11.5px; color: var(--ink-3); }
.low .clock .now { color: var(--red); animation: pulse 1.05s infinite; }
@keyframes pulse { 50% { opacity: .45; } }
.low .stage { box-shadow: inset 0 0 80px rgba(200,52,44,0.12); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #555; display: inline-block; }
.dot.on { background: var(--green); box-shadow: 0 0 8px var(--green); }
.chip small { color: var(--ink-3); }
.tabs { display: flex; gap: 8px; margin-top: 12px; }
.tabs button { flex: 1; border: 1px solid var(--line); background: var(--panel); color: var(--ink-2); border-radius: 10px; padding: 10px 14px; font-weight: 600; text-align: left; }
.tabs button.on { border-color: var(--amber); color: var(--ink); background: rgba(226,169,59,0.1); }
.tabs small { display: block; font-weight: 400; color: var(--ink-3); }
.banner { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 12px; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); }
.banner b { display: block; font-family: var(--serif); font-size: 17px; }
.banner span { color: var(--ink-2); font-size: 14px; }
.banner.hot { border-color: var(--red); background: rgba(200,52,44,0.12); animation: glow 2s infinite; }
@keyframes glow { 50% { box-shadow: 0 0 24px rgba(200,52,44,0.35); } }

.col { display: grid; gap: 18px; }
.item .tag, .tag { font-style: normal; font-size: 11px; color: var(--amber); border: 1px solid rgba(226,169,59,.4); border-radius: 5px; padding: 1px 5px; margin-left: 4px; }
.item > span:not(.portrait):not(.loc-icon):not(.count) { display: grid; }
.count.crack { color: var(--red); }
.scene-head { display: flex; gap: 16px; align-items: center; }
.loc-icon.big { width: 64px; height: 64px; font-size: 32px; border-radius: 14px; }
.notice { margin: 16px 0; padding: 14px 16px; border-radius: 12px; background: rgba(95,174,115,0.08); border: 1px dashed rgba(95,174,115,0.5); }
.notice p { margin: 6px 0; line-height: 1.6; }
.notice small { color: var(--ink-3); }
.lock { margin: 16px 0; padding: 16px; border-radius: 12px; background: linear-gradient(180deg, #2a2418, #1f1b13); border: 1px solid #5b4a26; }
.lock.open { border-color: var(--green); background: rgba(95,174,115,0.08); }
.lock p { margin: 6px 0 12px; line-height: 1.6; color: #e6d7b0; }
.lockform { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.lockform input { font-family: var(--type); font-size: 26px; letter-spacing: 0.5em; width: 170px; text-align: center; background: #0f0d09; border-color: #5b4a26; }
.adv { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-2); cursor: pointer; }
.adv small { color: var(--ink-3); }
.adv.off { opacity: .45; }
.confront { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--line); display: grid; gap: 8px; }
.confront label { font-family: var(--serif); font-size: 17px; }
.confront select { flex: 1; min-width: 200px; }
.confront small { color: var(--ink-3); }
.overview .where { font-family: var(--type); color: var(--amber); font-size: 13px; }
.overview .victim { padding: 12px 14px; border-left: 4px solid var(--red); background: rgba(200,52,44,0.07); line-height: 1.6; }
.tip { margin: 18px 0; padding: 14px 16px; border-radius: 12px; background: rgba(226,169,59,0.07); line-height: 1.6; color: var(--ink-2); }
.tip b { color: var(--ink); margin-right: 6px; }

.note.key { outline: 2px solid var(--amber); }
.labres { margin-top: 8px; padding: 8px 10px; background: rgba(43,36,24,0.08); border-left: 3px solid #3e6a7a; font-size: 12.5px; }
.note-act { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.note-act .btn { padding: 5px 9px; font-size: 12px; }
.note-act .btn:not(.amber) { background: #2b2418; color: var(--paper); }

.radio .chat { max-height: 230px; overflow: auto; padding: 10px; display: grid; gap: 8px; align-content: start; }
.msg { justify-self: start; max-width: 85%; background: var(--bg-2); border: 1px solid var(--line); padding: 8px 11px; border-radius: 12px 12px 12px 3px; font-size: 14px; line-height: 1.45; }
.msg.me { justify-self: end; background: rgba(226,169,59,0.12); border-color: rgba(226,169,59,.35); border-radius: 12px 12px 3px 12px; }
.msg small { display: block; font-size: 11px; color: var(--ink-3); margin-top: 3px; }
.chatform { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); }
.chatform input { flex: 1; min-width: 0; padding: 9px 11px; }
.log b { font-family: var(--type); font-weight: 400; color: var(--ink-3); margin-right: 4px; }
.log .pt { color: #8fb6d6; }
.log .al { color: var(--amber); }

/* Accusation modal */
.modal { position: fixed; inset: 0; z-index: 40; background: rgba(5,6,8,0.8); backdrop-filter: blur(4px); display: grid; place-items: center; padding: 16px; overflow: auto; }
.modal-card { width: min(1000px, 100%); background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; padding: 26px; }
.modal-card h2 { font-family: var(--serif); font-size: 32px; margin: 0; }
.modal-card .grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 18px; }

/* Dice */
.dice-row { display: flex; justify-content: center; gap: 10px; }
.dice-row .d20 { margin: 18px 0 8px; }
.d20.dim { opacity: .35; transform: scale(.85); transition: .4s; }
.dice-card.won { box-shadow: 0 0 60px -10px rgba(95,174,115,0.45); }
.dice-card.lost { box-shadow: 0 0 60px -10px rgba(200,52,44,0.45); }
.reveal { display: grid; gap: 8px; margin-top: 12px; text-align: left; }
.reveal .clue { animation: drop .5s cubic-bezier(.2,.8,.2,1); }
@keyframes drop { from { opacity: 0; transform: translateY(-10px) rotate(-2deg); } }
.dice-foot { margin-top: 16px; }

/* Cinematic */
.cine { position: fixed; inset: 0; z-index: 80; background: #050506; display: grid; place-items: center; padding: 24px; animation: fadein .8s; }
.cine.out { animation: fadeout .7s forwards; }
@keyframes fadein { from { opacity: 0; } }
@keyframes fadeout { to { opacity: 0; } }
.cine::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(70% 60% at 50% 45%, transparent, rgba(0,0,0,.8)); }
.cine-in { position: relative; z-index: 1; width: min(720px, 100%); max-height: 100%; overflow: auto; }
.cine-lines p { font-family: var(--serif); font-size: clamp(17px, 2.2vw, 21px); line-height: 1.75; color: #d9d2bf; margin: 0 0 12px; }
.cine-lines .stamp { font-family: var(--type); color: var(--red); font-size: 15px; letter-spacing: .2em; margin: 0; }
.cine-lines .place { font-family: var(--type); color: var(--ink-3); font-size: 14px; }
.cine-lines .title { font-size: clamp(38px, 6vw, 64px); font-weight: 800; color: #fff; line-height: 1.05; margin: 10px 0 22px; }
.cine-lines .victim { border-left: 3px solid var(--red); padding-left: 14px; color: #f0e7d0; }
.cine-lines .role { margin-top: 20px; font-family: var(--sans); font-size: 16px; color: var(--amber); }
.cine-foot { margin-top: 26px; display: flex; justify-content: flex-end; }

/* Verdict */
.vt { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 15px; }
.vt th, .vt td { text-align: left; padding: 9px 8px; border-bottom: 1px solid rgba(43,36,24,.15); }
.vt td.ok { color: #2f7a45; font-weight: 700; }
.vt td.bad { color: var(--red); }
.verdict h3 { font-family: var(--serif); font-size: 22px; margin: 22px 0 4px; }
.verdict .where { font-family: var(--type); color: #6b5d42; font-size: 13px; }

@media (max-width: 1080px) { .modal-card .grid3 { grid-template-columns: 1fr; } .clock { grid-template-columns: auto 90px; } }
@media (max-width: 560px) { .code span { width: 58px; height: 74px; font-size: 42px; } .gtop { padding: 12px 16px; } }
@media (prefers-reduced-motion: reduce) { body::before, .waiting i, .banner.hot, .low .clock .now { animation: none; } }
