:root {
  color-scheme: light;
  --ink: #17221d;
  --muted: #718078;
  --line: #e2e9e4;
  --surface: #ffffff;
  --canvas: #f4f8f5;
  --green: #18845b;
  --green-dark: #0f6845;
  --green-soft: #e5f4eb;
  --gold: #f8c15c;
  --shadow: 0 18px 54px rgba(24, 59, 41, .07);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--canvas); color: var(--ink); }
button, input { font: inherit; }
button { cursor: pointer; }
a { color: inherit; }
[hidden] { display: none !important; }
.topbar { height: 76px; padding: 0 clamp(20px, 5vw, 72px); display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(223, 233, 226, .8); background: rgba(255,255,255,.82); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: #1a2a21; font-size: 19px; font-weight: 760; letter-spacing: -.045em; text-decoration: none; }
.brand img { object-fit: contain; }
.brand-light { color: var(--green); font-weight: 560; }
.privacy-pill { display: inline-flex; align-items: center; gap: 8px; border: 1px solid #dbece2; padding: 8px 12px; border-radius: 99px; color: #426151; background: #f7fcf8; font-size: 12px; font-weight: 650; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #35aa6f; box-shadow: 0 0 0 3px #e3f5e9; }
.page-shell { width: min(1160px, calc(100% - 40px)); margin: 0 auto; padding: 46px 0 34px; }
.hero { position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr); gap: 44px; align-items: center; padding: 48px clamp(24px, 5vw, 64px); border-radius: 28px; background: linear-gradient(115deg, #e6f3e9 0%, #edf7ef 48%, #f5f8ef 100%); box-shadow: var(--shadow); }
.hero::after { content: ""; position: absolute; width: 340px; height: 340px; right: 34%; bottom: -250px; border-radius: 50%; border: 1px solid rgba(24,132,91,.11); box-shadow: 0 0 0 35px rgba(24,132,91,.025), 0 0 0 70px rgba(24,132,91,.025); pointer-events: none; }
.hero-copy, .auth-card { position: relative; z-index: 1; }
.eyebrow { display: inline-block; color: #42805e; font-size: 10px; font-weight: 800; letter-spacing: .16em; }
.hero h1 { margin: 15px 0 14px; color: #17271e; font-size: clamp(38px, 5vw, 57px); font-weight: 710; letter-spacing: -.065em; line-height: 1.04; }
.hero h1 span { color: var(--green); }
.hero-copy p { max-width: 510px; margin: 0; color: #607168; font-size: 15px; line-height: 1.75; }
.auth-card { padding: 24px; border: 1px solid rgba(226,233,228,.9); border-radius: 18px; background: rgba(255,255,255,.92); box-shadow: 0 10px 35px rgba(43,81,58,.075); }
.auth-card-heading { display: flex; align-items: center; gap: 13px; margin-bottom: 21px; }
.auth-icon { width: 39px; height: 39px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 12px; background: #f2f7f3; color: #4285f4; font-size: 20px; font-weight: 800; }
.auth-card h2 { margin: 0 0 4px; font-size: 15px; letter-spacing: -.02em; }
.auth-card-heading p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; border: 0; border-radius: 10px; padding: 0 16px; font-size: 13px; font-weight: 700; transition: transform .15s ease, background .15s ease, box-shadow .15s ease; }
.button:hover { transform: translateY(-1px); }
.button:focus-visible, input:focus-visible, summary:focus-visible { outline: 3px solid rgba(24,132,91,.25); outline-offset: 2px; }
.button-primary { width: 100%; color: #fff; background: var(--green); box-shadow: 0 7px 14px rgba(24,132,91,.17); }
.button-primary:hover { background: var(--green-dark); }
.button-secondary { color: #236246; background: #e8f4ec; }
.button-secondary:hover { background: #d8ecdf; }
.button-quiet { color: #53675c; background: #f0f4f1; }
.button-quiet:hover { background: #e7eee9; }
.button-small { min-height: 35px; padding: 0 12px; font-size: 11px; }
.status-message { min-height: 18px; margin: 13px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.status-message[data-kind="success"] { color: #167149; }
.status-message[data-kind="error"] { color: #ad423a; }
.setup-card { margin-top: 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); box-shadow: 0 7px 24px rgba(34,74,50,.035); }
.setup-card details { padding: 0 22px; }
.setup-card summary { display: flex; align-items: center; gap: 10px; min-height: 58px; color: #34493d; font-size: 13px; font-weight: 720; cursor: pointer; list-style: none; }
.setup-card summary::-webkit-details-marker { display: none; }
.summary-icon { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 8px; color: #357b56; background: var(--green-soft); font-size: 13px; }
.summary-note { margin-left: auto; color: #84948b; font-size: 10px; font-weight: 550; }
.setup-content { padding: 0 0 21px 34px; color: #607168; font-size: 12px; line-height: 1.65; }
.setup-content > p:first-child { max-width: 850px; margin: 0 0 17px; }
.client-form label { display: block; margin-bottom: 7px; color: #34493d; font-size: 11px; font-weight: 700; }
.input-row { display: flex; gap: 9px; }
.input-row input { flex: 1; min-width: 0; height: 42px; border: 1px solid #dce6df; border-radius: 9px; padding: 0 12px; color: var(--ink); background: #fbfdfb; font-size: 12px; }
.input-row input::placeholder { color: #a2afa7; }
.help-text { margin: 7px 0 0; color: #7c8c82; font-size: 10px; line-height: 1.6; }
code { overflow-wrap: anywhere; color: #386b4d; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .96em; }
.setup-steps { display: grid; gap: 5px; margin: 16px 0; padding-left: 18px; }
.setup-steps li { padding-left: 3px; }
.notice { margin: 14px 0 0; padding: 10px 12px; border-left: 3px solid #80bd92; border-radius: 0 8px 8px 0; background: #f4faf5; color: #53675a; font-size: 11px; }
.content-grid { display: grid; grid-template-columns: minmax(290px, .77fr) minmax(0, 1.23fr); gap: 18px; margin-top: 22px; align-items: stretch; }
.panel { min-width: 0; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); box-shadow: 0 8px 28px rgba(34,74,50,.04); }
.library-panel { padding: 22px 19px 17px; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; margin: 0 0 17px; }
.panel-heading h2, .player-heading h2 { margin: 4px 0 0; color: #1d2a22; font-size: 20px; letter-spacing: -.04em; }
.count-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 29px; height: 25px; padding: 0 8px; border-radius: 99px; color: #4c725b; background: #edf6ef; font-size: 10px; font-weight: 750; }
.search-form { position: relative; display: flex; align-items: center; gap: 7px; }
.search-form input { width: 100%; min-width: 0; height: 39px; border: 1px solid #e3eae5; border-radius: 9px; padding: 0 9px 0 33px; background: #fbfdfb; font-size: 11px; }
.search-icon { position: absolute; left: 11px; z-index: 1; color: #8b9c91; font-size: 22px; line-height: 1; transform: rotate(-20deg); }
.search-form button { height: 39px; border: 0; border-radius: 9px; padding: 0 13px; color: #fff; background: #344f3e; font-size: 11px; font-weight: 700; }
.files-list { display: grid; gap: 7px; min-height: 227px; max-height: 420px; overflow: auto; margin-top: 14px; padding-right: 2px; }
.file-card { display: flex; align-items: center; gap: 11px; width: 100%; padding: 10px 9px; border: 1px solid transparent; border-radius: 11px; color: inherit; text-align: left; background: transparent; transition: border .15s ease, background .15s ease; }
.file-card:hover { border-color: #e4eee6; background: #f8fbf8; }
.file-card.is-active { border-color: #c9e5d2; background: #f0f8f2; }
.file-icon { display: grid; place-items: center; flex: 0 0 auto; width: 37px; height: 37px; border-radius: 10px; color: #35805a; background: #eaf5ed; font-size: 13px; }
.file-copy { min-width: 0; flex: 1; }
.file-name { overflow: hidden; display: block; color: #283a2e; font-size: 11px; font-weight: 680; text-overflow: ellipsis; white-space: nowrap; }
.file-detail { display: block; margin-top: 4px; color: #829087; font-size: 9px; }
.file-arrow { color: #9aaa9f; font-size: 15px; }
.empty-state { min-height: 210px; display: flex; flex-direction: column; justify-content: center; align-items: center; color: #8b9a91; text-align: center; }
.empty-symbol { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid #e6eee8; border-radius: 13px; color: #65a27b; background: #f7fbf8; font-size: 14px; }
.empty-state p { max-width: 220px; margin: 10px auto 0; font-size: 11px; line-height: 1.55; }
.load-more { width: 100%; margin-top: 12px; font-size: 11px; }
.player-panel { padding: 22px; }
.player-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; min-height: 56px; margin-bottom: 17px; }
.player-heading-copy { min-width: 0; }
.player-heading h2 { max-width: 520px; overflow-wrap: anywhere; font-size: 18px; }
.player-heading p { margin: 5px 0 0; color: #87948c; font-size: 10px; }
.text-link { flex: 0 0 auto; padding-top: 14px; color: #348157; font-size: 10px; font-weight: 700; text-decoration: none; }
.text-link:hover { text-decoration: underline; }
.video-frame { position: relative; overflow: hidden; display: grid; place-items: center; aspect-ratio: 16 / 9; min-height: 180px; border-radius: 13px; background: #15231b; }
.video-frame video { display: block; width: 100%; height: 100%; max-height: 480px; background: #101914; object-fit: contain; }
.video-placeholder { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #a8b8ad; pointer-events: none; }
.video-placeholder p { margin: 12px 0 0; font-size: 11px; }
.play-orb { display: grid; place-items: center; width: 50px; height: 50px; border: 1px solid rgba(200,231,210,.28); border-radius: 50%; color: #cfebd7; background: rgba(93,155,112,.16); font-size: 16px; padding-left: 3px; }
.embed-panel { margin-top: 18px; padding: 14px; border: 1px solid #e6eee8; border-radius: 12px; background: #fbfdfb; }
.embed-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.embed-head h3 { margin: 4px 0 0; font-size: 13px; letter-spacing: -.02em; }
.embed-url { width: 100%; height: 34px; border: 1px solid #e1eae3; border-radius: 8px; padding: 0 9px; color: #567363; background: white; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 9px; }
.embed-snippet { overflow: auto; max-height: 75px; margin: 8px 0 0; padding: 9px; border-radius: 8px; color: #52675a; background: #f1f6f2; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 9px; }
.embed-panel .help-text { margin-top: 8px; }
.bottom-note { display: flex; align-items: flex-start; gap: 11px; margin-top: 18px; padding: 13px 16px; border: 1px solid #e5ece7; border-radius: 12px; background: #f9fbf9; }
.note-icon { display: grid; place-items: center; flex: 0 0 auto; width: 19px; height: 19px; border-radius: 50%; color: #548165; background: #e5f2e8; font-size: 11px; font-weight: 800; }
.bottom-note p { margin: 0; color: #74837a; font-size: 10px; line-height: 1.6; }
.bottom-note strong { color: #4b6253; }
.footer { display: flex; justify-content: space-between; width: min(1160px, calc(100% - 40px)); margin: 0 auto; padding: 0 0 24px; color: #8c9b92; font-size: 10px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
body.embed-mode .page-shell { width: min(100%, 950px); padding: 18px; }
body.embed-mode .topbar { height: 54px; padding: 0 18px; }
body.embed-mode .privacy-pill, body.embed-mode .hero-copy, body.embed-mode .library-panel, body.embed-mode .bottom-note, body.embed-mode .footer { display: none !important; }
body.embed-mode .hero { display: block; padding: 0; background: transparent; box-shadow: none; }
body.embed-mode .hero::after { display: none; }
body.embed-mode .auth-card { max-width: 450px; margin: 0 auto 14px; }
body.embed-mode .content-grid { display: block; margin-top: 0; }
body.embed-mode .player-panel { padding: 15px; }
body.embed-mode .player-heading { min-height: auto; margin-bottom: 11px; }
body.embed-mode #setupCard { margin: 0 0 14px; }
body.embed-mode .setup-card details { padding: 0 14px; }
body.embed-mode .setup-content { padding-left: 0; }
body.embed-mode .embed-panel { display: none !important; }
@media (max-width: 840px) {
  .hero { grid-template-columns: 1fr; gap: 27px; padding: 35px 28px; }
  .hero-copy p { max-width: 680px; }
  .auth-card { max-width: 520px; }
  .content-grid { grid-template-columns: 1fr; }
  .files-list { max-height: 340px; }
}
@media (max-width: 560px) {
  .topbar { height: 64px; padding: 0 17px; }
  .brand { font-size: 17px; }
  .brand img { width: 35px; height: 33px; }
  .privacy-pill { padding: 7px 9px; font-size: 10px; }
  .page-shell { width: calc(100% - 24px); padding-top: 19px; }
  .hero { padding: 29px 19px 21px; border-radius: 20px; }
  .hero h1 { font-size: 39px; }
  .hero-copy p { font-size: 13px; }
  .auth-card { padding: 18px; }
  .setup-card details { padding: 0 14px; }
  .setup-card summary { min-height: 52px; font-size: 11px; }
  .summary-note { display: none; }
  .setup-content { padding-left: 0; font-size: 11px; }
  .input-row { align-items: stretch; flex-direction: column; }
  .input-row .button { width: 100%; }
  .library-panel, .player-panel { padding: 17px 14px; }
  .panel-heading h2, .player-heading h2 { font-size: 17px; }
  .player-heading { gap: 6px; }
  .text-link { font-size: 9px; }
  .video-frame { min-height: 155px; }
  .footer { width: calc(100% - 24px); font-size: 9px; }
  body.embed-mode .page-shell { padding: 10px; }
}
