/* DDC Recordings. Builds on the DDC design system (tokens.css, liquid-glass.css). */

[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { min-height: 100vh; -webkit-font-smoothing: antialiased; }
h1 { font-size: 30px; font-weight: 750; letter-spacing: -0.6px; line-height: 1.15; margin: 4px 0 6px; color: var(--heading); }
h2 { font-size: 17px; font-weight: 720; margin: 0; color: var(--heading); }
p { margin: 0; }
a { color: var(--accent); }
.hint { font-size: 12.5px; color: var(--muted); }
.form-error { font-size: 13.5px; font-weight: 600; color: var(--danger); }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.notice { background: var(--warning-bg); color: var(--warning-text); border-radius: 14px; padding: 12px 16px; margin-bottom: 16px; font-size: 13.5px; }
.brand-rule { margin-top: 12px; }

/* ---- Sign in ---- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.login-card { width: min(400px, 100%); border-radius: var(--radius-dialog); padding: 34px 30px 26px; display: flex; flex-direction: column; align-items: flex-start; }
.login-card > * { position: relative; z-index: 3; }
.login-mark { margin-bottom: 18px; }
.login-copy { margin: 16px 0 22px; color: var(--copy); }
.btn--google { width: 100%; min-height: 46px; gap: 10px; }
.login-card .btn--link { align-self: center; margin-top: 10px; font-size: 13px; font-weight: 600; }
.login-form { width: 100%; margin-top: 6px; }
.login-form .btn { width: 100%; }
.login-card .form-error { margin-top: 12px; }

/* ---- App frame ---- */
.side { position: fixed; z-index: 20; left: 12px; top: 12px; bottom: 12px; width: 264px; border-radius: 26px; padding: 18px 14px 14px; display: flex; flex-direction: column; gap: 14px; }
.side > * { position: relative; z-index: 3; }
.logo { display: flex; align-items: center; gap: 10px; padding: 4px 6px; color: #fff; font-size: 18px; font-weight: 750; letter-spacing: -0.3px; text-decoration: none; }
.side-new { width: 100%; min-height: 42px; }
.side-label { font-size: 11.5px; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; color: rgb(211 222 243 / 0.6); padding: 6px 10px 0; }
.tabs { position: relative; display: flex; flex-direction: column; gap: 4px; }
.tabs button { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 42px; padding: 8px 12px; border: none; border-radius: 14px; background: transparent; color: #d3def3; font: inherit; font-weight: 620; text-align: left; cursor: pointer; transition: color 0.2s; }
.tabs button:hover, .tabs button.active { color: #fff; }
.tabs button svg { flex: none; }
.tabs:not(:has(> .lens:not([hidden]))) button.active { background: linear-gradient(180deg, rgb(76 120 240 / 0.78), rgb(40 81 197 / 0.74)); }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 6px; padding-top: 12px; border-top: 1px solid rgb(255 255 255 / 0.1); }
.side-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 2px 4px 2px 10px; min-height: 40px; font-weight: 600; }
.side-me { font-size: 12.5px; font-weight: 500; color: rgb(211 222 243 / 0.75); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side .icon-btn { color: #d3def3; }
.side .icon-btn:hover { color: #fff; background: rgb(255 255 255 / 0.12); }
.side .toggle:not(:checked) { background: rgb(255 255 255 / 0.16); }

.content { margin-left: 288px; padding: 34px 28px 80px; max-width: 980px; }
.page-head { margin-bottom: 22px; }

/* ---- Upload ---- */
.card { margin-bottom: 16px; }
.drop { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; padding: 36px 20px; border: 2px dashed var(--control); cursor: pointer; transition: border-color 0.15s, background 0.15s; }
.drop:hover, .drop.over { border-color: var(--primary); background: var(--soft); }
.drop-icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 14px; background: var(--soft); color: var(--primary); margin-bottom: 8px; }
html[data-theme='dark'] .drop-icon { color: var(--accent); }
.drop-title { font-size: 17px; font-weight: 720; color: var(--heading); }
.job { display: flex; flex-direction: column; gap: 14px; }
.job .field { margin: 0; }
.options { display: flex; flex-direction: column; gap: 10px; }
.option { display: flex; align-items: center; gap: 12px; font-weight: 600; color: var(--heading); cursor: pointer; }
.option .hint { font-weight: 400; }
.bar { height: 8px; border-radius: 999px; background: var(--g-recess); overflow: hidden; margin-bottom: 8px; }
#bar-fill { height: 100%; width: 0; border-radius: 999px; background: linear-gradient(90deg, var(--primary), var(--cyan)); transition: width 0.25s; }
#done { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.link-row { width: 100%; flex-wrap: nowrap; }
.link-row .input { min-width: 0; }

/* ---- Recorder ---- */
.side-upload { color: #fff; background: rgb(255 255 255 / 0.1); box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.14); margin-top: -6px; }
.side-upload:hover { background: rgb(255 255 255 / 0.18); }
select.input { appearance: auto; }
.meter-row { display: flex; align-items: center; gap: 10px; margin-top: -4px; }
.meter { flex: 1; max-width: 240px; margin: 0; }
#rec-meter { height: 100%; width: 0; border-radius: 999px; background: linear-gradient(90deg, var(--primary), var(--cyan)); transition: width 0.08s linear; }
.rec-status { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--heading); }
.rec-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--muted); }
.rec-dot.on { background: #e5484d; animation: rec-pulse 1.2s ease-in-out infinite; }
.rec-time { margin-left: auto; font-variant-numeric: tabular-nums; font-size: 20px; }
.rec-preview { width: 100%; max-height: 300px; border-radius: 14px; background: #000; object-fit: contain; }
.job .danger { color: var(--danger); }
@keyframes rec-pulse { 50% { opacity: 0.35; } }

/* ---- Video list ---- */
.videos { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.video { display: flex; align-items: center; gap: 14px; padding: 14px 18px; margin: 0; }
.video .info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.video .name { font-size: 16px; font-weight: 700; color: var(--heading); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.video .name:hover { text-decoration: underline; }
.video .meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.video .acts { display: flex; gap: 6px; flex-shrink: 0; align-items: center; }
.video .btn { min-height: 34px; padding: 5px 13px; font-size: 13.5px; }
.video .btn--link.danger { color: var(--danger); }
.stat { display: inline-flex; align-items: center; gap: 4px; }
.empty { text-align: center; color: var(--muted); padding: 34px 20px; }

.toast { z-index: 50; font-weight: 650; }
.toast > * { position: relative; z-index: 3; }

/* ---- Phones ---- */
@media (max-width: 820px) {
  .content { margin-left: 0; padding: 82px 14px 110px; }
  .side { left: 0; right: 0; top: 0; bottom: auto; width: auto; border-radius: 0 0 22px 22px; padding: 10px 12px 12px; gap: 10px; flex-direction: row; flex-wrap: wrap; align-items: center; }
  .logo { flex: 1; font-size: 16px; }
  .side-upload, .side-label, .side-me, .side-foot label { display: none; }
  #record { width: auto; min-height: 36px; padding: 6px 14px; }
  .side-foot { margin: 0; padding: 0; border: none; }
  .side-row { padding: 0; min-height: 0; }
  .tabs { order: 3; flex: 1 0 100%; flex-direction: row; gap: 2px; padding: 3px; border-radius: 16px; background: rgb(0 0 0 / 0.22); }
  .tabs button { justify-content: center; min-height: 36px; padding: 6px 8px; font-size: 13px; border-radius: 13px; }
  .tabs button svg { display: none; }
  .content { padding-top: 142px; }
  h1 { font-size: 25px; }
  .card { border-radius: 20px; padding: 16px; }
  .video { flex-direction: column; align-items: stretch; gap: 10px; }
  .video .acts { flex-wrap: wrap; }
  .input { font-size: 16px; }
}

/* ---- Share page ---- */
.watch-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 1100px; margin: 0 auto; padding: 16px 20px 0; }
.watch-brand { display: flex; align-items: center; gap: 10px; color: var(--heading); font-weight: 750; font-size: 16px; letter-spacing: -0.2px; text-decoration: none; }
.watch-bar { flex-wrap: wrap; }
.watch-tools .btn { min-height: 36px; padding: 6px 14px; font-size: 13.5px; }
.watch-tools .danger { color: var(--danger); }
.watch-brand small { display: block; font-size: 11.5px; font-weight: 600; letter-spacing: 0; color: var(--muted); }
.watch-main { max-width: 1100px; margin: 0 auto; padding: 16px 20px 72px; }
.player { background: #000; border-radius: var(--radius-card); overflow: hidden; aspect-ratio: 16 / 9; display: flex; box-shadow: 0 2px 6px rgb(14 26 50 / 0.08), 0 30px 70px -24px rgb(14 26 50 / 0.45); }
.player video { width: 100%; height: 100%; display: block; background: #000; }
.under { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.speed-label { font-size: 12.5px; font-weight: 700; color: var(--muted); margin-right: 2px; }
.watch-info { margin-top: 22px; }
.watch-info h1 { overflow-wrap: anywhere; }
.watch-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 8px; color: var(--muted); font-size: 13px; }
.watch-meta .avatar { width: 30px; height: 30px; font-size: 12px; }
.watch-meta strong { color: var(--heading); font-weight: 700; }
.like.active { color: #fff; background: linear-gradient(180deg, #4471e6, #2a54c9 62%, #2549b8); box-shadow: 0 0 0 0.5px rgb(18 38 105 / 0.6), 0 8px 20px -6px rgb(40 81 197 / 0.55), inset 0 1px 0.5px rgb(255 255 255 / 0.5), inset 0 -8px 14px -10px rgb(125 208 220 / 0.75); }
.comments { margin-top: 26px; display: grid; gap: 16px; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: start; }
.comments .card { margin: 0; }
.comment-list { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.comment { display: flex; gap: 12px; }
.comment .body { flex: 1; min-width: 0; }
.comment .who { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.comment .who strong { color: var(--heading); font-weight: 700; }
.comment .text { white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 2px; }
.comment .btn--link { min-height: 0; padding: 0; font-size: 12.5px; color: var(--danger); }
.comment-form { display: flex; flex-direction: column; gap: 2px; }
.comment-form h2 { margin-bottom: 14px; }
.comment-form textarea { resize: vertical; min-height: 96px; }
.comment-form .option { font-size: 13.5px; margin-bottom: 14px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.watch-foot { text-align: center; padding: 0 20px 36px; }
.watch-empty { text-align: center; padding: 16vh 0; }
.watch-empty p { color: var(--muted); max-width: 420px; margin: 0 auto; }
@media (max-width: 820px) {
  .comments { grid-template-columns: 1fr; }
  .player { border-radius: 16px; }
  .watch-main { padding: 12px 12px 60px; }
  .watch-bar { padding: 12px 14px 0; }
}
