:root {
  color-scheme: dark;
  --bg: var(--tg-theme-bg-color, #0b0d12);
  --surface: var(--tg-theme-secondary-bg-color, #141821);
  --surface-2: #1a1f2a;
  --surface-3: #222936;
  --text: var(--tg-theme-text-color, #f7f7f4);
  --muted: var(--tg-theme-hint-color, #9198a8);
  --accent: var(--tg-theme-button-color, #ffcf68);
  --accent-text: var(--tg-theme-button-text-color, #19150b);
  --coral: #ff6f61;
  --green: #59d499;
  --blue: #69a9ff;
  --danger: #ff7185;
  --border: rgba(255, 255, 255, .09);
  --shadow: 0 18px 48px rgba(0, 0, 0, .28);
  --radius-lg: 26px;
  --radius-md: 18px;
  --radius-sm: 13px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: Inter, "SF Pro Display", "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background:
    radial-gradient(circle at 18% -5%, rgba(255, 207, 104, .11), transparent 35%),
    radial-gradient(circle at 105% 28%, rgba(255, 111, 97, .08), transparent 32%),
    var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

button, input, textarea, select { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }
a { color: var(--accent); }
body > main { width: min(100%, 720px); margin: 0 auto; padding: 28px 16px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; box-shadow: var(--shadow); }
.card h1 { margin-top: 0; font-size: clamp(28px, 8vw, 42px); letter-spacing: -.035em; }
.card h2 { margin: 24px 0 7px; font-size: 17px; }
.card p { color: #d4d7df; line-height: 1.6; }

.ambient {
  position: fixed;
  border-radius: 999px;
  filter: blur(80px);
  opacity: .12;
  pointer-events: none;
}
.ambient-one { width: 190px; height: 190px; background: var(--accent); top: -110px; left: -70px; }
.ambient-two { width: 170px; height: 170px; background: var(--coral); right: -110px; top: 38%; }

.app-shell {
  width: min(100%, 720px);
  min-height: 100dvh;
  margin: 0 auto;
  padding: 0 16px calc(102px + var(--safe-bottom));
  position: relative;
}

.topbar {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: max(10px, env(safe-area-inset-top)) 2px 8px;
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  background: transparent;
  border: 0;
  padding: 0;
  text-align: left;
  cursor: pointer;
}
.brand-lockup strong { display: block; font-size: 18px; line-height: 1; letter-spacing: .08em; }
.brand-lockup small { display: block; margin-top: 4px; color: var(--muted); font-size: 8px; letter-spacing: .25em; }
.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 207, 104, .35);
  border-radius: 13px;
  background: linear-gradient(145deg, rgba(255, 207, 104, .18), rgba(255, 111, 97, .08));
  box-shadow: inset 0 1px rgba(255, 255, 255, .08);
}
.brand-mark svg { width: 25px; fill: none; stroke: var(--accent); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.entertainment-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, .03);
  font-size: 11px;
  white-space: nowrap;
}
.entertainment-badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); }

.content { padding: 10px 0 24px; }
.page { animation: page-in .28s ease both; }
@keyframes page-in { from { opacity: 0; transform: translateY(7px); } }

.hero { padding: 18px 2px 22px; }
.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 9px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .11em;
  text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 18px; height: 1px; background: currentColor; }
.hero h1, .page-title {
  margin: 0;
  font-size: clamp(32px, 9vw, 52px);
  line-height: .98;
  letter-spacing: -.045em;
  text-wrap: balance;
}
.hero h1 em { color: var(--accent); font-style: normal; }
.hero > p { max-width: 520px; margin: 14px 0 0; color: var(--muted); font-size: 15px; line-height: 1.55; }

.panel {
  background: linear-gradient(160deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .018)), var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  box-shadow: var(--shadow);
}
.panel + .panel { margin-top: 12px; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.panel-head h2 { margin: 0; font-size: 20px; letter-spacing: -.02em; }
.panel-head p { margin: 5px 0 0; color: var(--muted); font-size: 13px; line-height: 1.45; }

.stepper { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 18px; }
.step {
  position: relative;
  min-height: 4px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .08);
  overflow: hidden;
}
.step.active::after, .step.done::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, var(--accent), var(--coral)); }
.step.active::after { animation: fill-step .35s ease both; }
@keyframes fill-step { from { transform: scaleX(.2); transform-origin: left; } }

.form-stack { display: grid; gap: 15px; }
.field { display: grid; gap: 7px; }
.field-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.field label, .field-label { font-size: 13px; font-weight: 750; color: #dfe2e8; }
.field-note, .counter { color: var(--muted); font-size: 11px; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

input, textarea, select {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, .11);
  border-radius: var(--radius-sm);
  outline: 0;
  background: rgba(5, 7, 11, .48);
  color: var(--text);
  padding: 13px 14px;
  transition: border-color .18s, box-shadow .18s, background .18s;
}
input { min-height: 50px; }
textarea { min-height: 150px; resize: vertical; line-height: 1.5; }
input::placeholder, textarea::placeholder { color: #6f7684; }
input:focus, textarea:focus, select:focus { border-color: rgba(255, 207, 104, .7); box-shadow: 0 0 0 3px rgba(255, 207, 104, .09); background: rgba(5, 7, 11, .7); }
.invalid { border-color: var(--danger) !important; box-shadow: 0 0 0 3px rgba(255, 113, 133, .09) !important; }

.presets { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: -2px 0 2px; padding: 2px 0; }
.presets::-webkit-scrollbar { display: none; }
.preset {
  flex: 0 0 auto;
  padding: 8px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  color: #c7cbd4;
  font-size: 12px;
  cursor: pointer;
}
.preset:active { transform: scale(.97); }

.daily-case {
  width: 100%; display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 13px;
  margin: 0 0 14px; padding: 14px; border: 1px solid rgba(255, 207, 104, .2);
  border-radius: var(--radius-md); background: linear-gradient(120deg, rgba(255, 207, 104, .09), rgba(255, 111, 97, .05)), var(--surface);
  color: var(--text); text-align: left; cursor: pointer; box-shadow: 0 12px 30px rgba(0, 0, 0, .15);
}
.daily-case:active { transform: scale(.99); }
.daily-case-icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 16px; background: rgba(255, 255, 255, .06); font-size: 23px; }
.daily-case span:last-child { min-width: 0; display: grid; gap: 3px; }
.daily-case small { color: var(--accent); font-size: 9px; font-weight: 900; letter-spacing: .11em; }
.daily-case b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.daily-case i { color: var(--muted); font-size: 10px; }

.style-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.style-option { position: relative; }
.style-option input { position: absolute; opacity: 0; pointer-events: none; }
.style-option span {
  min-height: 78px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: rgba(255, 255, 255, .025);
  cursor: pointer;
  transition: .18s ease;
}
.style-option b { font-size: 13px; }
.style-option small { color: var(--muted); font-size: 10px; line-height: 1.3; }
.style-option input:checked + span { border-color: rgba(255, 207, 104, .62); background: rgba(255, 207, 104, .09); box-shadow: inset 0 0 0 1px rgba(255, 207, 104, .1); }

.switch-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: rgba(255, 255, 255, .025);
  cursor: pointer;
}
.switch-copy b { display: block; font-size: 13px; }
.switch-copy small { display: block; margin-top: 5px; color: var(--muted); font-size: 11px; line-height: 1.4; }
.switch { position: relative; flex: 0 0 auto; width: 43px; height: 25px; }
.switch input { position: absolute; opacity: 0; }
.switch i { position: absolute; inset: 0; border-radius: 99px; background: #343a47; transition: .2s; }
.switch i::after { content: ""; position: absolute; width: 19px; height: 19px; left: 3px; top: 3px; border-radius: 50%; background: white; transition: .2s; box-shadow: 0 2px 5px rgba(0, 0, 0, .25); }
.switch input:checked + i { background: var(--accent); }
.switch input:checked + i::after { transform: translateX(18px); background: var(--accent-text); }

.actions { display: flex; gap: 9px; margin-top: 2px; }
.btn {
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 0;
  border-radius: 15px;
  padding: 12px 16px;
  background: linear-gradient(135deg, var(--accent), #ffb85f);
  color: var(--accent-text);
  font-weight: 850;
  cursor: pointer;
  box-shadow: 0 9px 24px rgba(255, 190, 80, .14);
  transition: transform .14s, filter .14s, opacity .14s;
}
.btn:active { transform: scale(.98); }
.btn:hover { filter: brightness(1.04); }
.btn:disabled { opacity: .55; cursor: wait; }
.btn.secondary { background: var(--surface-3); color: var(--text); box-shadow: none; border: 1px solid var(--border); }
.btn.ghost { background: transparent; color: var(--muted); box-shadow: none; border: 1px solid var(--border); }
.btn.danger { background: rgba(255, 113, 133, .12); color: var(--danger); border: 1px solid rgba(255, 113, 133, .22); box-shadow: none; }
.btn.block { width: 100%; }
.btn.compact { min-height: 42px; padding: 9px 12px; font-size: 13px; }
.data-management { width: 100%; margin-top: 22px; padding: 9px; border: 0; background: transparent; color: var(--muted); font-size: 11px; text-decoration: underline; cursor: pointer; }
.btn-icon { font-size: 17px; }
.spin { width: 17px; height: 17px; border: 2px solid rgba(0, 0, 0, .2); border-top-color: currentColor; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.legal { margin: 13px 4px 0; color: var(--muted); font-size: 10px; line-height: 1.5; text-align: center; }
.legal a { color: inherit; }

.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; padding: 20px 2px 18px; }
.page-heading .page-title { font-size: clamp(30px, 8vw, 44px); }
.page-heading p { margin: 8px 0 0; color: var(--muted); font-size: 13px; }
.count-badge { min-width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid var(--border); border-radius: 13px; background: var(--surface); color: var(--accent); font-weight: 850; }

.case-list { display: grid; gap: 10px; }
.case-card {
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: linear-gradient(145deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, .015)), var(--surface);
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: transform .15s, border-color .15s;
}
.case-card:active { transform: scale(.985); }
.case-card:hover { border-color: rgba(255, 207, 104, .25); }
.case-icon { width: 43px; height: 43px; display: grid; place-items: center; border-radius: 14px; background: var(--surface-3); font-size: 19px; }
.case-copy { min-width: 0; }
.case-copy b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.case-copy span { display: block; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 11px; }
.case-arrow { color: var(--muted); font-size: 20px; }
.case-meta { display: flex; align-items: center; gap: 7px; margin-top: 7px; }
.status-chip, .role-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .06);
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.status-chip.waiting { background: rgba(105, 169, 255, .1); color: var(--blue); }
.status-chip.ready, .status-chip.generating { background: rgba(255, 207, 104, .1); color: var(--accent); }
.status-chip.verdict { background: rgba(89, 212, 153, .1); color: var(--green); }

.case-header { padding: 18px; overflow: hidden; position: relative; }
.case-header::after { content: "⚖"; position: absolute; right: -15px; bottom: -45px; color: rgba(255, 255, 255, .025); font-size: 150px; transform: rotate(-10deg); pointer-events: none; }
.case-number { color: var(--muted); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; }
.case-header h1 { max-width: 560px; margin: 10px 0 12px; font-size: clamp(27px, 7vw, 39px); line-height: 1.05; letter-spacing: -.035em; position: relative; z-index: 1; }
.case-header-meta { display: flex; flex-wrap: wrap; gap: 7px; position: relative; z-index: 1; }

.case-progress { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; margin: 14px 0; }
.progress-item { text-align: center; color: #666e7d; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.progress-item i { display: block; height: 3px; margin-bottom: 7px; border-radius: 10px; background: #2c3240; }
.progress-item.done { color: var(--green); }
.progress-item.active { color: var(--accent); }
.progress-item.done i { background: var(--green); }
.progress-item.active i { background: var(--accent); box-shadow: 0 0 12px rgba(255, 207, 104, .4); }

.statement { padding: 16px; border: 1px solid var(--border); border-radius: var(--radius-md); background: rgba(255, 255, 255, .022); }
.statement + .statement { margin-top: 9px; }
.statement-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 9px; }
.statement-side { display: flex; align-items: center; gap: 8px; }
.avatar { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 10px; background: rgba(105, 169, 255, .13); color: var(--blue); font-size: 12px; font-weight: 900; }
.avatar.defendant { background: rgba(255, 111, 97, .12); color: var(--coral); }
.statement h3 { margin: 0; font-size: 13px; }
.statement small { color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .08em; }
.statement p { margin: 0; color: #d8dbe2; font-size: 14px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }

.callout { margin-top: 12px; padding: 15px; border-radius: var(--radius-md); border: 1px solid rgba(255, 207, 104, .18); background: linear-gradient(135deg, rgba(255, 207, 104, .09), rgba(255, 111, 97, .045)); }
.callout h3 { margin: 0 0 6px; font-size: 16px; }
.callout p { margin: 0 0 13px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.defense-callout { border-color: rgba(105, 169, 255, .24); background: linear-gradient(135deg, rgba(105, 169, 255, .09), rgba(255, 207, 104, .04)); }
.defense-presets { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.defense-presets button { min-height: 49px; display: flex; align-items: center; gap: 8px; padding: 9px 10px; border: 1px solid var(--border); border-radius: 13px; background: rgba(0, 0, 0, .16); color: #d9dce3; text-align: left; font-size: 11px; cursor: pointer; }
.defense-presets button span { font-size: 16px; }
.defense-presets button.active { border-color: rgba(105, 169, 255, .5); background: rgba(105, 169, 255, .1); color: white; }
.consent-row { border-color: rgba(89, 212, 153, .18); }

.verdict-hero { text-align: center; padding: 22px 14px 18px; }
.verdict-seal { width: 66px; height: 66px; display: grid; place-items: center; margin: 0 auto 12px; border: 1px solid rgba(255, 207, 104, .35); border-radius: 22px; background: rgba(255, 207, 104, .1); font-size: 30px; box-shadow: 0 0 36px rgba(255, 207, 104, .09); }
.verdict-hero .eyebrow { justify-content: center; }
.verdict-hero .eyebrow::before { display: none; }
.verdict-hero h2 { margin: 0 auto; max-width: 540px; font-size: clamp(29px, 8vw, 43px); line-height: 1.02; letter-spacing: -.04em; }

.scoreboard { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: 14px 0; }
.score { padding: 15px; border: 1px solid var(--border); border-radius: var(--radius-md); background: rgba(255, 255, 255, .025); }
.score.winner { border-color: rgba(255, 207, 104, .35); background: rgba(255, 207, 104, .07); }
.score-label { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 11px; }
.score strong { display: block; margin: 5px 0 9px; font-size: 28px; line-height: 1; }
.score-track { height: 4px; border-radius: 10px; background: #292f3b; overflow: hidden; }
.score-track i { display: block; height: 100%; border-radius: inherit; background: var(--blue); }
.score:last-child .score-track i { background: var(--coral); }

.section-title { display: flex; align-items: center; gap: 9px; margin: 20px 2px 10px; font-size: 16px; }
.section-title span { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 9px; background: var(--surface-3); font-size: 13px; }
.reason-list { display: grid; gap: 8px; counter-reset: reasons; }
.reason { counter-increment: reasons; display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: start; padding: 13px; border: 1px solid var(--border); border-radius: 15px; background: rgba(255, 255, 255, .022); color: #d9dce3; font-size: 13px; line-height: 1.5; }
.reason::before { content: counter(reasons); width: 23px; height: 23px; display: grid; place-items: center; border-radius: 8px; background: rgba(255, 207, 104, .11); color: var(--accent); font-size: 10px; font-weight: 900; }
.decisive-evidence { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: center; margin-top: 9px; padding: 15px; border: 1px solid rgba(255, 111, 97, .2); border-radius: var(--radius-md); background: linear-gradient(135deg, rgba(255, 111, 97, .1), rgba(255, 207, 104, .04)); }
.decisive-evidence > span { width: 39px; height: 39px; display: grid; place-items: center; border-radius: 13px; background: rgba(255, 111, 97, .12); font-size: 20px; }
.decisive-evidence div { display: grid; gap: 5px; }
.decisive-evidence small { color: var(--coral); font-size: 8px; font-weight: 900; letter-spacing: .1em; }
.decisive-evidence b { font-size: 12px; line-height: 1.45; }
.sentence { padding: 17px; border: 1px solid rgba(255, 207, 104, .2); border-radius: var(--radius-md); background: linear-gradient(135deg, rgba(255, 207, 104, .09), rgba(255, 111, 97, .05)); font-size: 16px; line-height: 1.5; font-weight: 700; }
.roast { margin-top: 8px; padding: 13px 15px; border-radius: 15px; background: rgba(255, 111, 97, .08); color: #ffd5cf; font-size: 13px; line-height: 1.5; }

.share-studio {
  position: relative;
  margin: 18px 0 12px;
  padding: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 207, 104, .24);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 100% 0, rgba(255, 111, 97, .14), transparent 38%),
    radial-gradient(circle at 0 100%, rgba(105, 169, 255, .09), transparent 38%),
    var(--surface);
  box-shadow: var(--shadow);
}
.share-studio::after { content: "#"; position: absolute; right: -10px; top: -35px; color: rgba(255, 255, 255, .025); font-size: 180px; font-weight: 900; pointer-events: none; }
.share-kicker { position: relative; z-index: 1; color: var(--coral); font-size: 10px; font-weight: 900; letter-spacing: .1em; }
.share-studio h3 { position: relative; z-index: 1; margin: 7px 0 6px; font-size: 24px; letter-spacing: -.025em; }
.share-studio > p { position: relative; z-index: 1; margin: 0 0 15px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.format-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 15px; padding: 5px; border: 1px solid var(--border); border-radius: 15px; background: rgba(0, 0, 0, .18); }
.format-switch button { min-height: 43px; border: 0; border-radius: 11px; background: transparent; color: var(--muted); font-size: 12px; font-weight: 850; cursor: pointer; }
.format-switch button small { display: block; margin-top: 2px; font-size: 8px; font-weight: 600; }
.format-switch button.active { background: var(--surface-3); color: var(--accent); box-shadow: 0 4px 15px rgba(0, 0, 0, .18); }
.share-preview { position: relative; width: min(58vw, 265px); margin: 0 auto 15px; overflow: hidden; border: 1px solid rgba(255, 255, 255, .13); border-radius: 22px; background: #0a0c12; box-shadow: 0 18px 38px rgba(0, 0, 0, .4); transition: aspect-ratio .2s ease; }
.share-preview.story { aspect-ratio: 9 / 16; }
.share-preview.post { aspect-ratio: 4 / 5; }
.share-preview img { width: 100%; height: 100%; display: block; object-fit: cover; opacity: 0; transition: opacity .25s; }
.share-preview img.ready { opacity: 1; }
.preview-loader { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 8px; color: var(--muted); }
.preview-loader.hidden { display: none; }
.preview-loader small { font-size: 9px; }
.share-primary { margin-bottom: 8px; background: linear-gradient(135deg, #ffdc7a, #ff846d); }
.share-tools { display: grid; grid-template-columns: repeat(2, 1fr); gap: 7px; }
.share-tools .btn { min-width: 0; white-space: normal; line-height: 1.25; }
.share-tools .btn:last-child:nth-child(3) { grid-column: 1 / -1; }
.privacy-note { margin: 12px 3px 0 !important; text-align: center; font-size: 9px !important; }

.jury-box { margin-top: 14px; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius-md); background: var(--surface); }
.jury-box h3 { margin: 0; font-size: 16px; }
.jury-box p { margin: 5px 0 13px; color: var(--muted); font-size: 11px; }
.jury-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.jury-head > span { flex: 0 0 auto; padding: 6px 8px; border-radius: 999px; background: rgba(255, 207, 104, .09); color: var(--accent); font-size: 9px; font-weight: 900; }
.jury-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.jury-vote { min-width: 0; padding: 12px 8px; border: 1px solid var(--border); border-radius: 13px; background: var(--surface-3); color: var(--text); cursor: pointer; }
.jury-vote span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.jury-vote strong { display: block; margin-top: 4px; font-size: 18px; }
.jury-quest { position: relative; display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; margin-top: 12px; padding: 12px; border-radius: 13px; background: rgba(0, 0, 0, .17); }
.jury-quest div { display: grid; gap: 3px; }
.jury-quest b { font-size: 11px; }
.jury-quest small { color: var(--muted); font-size: 9px; }
.jury-quest > span { color: var(--accent); font-size: 11px; font-weight: 900; }
.jury-quest > i { grid-column: 1 / -1; height: 4px; overflow: hidden; border-radius: 99px; background: #2a303c; }
.jury-quest > i em { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--blue), var(--accent)); transition: width .3s ease; }

.after-verdict-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.case-safety-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 14px; padding: 13px 0 2px; }
.case-safety-actions button { border: 0; background: transparent; color: #697180; font-size: 9px; text-decoration: underline; cursor: pointer; }
.case-safety-actions button:disabled { opacity: .65; cursor: default; }

.feed-sort { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: -5px 0 13px; padding: 5px; border: 1px solid var(--border); border-radius: 15px; background: rgba(0, 0, 0, .15); }
.feed-sort button { min-height: 42px; border: 0; border-radius: 11px; background: transparent; color: var(--muted); font-size: 11px; font-weight: 850; cursor: pointer; }
.feed-sort button.active { background: var(--surface-3); color: var(--text); }

.report-reasons { display: grid; gap: 7px; margin-bottom: 12px; }
.report-reasons button { min-height: 44px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 13px; background: var(--surface-3); color: var(--text); text-align: left; cursor: pointer; }

.courtroom-reveal { position: fixed; z-index: 120; inset: 0; display: grid; place-content: center; justify-items: center; padding: 28px; overflow: hidden; background: radial-gradient(circle at 50% 38%, #282219 0, #11141b 38%, #07090e 80%); text-align: center; }
.reveal-rays { position: absolute; width: 680px; height: 680px; border-radius: 50%; background: repeating-conic-gradient(from 0deg, rgba(255, 209, 102, .035) 0 8deg, transparent 8deg 18deg); animation: reveal-spin 18s linear infinite; }
.reveal-seal { position: relative; width: 88px; height: 88px; display: grid; place-items: center; margin-bottom: 20px; border: 1px solid rgba(255, 209, 102, .35); border-radius: 30px; background: rgba(255, 209, 102, .1); box-shadow: 0 0 70px rgba(255, 209, 102, .12); font-size: 39px; animation: reveal-pulse 1.3s ease-in-out infinite; }
.courtroom-reveal small, .courtroom-reveal h2, .courtroom-reveal p, .reveal-dots { position: relative; }
.courtroom-reveal small { color: var(--accent); font-size: 10px; font-weight: 900; letter-spacing: .2em; }
.courtroom-reveal h2 { max-width: 520px; margin: 11px 0 0; font-size: clamp(29px, 9vw, 48px); line-height: 1.02; letter-spacing: -.035em; }
.courtroom-reveal p { max-width: 460px; margin: 12px 0 0; color: #c4c8d0; font-size: 14px; line-height: 1.5; }
.reveal-dots { display: flex; gap: 7px; margin-top: 22px; }
.reveal-dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); animation: reveal-dot 1s ease-in-out infinite; }
.reveal-dots i:nth-child(2) { animation-delay: .16s; }
.reveal-dots i:nth-child(3) { animation-delay: .32s; }
.courtroom-reveal.final .reveal-seal { animation: verdict-hit .45s cubic-bezier(.2, .9, .2, 1.25) both; }
@keyframes reveal-spin { to { transform: rotate(360deg); } }
@keyframes reveal-pulse { 50% { transform: translateY(-5px) scale(1.03); } }
@keyframes reveal-dot { 50% { transform: translateY(-5px); opacity: .35; } }
@keyframes verdict-hit { from { transform: scale(2.2) rotate(-14deg); opacity: 0; } to { transform: scale(1) rotate(0); opacity: 1; } }

.empty { text-align: center; padding: 35px 22px; border: 1px dashed rgba(255, 255, 255, .13); border-radius: var(--radius-lg); background: rgba(255, 255, 255, .018); }
.empty-icon { width: 58px; height: 58px; display: grid; place-items: center; margin: 0 auto 13px; border-radius: 20px; background: var(--surface-3); font-size: 27px; }
.empty h2 { margin: 0; font-size: 20px; }
.empty p { max-width: 390px; margin: 8px auto 17px; color: var(--muted); font-size: 13px; line-height: 1.55; }

.loading-screen { min-height: 62vh; display: grid; place-content: center; justify-items: center; color: var(--muted); }
.loader-seal { width: 68px; height: 68px; display: grid; place-items: center; border: 1px solid var(--border); border-radius: 23px; background: var(--surface); font-size: 28px; animation: seal-pulse 1.4s ease-in-out infinite; }
.loading-screen p { font-size: 12px; }
@keyframes seal-pulse { 50% { transform: translateY(-5px); box-shadow: 0 12px 30px rgba(255, 207, 104, .1); } }
.skeleton { min-height: 78px; border-radius: var(--radius-md); background: linear-gradient(100deg, var(--surface) 30%, var(--surface-2) 50%, var(--surface) 70%); background-size: 300% 100%; animation: shimmer 1.3s infinite; }
.skeleton + .skeleton { margin-top: 10px; }
@keyframes shimmer { to { background-position: -150% 0; } }

.tabbar {
  position: fixed;
  z-index: 20;
  left: 50%;
  bottom: max(10px, var(--safe-bottom));
  transform: translateX(-50%);
  width: min(calc(100% - 24px), 696px);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
  padding: 6px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 22px;
  background: rgba(18, 22, 30, .92);
  box-shadow: 0 15px 44px rgba(0, 0, 0, .42);
  backdrop-filter: blur(18px);
}
.tab { min-height: 54px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 0; border-radius: 16px; background: transparent; color: #747c8b; font-size: 9px; font-weight: 750; cursor: pointer; }
.tab svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tab.active { color: var(--accent); background: rgba(255, 207, 104, .08); }

.toast {
  position: fixed;
  z-index: 80;
  left: 50%;
  bottom: calc(92px + var(--safe-bottom));
  width: max-content;
  max-width: calc(100% - 32px);
  transform: translate(-50%, 18px);
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: #242a35;
  color: white;
  box-shadow: var(--shadow);
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transition: .22s ease;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.error { border-color: rgba(255, 113, 133, .35); }

.modal-backdrop { position: fixed; z-index: 90; inset: 0; display: grid; align-items: end; padding: 16px; background: rgba(0, 0, 0, .62); backdrop-filter: blur(6px); animation: fade .2s ease; }
.modal { width: min(100%, 520px); margin: 0 auto max(0px, var(--safe-bottom)); padding: 20px; border: 1px solid var(--border); border-radius: 25px; background: var(--surface); box-shadow: var(--shadow); animation: modal-up .25s ease; }
.modal h2 { margin: 0; font-size: 22px; }
.modal p { margin: 9px 0 18px; color: var(--muted); font-size: 13px; line-height: 1.55; }
@keyframes fade { from { opacity: 0; } }
@keyframes modal-up { from { transform: translateY(18px); opacity: 0; } }

@media (max-width: 430px) {
  .app-shell { padding-left: 12px; padding-right: 12px; }
  .panel { padding: 15px; }
  .split { grid-template-columns: 1fr; }
  .entertainment-badge { font-size: 9px; padding: 6px 8px; }
  .score strong { font-size: 25px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}
