:root{
  --bg:#02060d;
  --bg-2:#061426;
  --panel:#07111f;
  --panel-soft:rgba(8,22,39,.72);
  --ink:#f4f8ff;
  --muted:#8aa0b8;
  --line:rgba(107,135,166,.18);
  --accent:#3b82f6;
  --warm:#ff8a3d;
  --gold:#ffd166;
  --shadow:none;
}

html[data-theme="light"]{
  --bg:#eef5fb;
  --bg-2:#e4f5f8;
  --panel:#ffffff;
  --panel-soft:rgba(15,23,42,.035);
  --ink:#071827;
  --muted:#4c647b;
  --line:rgba(15,44,70,.16);
  --accent:#2563eb;
  --warm:#f97316;
  --gold:#b45309;
  --shadow:none;
}

*{box-sizing:border-box}

html,
body{
  min-height:100%;
  margin:0;
}

html{
  background:var(--bg);
}

body{
  position:relative;
  isolation:isolate;
  background:
    linear-gradient(135deg, #02060d 0%, #061426 58%, #02060d 100%);
  color:var(--ink);
  font-family:Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

html[data-theme="light"] body{
  background:#f6f8fb;
}

html[data-theme="light"] body.page-app .header{
  background:rgba(255,255,255,.9);
  border-bottom-color:#e2e8f0;
  box-shadow:0 1px 0 rgba(15,23,42,.04), 0 12px 34px rgba(15,23,42,.06);
}

a{color:inherit}

.container{
  width:100%;
  margin:0 auto;
  padding:12px clamp(16px,3vw,34px);
}

.header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:22px;
  border-bottom:1px solid var(--line);
  background:rgba(2,6,13,.94);
}

html[data-theme="light"] body:not(.page-public) .header{
  background:rgba(255,255,255,.72);
}

.brand{
  display:inline-flex;
  align-items:center;
  min-width:0;
  text-decoration:none;
}

.brand-text{
  position:relative;
  display:grid;
  gap:4px;
  padding-left:14px;
}

.brand-text::before{
  content:"";
  position:absolute;
  left:0;
  top:2px;
  bottom:2px;
  width:4px;
  border-radius:999px;
  background:linear-gradient(180deg,#67e8f9,#38bdf8);
}

.brand-text strong{
  font-size:clamp(15px,1.35vw,18px);
  line-height:1.05;
  letter-spacing:0;
  font-weight:750;
}

.brand-text span{
  color:var(--muted);
  font-size:10px;
  font-weight:400;
  letter-spacing:.03em;
}

.header-actions{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
}

.language-select-wrap{
  position:relative;
  display:inline-flex;
  align-items:center;
  color:var(--ink);
}

.control-icon{
  position:absolute;
  left:13px;
  z-index:1;
  width:16px;
  height:16px;
  border:2px solid currentColor;
  border-radius:50%;
  opacity:.8;
  pointer-events:none;
}

.control-icon::before,
.control-icon::after{
  content:"";
  position:absolute;
  inset:3px -3px;
  border-top:1.5px solid currentColor;
  border-bottom:1.5px solid currentColor;
  border-radius:50%;
}

.control-icon::after{
  inset:-3px 5px;
  border:0;
  border-left:1.5px solid currentColor;
  border-right:1.5px solid currentColor;
}

.language-select-wrap::after{
  content:"";
  position:absolute;
  right:14px;
  top:50%;
  width:7px;
  height:7px;
  border-right:2px solid currentColor;
  border-bottom:2px solid currentColor;
  pointer-events:none;
  transform:translateY(-65%) rotate(45deg);
  opacity:.78;
}

.language-select,
.theme-toggle,
.login-button{
  min-height:42px;
  border:1px solid rgba(56,189,248,.22);
  border-radius:12px;
  background:linear-gradient(135deg, rgba(255,255,255,.07), rgba(255,255,255,.025));
  color:var(--ink);
  font:800 13px/1 Inter, ui-sans-serif, system-ui, sans-serif;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.08);
}

html[data-theme="light"] body:not(.page-public) .language-select,
html[data-theme="light"] body:not(.page-public) .theme-toggle{
  background:#fff;
  border-color:#dbe4ee;
  color:#172033;
  box-shadow:0 1px 2px rgba(15,23,42,.04);
}

.language-select{
  min-width:148px;
  padding:0 40px 0 38px;
  text-align:left;
  cursor:pointer;
}

.language-menu-list{
  position:absolute;
  left:0;
  top:calc(100% + 7px);
  z-index:40;
  width:100%;
  overflow:hidden;
  border:1px solid rgba(56,189,248,.32);
  border-radius:12px;
  background:#071827;
  box-shadow:0 18px 40px rgba(0,0,0,.34);
}

html[data-theme="light"] body:not(.page-public) .language-menu-list{
  background:#fff;
  box-shadow:0 16px 34px rgba(15,44,70,.16);
}

.language-menu-list[hidden]{
  display:none;
}

.language-menu-list a{
  display:flex;
  align-items:center;
  min-height:40px;
  padding:0 14px;
  color:var(--ink);
  font-size:14px;
  font-weight:750;
  text-decoration:none;
}

.language-menu-list a:hover,
.language-menu-list a.active{
  background:rgba(56,189,248,.14);
  color:#7dd3fc;
}

html[data-theme="light"] body:not(.page-public) .language-menu-list a:hover,
html[data-theme="light"] body:not(.page-public) .language-menu-list a.active{
  background:rgba(56,189,248,.12);
  color:#0369a1;
}

.theme-toggle{
  min-width:104px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:0 14px;
  cursor:pointer;
}

.theme-toggle-knob{
  width:18px;
  height:18px;
  border-radius:50%;
  background:linear-gradient(135deg,#f8fafc,#93c5fd);
  box-shadow:0 0 0 3px rgba(96,165,250,.12);
}

html[data-theme="light"] body:not(.page-public) .theme-toggle-knob{
  background:linear-gradient(135deg,#fbbf24,#f97316);
  box-shadow:0 0 0 3px rgba(249,115,22,.13);
}

.theme-toggle-label{
  display:inline-flex;
  align-items:center;
}

.header-account-link{
  max-width:min(280px,28vw);
  min-height:42px;
  display:inline-flex;
  align-items:center;
  padding:0 13px;
  overflow:hidden;
  border:1px solid rgba(56,189,248,.34);
  border-radius:12px;
  background:rgba(56,189,248,.08);
  color:var(--ink);
  font-size:13px;
  font-weight:750;
  text-decoration:none;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.header-account-link:hover{
  border-color:#38bdf8;
  background:rgba(56,189,248,.14);
}

.login-button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:90px;
  padding:0 16px;
  border-color:#38bdf8;
  background:linear-gradient(135deg,#0e7490,#38bdf8);
  color:#fff;
  box-shadow:0 0 18px rgba(56,189,248,.18);
  text-decoration:none;
  text-shadow:0 1px 1px rgba(0,0,0,.28);
}

html[data-theme="light"] body:not(.page-public) .login-button{
  border-color:#1d4ed8;
  background:#2563eb;
  color:#fff;
  box-shadow:0 8px 18px rgba(37,99,235,.18);
}

.language-select:hover,
.theme-toggle:hover,
.login-button:hover{
  border-color:color-mix(in srgb, var(--accent) 72%, var(--line));
}

.footer{
  display:grid;
  gap:28px;
  justify-content:center;
  color:var(--muted);
  font-size:13px;
  margin-top:64px;
  padding:32px 24px 24px;
  border-top:1px solid rgba(125,247,223,.14);
  background:
    linear-gradient(180deg, rgba(5,17,32,.72), rgba(3,11,22,.94)),
    radial-gradient(circle at 50% 0%, rgba(45,212,191,.08), transparent 32%);
}

.footer-grid{
  display:grid;
  grid-template-columns:repeat(5,1fr);
  gap:24px;
  max-width:1380px;
  justify-self:center;
  width:100%;
}

.footer-col{
  display:flex;
  flex-direction:column;
  gap:6px;
  text-align:left;
}

.footer-col-title{
  color:#d8f3ff;
  font-size:14px;
  font-weight:850;
  margin-bottom:4px;
}

.footer-col a{
  color:#8fb0c9;
  font-size:13px;
  font-weight:650;
  text-decoration:none;
  transition:color .15s ease, text-shadow .15s ease;
  width:fit-content;
}

.footer-col a:hover{
  color:#7df7df;
  text-decoration:none;
  text-shadow:0 0 18px rgba(125,247,223,.22);
}

.footer-col .footer-social-links{
  display:grid;
  grid-template-columns:36px 36px 36px;
  gap:6px;
  justify-content:start;
}

.footer-col .footer-social-links a{
  width:36px;
  height:36px;
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid rgba(45,212,191,.26);
  border-radius:999px;
  background:rgba(3,18,32,.52);
  color:#9fb9d0;
  text-decoration:none;
  transition:border-color .15s ease, background .15s ease, color .15s ease, transform .15s ease;
}

.footer-col .footer-social-links a:hover{
  border-color:rgba(45,212,191,.68);
  background:rgba(45,212,191,.14);
  color:#5eead4;
  transform:translateY(-1px);
}

.footer-col .footer-social-links a:nth-child(4){
  grid-column:1;
}

.footer-col .footer-social-links a:nth-child(5){
  grid-column:2;
}

.footer-col .footer-social-links svg{
  width:19px;
  height:19px;
  display:block;
  fill:currentColor;
}

@media(max-width:860px){
  .footer-grid{
    grid-template-columns:repeat(3,1fr);
  }
}

@media(max-width:520px){
  .footer-grid{
    grid-template-columns:1fr;
    text-align:center;
  }
  .footer-col{
    text-align:center;
    align-items:center;
  }
  .footer-col .footer-social-links{
    align-items:center;
  }
}

.footer p{
  width:100%;
  max-width:760px;
  margin:0;
  justify-self:center;
  text-align:center;
  line-height:1.6;
}

.footer-owner-link{
  color:#d8f3ff;
  font-weight:750;
  text-decoration:none;
}

.footer-owner-link:hover{
  color:#5eead4;
  text-decoration:underline;
  text-underline-offset:3px;
}

.footer-api-integrations{
  display:grid;
  justify-items:center;
  gap:12px;
  margin-bottom:20px;
  color:#8fb0c9;
  font-size:13px;
  font-weight:650;
}

.footer-api-integrations > div{
  display:flex;
  justify-content:center;
  gap:10px;
  flex-wrap:wrap;
}

.footer-brand-badge{
  width:126px;
  height:38px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:0;
  border:1px solid rgba(132,177,214,.18);
  border-radius:12px;
  background:rgba(3,18,32,.52);
  box-shadow:0 12px 26px rgba(0,0,0,.16);
  overflow:hidden;
}

.footer-brand-badge img{
  width:100%;
  height:100%;
  display:block;
  object-fit:contain;
}

.field{
  width:100%;
  min-height:42px;
  padding:0 12px;
  border:1px solid rgba(71,85,105,.2);
  border-radius:11px;
  background:rgba(4,17,29,.68);
  color:var(--ink);
  font:400 15px/1 Inter, ui-sans-serif, system-ui, sans-serif;
  transition:border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.creator-form select.field,
.dashboard-visibility-panel select.field{
  border-color:rgba(100,116,139,.36);
  background-color:#111827;
  color:#f8fafc;
  box-shadow:0 0 0 1px rgba(148,163,184,.04), 0 0 14px rgba(15,23,42,.14);
}

.creator-form select.field:hover,
.dashboard-visibility-panel select.field:hover,
.creator-form select.field:focus,
.dashboard-visibility-panel select.field:focus{
  border-color:#64748b;
  background-color:#1e293b;
  box-shadow:0 0 0 3px rgba(100,116,139,.16);
}

select.field{
  min-height:46px;
  padding:0 42px 0 14px;
  appearance:none;
  background-color:#0a1b2c;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-position:calc(100% - 14px) 50%;
  background-size:18px 18px;
  background-repeat:no-repeat;
  color:var(--ink);
  cursor:pointer;
  font-size:14px;
  font-weight:650;
  letter-spacing:0;
}

select.field:hover{
  border-color:#64748b;
  background-color:#0a1b2c;
}

select.field option{
  background:#071827;
  color:#f4f8ff;
  font:600 14px/1.4 Inter, ui-sans-serif, system-ui, sans-serif;
}

.field:focus{
  outline:none;
  border-color:#64748b;
  box-shadow:0 0 0 3px rgba(100,116,139,.16);
  background:rgba(4,17,29,.78);
}

html[data-theme="light"] .field{
  border-color:rgba(71,85,105,.2);
  background:#fff;
  box-shadow:inset 0 1px 0 rgba(15,23,42,.03);
}

html[data-theme="light"] select.field{
  background-color:#fff;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23334155' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-position:calc(100% - 14px) 50%;
  background-size:18px 18px;
  background-repeat:no-repeat;
  color:#071827;
}

select.field:focus{
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-position:calc(100% - 14px) 50%;
  background-size:18px 18px;
  background-repeat:no-repeat;
}

html[data-theme="light"] select.field:focus{
  background-color:#fff;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23334155' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-position:calc(100% - 14px) 50%;
  background-size:18px 18px;
  background-repeat:no-repeat;
}

html[data-theme="light"] select.field:hover{
  background-color:#f8fbfd;
  border-color:#64748b;
}

html[data-theme="light"] select.field option{
  background:#fff;
  color:#071827;
}

html[data-theme="light"] .creator-form select.field,
html[data-theme="light"] .dashboard-visibility-panel select.field{
  border-color:#475569;
  background-color:#334155;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23f8fafc' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-position:calc(100% - 14px) 50%;
  background-size:18px 18px;
  background-repeat:no-repeat;
  color:#fff;
  box-shadow:0 8px 18px rgba(15,23,42,.12);
}

html[data-theme="light"] .creator-form select.field:hover,
html[data-theme="light"] .dashboard-visibility-panel select.field:hover,
html[data-theme="light"] .creator-form select.field:focus,
html[data-theme="light"] .dashboard-visibility-panel select.field:focus{
  border-color:#64748b;
  background-color:#3f4f66;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23f8fafc' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-position:calc(100% - 14px) 50%;
  background-size:18px 18px;
  background-repeat:no-repeat;
  color:#fff;
  box-shadow:0 10px 22px rgba(15,23,42,.16);
}

.field::placeholder{
  color:color-mix(in srgb, var(--muted) 80%, transparent);
}

.check-label{
  display:flex !important;
  align-items:center;
  gap:9px;
  color:var(--muted) !important;
  font-size:14px;
}

.hero-kicker{
  display:inline-flex;
  align-items:center;
  min-height:34px;
  margin:0 0 20px;
  padding:0 12px;
  border:1px solid rgba(45,212,191,.32);
  border-radius:999px;
  background:rgba(45,212,191,.08);
  color:#5eead4;
  font-size:13px;
  font-weight:850;
  letter-spacing:.14em;
  text-transform:uppercase;
}

.dashboard-job-meta .youtube-upload-button,
.job-status-actions .youtube-upload-button,
.done-actions .youtube-upload-button{
  min-height:42px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:0 16px;
  border:1px solid rgba(255,0,0,.78);
  border-radius:11px;
  background:#ff0000;
  color:#fff;
  font:850 14px/1 Inter, ui-sans-serif, system-ui, sans-serif;
  text-decoration:none;
  cursor:pointer;
  box-shadow:0 0 20px rgba(255,0,0,.18), 0 10px 22px rgba(0,0,0,.14);
}

html[data-theme="light"] .dashboard-job-meta .youtube-upload-button,
html[data-theme="light"] .job-status-actions .youtube-upload-button,
html[data-theme="light"] .done-actions .youtube-upload-button{
  color:#fff;
  background:#ff0000;
  border-color:#ff0000;
}

.dashboard-job-meta .youtube-upload-button:hover,
.job-status-actions .youtube-upload-button:hover,
.done-actions .youtube-upload-button:hover{
  background:#cc0000;
  border-color:#cc0000;
}

.youtube-upload-state{
  min-height:42px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:0 16px;
  border:1px solid rgba(255,0,0,.22);
  border-radius:11px;
  background:rgba(255,0,0,.08);
  color:#ffb4b4;
  font:850 14px/1 Inter, ui-sans-serif, system-ui, sans-serif;
  text-decoration:none;
}

html[data-theme="light"] .youtube-upload-state{
  color:#991b1b;
  background:#fff1f2;
  border-color:rgba(255,0,0,.18);
}

.youtube-upload-state-uploaded{
  background:#ff0000;
  border-color:#ff0000;
  color:#fff;
  box-shadow:0 0 20px rgba(255,0,0,.18), 0 10px 22px rgba(0,0,0,.14);
}

.youtube-upload-state-uploaded:hover{
  background:#cc0000;
  border-color:#cc0000;
}

.secondary-action{
  justify-self:start;
  min-height:38px;
  padding:0 14px;
  border:1px solid rgba(71,85,105,.18);
  border-radius:10px;
  background:#071827;
  color:var(--ink);
  cursor:pointer;
  font:700 13px/1 Inter, ui-sans-serif, system-ui, sans-serif;
}

.secondary-action:hover{
  border-color:color-mix(in srgb, var(--accent) 72%, var(--line));
}

.secondary-action:disabled{
  cursor:not-allowed;
  opacity:.55;
}

.secondary-action.is-loading{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  opacity:.9;
  pointer-events:none;
}

.secondary-action.is-loading::after{
  content:"";
  width:15px;
  height:15px;
  flex:0 0 auto;
  border:2px solid rgba(255,255,255,.45);
  border-top-color:currentColor;
  border-radius:50%;
  animation:spin .7s linear infinite;
}

.file-field{
  display:flex;
  align-items:center;
  min-height:46px;
  padding:6px 10px 6px 6px;
  cursor:pointer;
  font-size:14px;
  font-weight:600;
}

.file-field::file-selector-button{
  min-height:34px;
  margin-right:12px;
  padding:0 14px;
  border:1px solid rgba(56,189,248,.45);
  border-radius:9px;
  background:rgba(56,189,248,.12);
  color:var(--ink);
  cursor:pointer;
  font:800 13px/1 Inter, ui-sans-serif, system-ui, sans-serif;
  transition:border-color .15s ease, background .15s ease, transform .15s ease;
}

.file-field:hover::file-selector-button{
  border-color:#38bdf8;
  background:rgba(56,189,248,.2);
  transform:translateY(-1px);
}

html[data-theme="light"] .file-field::file-selector-button{
  background:#e2f5f2;
  color:#071827;
}

.selected-images{
  display:flex;
  flex-wrap:wrap;
  gap:6px;
  margin-top:8px;
}

.selected-images[hidden]{
  display:none;
}

.selected-images span{
  display:inline-flex;
  align-items:center;
  gap:7px;
  max-width:100%;
  padding:5px 8px;
  border:1px solid var(--line);
  border-radius:8px;
  background:#071827;
  color:var(--ink);
  font-size:12px;
  line-height:1.25;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.selected-images-sort-help{
  margin-top:6px !important;
}

.field-help{
  margin:5px 0 0 !important;
  color:var(--muted) !important;
  font-size:12px !important;
}

html[data-theme="light"] .secondary-action,
html[data-theme="light"] .selected-images span{
  background:#fff;
}

.credit-estimate{
  justify-self:stretch;
  max-width:none;
  display:grid;
  grid-template-columns:1fr 1fr auto;
  gap:0;
  padding:0;
  border:1px solid rgba(71,85,105,.18);
  border-radius:14px;
  background:linear-gradient(135deg, rgba(4,17,29,.62), rgba(7,24,39,.42));
  box-shadow:0 12px 28px rgba(15,44,70,.07);
  overflow:hidden;
}

html[data-theme="light"] .credit-estimate{
  background:#fff;
}

.credit-estimate > div{
  display:grid;
  gap:2px;
  align-content:center;
  min-height:70px;
  padding:12px 14px;
}

.credit-estimate > div + div{
  border-left:1px solid var(--line);
}

.credit-estimate span{
  color:var(--muted);
  font-size:12px;
}

.credit-estimate strong{
  color:#38bdf8;
  font-size:18px;
  font-weight:800;
}

.credit-estimate strong.credit-warning{
  color:#ef4444;
}

.credit-available-row{
  display:flex;
  align-items:center;
  gap:12px;
  min-height:0;
  padding:0;
  flex-wrap:wrap;
}

.credit-topup-link{
  min-height:0;
  padding:0;
  border:0;
  background:transparent;
  color:#38bdf8;
  cursor:pointer;
  font:inherit;
  font-size:18px;
  font-weight:800;
  text-decoration:underline;
  text-underline-offset:3px;
  white-space:nowrap;
}

.credit-topup-link[hidden]{
  display:none;
}

.credit-topup-link:hover{
  color:#67e8f9;
}

.credit-submit-cell{
  min-width:190px;
  place-items:center;
}

.create-submit{
  justify-self:stretch;
  min-height:48px;
  width:100%;
  padding:0 20px;
  border:0;
  border-radius:12px;
  background:linear-gradient(135deg,#0e7490,#38bdf8);
  color:#fff;
  cursor:pointer;
  box-shadow:0 0 20px rgba(56,189,248,.2), 0 10px 22px rgba(0,0,0,.16);
  text-shadow:0 1px 1px rgba(0,0,0,.28);
  font:800 15px/1 Inter, ui-sans-serif, system-ui, sans-serif;
}

html[data-theme="light"] .create-submit{
  background:linear-gradient(135deg,#1d4ed8,#0284c7);
  box-shadow:0 10px 22px rgba(29,78,216,.16);
}

.create-submit:hover{
  filter:saturate(1.08) brightness(1.03);
  transform:translateY(-1px);
}

.create-submit:disabled{
  cursor:not-allowed;
  filter:saturate(.65);
  opacity:.42;
  transform:none;
  box-shadow:none;
}

.create-submit.is-loading:disabled{
  position:relative;
  opacity:.9;
  filter:none;
  background:linear-gradient(135deg,#0f766e,#0891b2);
  color:#fff;
  box-shadow:0 12px 28px rgba(8,145,178,.2);
}

.create-submit.is-loading:disabled::after{
  content:"";
  width:16px;
  height:16px;
  margin-left:10px;
  display:inline-block;
  vertical-align:-3px;
  border:2px solid rgba(255,255,255,.45);
  border-top-color:#fff;
  border-radius:50%;
  animation:spin .7s linear infinite;
}

@keyframes spin{
  to{
    transform:rotate(360deg);
  }
}

.create-submit.is-incomplete:disabled{
  background:linear-gradient(135deg,#475569,#64748b);
  text-shadow:none;
}

html[data-theme="light"] .create-submit.is-incomplete:disabled{
  background:linear-gradient(135deg,#94a3b8,#cbd5e1);
  color:#334155;
}

.job-status{
  display:grid;
  gap:5px;
  max-width:680px;
  margin-top:12px;
  padding:10px 12px;
  border:1px solid var(--line);
  border-radius:12px;
  background:var(--panel-soft);
}

.job-status.done{
  max-width:860px;
  grid-template-columns:1fr;
  align-items:start;
  gap:8px;
  padding:14px 16px;
  border-color:rgba(56,189,248,.58);
  background:linear-gradient(135deg, rgba(56,189,248,.16), rgba(96,165,250,.08));
  box-shadow:0 16px 34px rgba(56,189,248,.12);
}

.job-status span{
  color:var(--muted);
  font-size:13px;
}

.job-status.done span,
.job-status.done strong{
  grid-column:1;
}

.job-status strong{
  color:var(--ink);
  font-size:14px;
  font-weight:500;
}

.job-status.done strong{
  font-size:18px;
  font-weight:850;
}

.job-status a{
  justify-self:start;
  color:#38bdf8;
  text-decoration:none;
}

.job-status-actions{
  grid-column:1;
  grid-row:auto;
  align-self:start;
  justify-self:start;
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  justify-content:flex-start;
  margin-top:6px;
}

.job-status-actions a,
.job-status .job-status-download{
  display:inline-flex;
  align-items:center;
  min-height:42px;
  padding:0 16px;
  border-radius:10px;
  background:linear-gradient(135deg,#0e7490,#38bdf8);
  color:#fff;
  font-size:14px;
  font-weight:850;
  text-shadow:0 1px 1px rgba(0,0,0,.28);
  box-shadow:0 0 20px rgba(56,189,248,.18), 0 10px 22px rgba(0,0,0,.16);
}

.job-status-actions .job-new-video{
  border:1px solid rgba(56,189,248,.42);
  background:#102033;
  box-shadow:none;
}

.job-status.failed{
  border-color:rgba(255,102,122,.45);
}

.queue-modal{
  position:fixed;
  inset:0;
  z-index:80;
  display:grid;
  place-items:center;
  padding:24px;
  background:rgba(7,24,39,.52);
  backdrop-filter:blur(7px);
}

.queue-modal[hidden]{
  display:none;
}

.activity-consent-modal{position:fixed;z-index:120;right:0;bottom:0;left:0;padding:14px 24px;background:rgba(7,24,39,.94);border-top:1px solid rgba(56,189,248,.34);box-shadow:0 -12px 34px rgba(0,0,0,.2);animation:activity-consent-in .28s ease-out}
.activity-consent-card{width:min(1180px,100%);margin:0 auto;display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:28px;align-items:center;color:#fff}
.activity-consent-card .hero-kicker{grid-column:1;margin:0;color:#7dd3fc}.activity-consent-card h2{grid-column:1;margin:2px 0 5px;color:#fff;font-size:18px}.activity-consent-card p{grid-column:1;margin:0;color:#d6e5ef;line-height:1.45;font-size:13px}.activity-consent-card .activity-consent-note{margin-top:4px;font-size:12px;color:#aabfcc}.activity-consent-card>a{grid-column:1;color:#7dd3fc;text-decoration:none;font-size:12px;margin-top:5px}
.activity-consent-actions{grid-column:2;grid-row:1 / span 4;display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end;margin:0}.activity-consent-actions button{margin:0;min-height:40px;white-space:nowrap}
@media (max-width:720px){.activity-consent-modal{padding:14px 16px}.activity-consent-card{display:block}.activity-consent-actions{margin:14px 0 0;justify-content:flex-start}.activity-consent-actions button{flex:1}.activity-consent-card>a{display:inline-block;margin-top:9px}}
@keyframes activity-consent-in{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:translateY(0)}}
.account-activity-consent{display:flex;justify-content:space-between;gap:20px;align-items:center;padding:18px;border:1px solid rgba(56,189,248,.25);border-radius:14px;background:var(--panel-soft)}
.account-activity-consent strong,.account-activity-consent span{display:block}.account-activity-consent span{margin-top:4px;color:var(--muted);font-size:13px}
.youtube-upload-form-error{margin:0;padding:11px 13px;border:1px solid rgba(239,68,68,.42);border-radius:10px;background:rgba(239,68,68,.09);color:#b91c1c;font-size:13px;line-height:1.45}

.queue-dialog{
  position:relative;
  width:min(420px,100%);
  display:grid;
  grid-template-columns:44px minmax(0,1fr);
  gap:14px;
  align-items:center;
  padding:18px;
  border:1px solid rgba(56,189,248,.35);
  border-radius:14px;
  background:var(--panel);
  box-shadow:0 22px 70px rgba(0,0,0,.32);
}

.queue-dialog .done-close{
  display:grid;
  place-items:center;
  top:12px;
  right:12px;
  text-decoration:none;
}

.queue-spinner{
  width:38px;
  height:38px;
  border:4px solid rgba(56,189,248,.22);
  border-top-color:#38bdf8;
  border-radius:50%;
  animation:queue-spin .85s linear infinite;
}

.queue-dialog strong{
  display:block;
  color:var(--ink);
  font-size:17px;
  font-weight:700;
}

.queue-dialog p{
  margin:4px 0 0;
  color:var(--muted);
  font-size:14px;
  line-height:1.45;
}

.done-modal{
  position:fixed;
  inset:0;
  z-index:90;
  display:grid;
  place-items:center;
  padding:24px;
  background:rgba(7,24,39,.64);
  backdrop-filter:blur(7px);
}

.done-modal[hidden]{
  display:none;
}

.done-dialog{
  position:relative;
  width:min(680px,100%);
  display:grid;
  gap:14px;
  padding:18px;
  border:1px solid rgba(47,209,140,.45);
  border-radius:14px;
  background:var(--panel);
  box-shadow:0 22px 70px rgba(0,0,0,.34);
}

.done-dialog-short{
  width:min(420px,100%);
}

.billing-success-modal .done-dialog-short{
  width:min(560px,100%);
  gap:18px;
  padding:24px;
}

.billing-success-modal .done-head{
  grid-template-columns:58px minmax(0,1fr);
  gap:16px;
  padding-right:44px;
}

.billing-success-modal .done-check{
  width:54px;
  height:54px;
  font-size:32px;
  background:#22c55e;
  color:#052e16;
}

.billing-success-modal .done-head strong{
  font-size:24px;
}

.billing-success-modal .done-head p{
  margin-top:6px;
  font-size:17px;
  line-height:1.4;
}

.billing-success-note{
  margin:0;
  color:var(--muted);
  font-size:15px;
  line-height:1.55;
}

.billing-success-modal .done-download{
  justify-self:end;
}

.error-modal .done-dialog,
.error-dialog{
  border-color:rgba(248,113,113,.5);
}

.error-modal .done-dialog{
  padding:22px 26px 22px 22px;
}

.error-modal .done-close{
  top:22px;
  right:22px;
  width:44px;
  height:44px;
  border-color:rgba(248,113,113,.7);
  border-radius:14px;
  background:rgba(248,113,113,.08);
  color:#ef4444;
  font-size:26px;
  line-height:1;
  box-shadow:none;
}

.error-modal .done-close:hover{
  background:#ef4444;
  color:#fff;
}

.error-modal .done-head{
  grid-template-columns:50px minmax(0,1fr);
  gap:16px;
  align-items:start;
  padding-right:62px;
}

.error-dialog .done-head{
  padding-right:62px;
}

.error-modal .done-check,
.error-check{
  width:44px;
  height:44px;
  border:1px solid rgba(20,184,166,.7);
  border-radius:14px;
  background:rgba(20,184,166,.08);
  color:#0f766e;
  font-size:27px;
  box-shadow:none;
}

.error-modal .done-head strong{
  font-size:20px;
  line-height:1.2;
}

.error-modal .done-head p{
  font-size:16px;
  line-height:1.45;
}

.error-modal .error-technical{
  margin:4px 0 0;
  color:var(--text);
  line-height:1.45;
}

.error-modal .done-download,
.error-close{
  justify-self:center;
  min-width:116px;
  border:1px solid rgba(20,184,166,.55);
  background:#0e7490;
  color:#fff;
  box-shadow:none;
  text-shadow:none;
}

.done-dialog-wide{
  width:min(820px,100%);
}

.done-dialog-square{
  width:min(560px,100%);
}

.done-close{
  position:absolute;
  top:10px;
  right:10px;
  width:32px;
  height:32px;
  border:1px solid rgba(56,189,248,.72);
  border-radius:8px;
  background:rgba(56,189,248,.14);
  color:#38bdf8;
  cursor:pointer;
  font:850 21px/1 Inter, ui-sans-serif, system-ui, sans-serif;
}

.done-close:hover{
  background:#38bdf8;
  color:#071827;
}

.done-head{
  display:grid;
  grid-template-columns:46px minmax(0,1fr);
  gap:12px;
  align-items:center;
}

.done-check{
  width:42px;
  height:42px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:#38bdf8;
  color:#061827;
  font-size:25px;
  font-weight:800;
}

.done-head strong{
  display:block;
  color:var(--ink);
  font-size:18px;
  font-weight:750;
}

.done-head p{
  margin:4px 0 0;
  color:var(--muted);
  font-size:14px;
}

.done-video-frame{
  position:relative;
  width:100%;
  display:grid;
  place-items:center;
  overflow:hidden;
  border:1px solid var(--line);
  border-radius:10px;
  background:
    var(--done-poster, none) center center / contain no-repeat,
    #071827;
}

.done-video-frame.is-playing .done-video-poster{
  opacity:0;
  visibility:hidden;
}

.done-video-poster{
  position:absolute;
  z-index:2;
  top:0;
  right:0;
  bottom:58px;
  left:0;
  width:100%;
  height:calc(100% - 58px);
  object-fit:contain;
  background:#071827;
  pointer-events:none;
  transition:opacity .16s ease, visibility .16s ease;
}

.done-video{
  position:relative;
  z-index:1;
  width:100%;
  max-height:70vh;
  object-fit:contain;
  border:0;
  border-radius:0;
  background:transparent;
}

.done-video-short,
.done-video-frame-short{
  width:min(320px,100%);
  aspect-ratio:9/16;
  justify-self:center;
}

.done-video-wide,
.done-video-frame-wide{
  aspect-ratio:16/9;
}

.done-video-square,
.done-video-frame-square{
  aspect-ratio:1/1;
}

.done-dialog audio{
  width:100%;
}

.done-download{
  justify-self:start;
  min-height:38px;
  display:inline-grid;
  align-items:center;
  padding:0 13px;
  border-radius:9px;
  background:linear-gradient(135deg,#0e7490,#38bdf8);
  color:#fff;
  font-size:14px;
  font-weight:700;
  text-decoration:none;
  text-shadow:0 1px 1px rgba(0,0,0,.28);
}

.done-actions{
  display:flex;
  flex-wrap:wrap;
  justify-content:space-between;
  gap:12px;
}

.youtube-upload-modal{
  position:fixed;
  inset:0;
  z-index:95;
  display:grid;
  place-items:center;
  padding:24px;
  background:rgba(7,24,39,.64);
  backdrop-filter:blur(8px);
}

.youtube-upload-modal[hidden]{
  display:none;
}

.youtube-upload-dialog{
  position:relative;
  width:min(760px,100%);
  max-height:calc(100vh - 48px);
  overflow:auto;
  display:grid;
  gap:20px;
  padding:28px 30px 30px;
  border:1px solid rgba(56,189,248,.38);
  border-radius:18px;
  background:
    linear-gradient(180deg, rgba(56,189,248,.08), rgba(255,255,255,.02) 32%),
    var(--panel);
  box-shadow:0 24px 80px rgba(0,0,0,.36);
}

.youtube-upload-dialog .done-head{
  grid-template-columns:58px minmax(0,1fr);
  width:min(620px,100%);
  justify-self:center;
  align-items:center;
  gap:16px;
  padding-right:44px;
}

.youtube-upload-dialog .done-check{
  width:54px;
  height:54px;
  background:#ff0000;
  color:#fff;
  font-size:23px;
}

.youtube-upload-dialog .done-head strong{
  font-size:24px;
  line-height:1.2;
}

.youtube-upload-dialog .done-head p{
  max-width:560px;
  margin-top:7px;
  font-size:15px;
  line-height:1.45;
}

.youtube-metadata-grid{
  display:grid;
  gap:16px;
  padding:18px;
  border:1px solid rgba(56,189,248,.2);
  border-radius:16px;
  background:
    linear-gradient(135deg, rgba(56,189,248,.1), rgba(37,99,235,.05)),
    rgba(255,255,255,.035);
}

html[data-theme="light"] .youtube-metadata-grid{
  background:
    linear-gradient(135deg, rgba(224,242,254,.78), rgba(239,246,255,.56)),
    #f8fafc;
  border-color:rgba(14,116,144,.18);
}

.youtube-metadata-grid label{
  display:grid;
  gap:8px;
  color:var(--muted);
  font-size:13px;
  font-weight:800;
}

.youtube-metadata-grid .field{
  width:100%;
  border-color:rgba(148,163,184,.32);
  border-radius:13px;
  background:rgba(2,8,23,.32);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.04);
}

html[data-theme="light"] .youtube-metadata-grid .field{
  background:#fff;
  border-color:rgba(100,116,139,.26);
  box-shadow:0 1px 2px rgba(15,23,42,.04);
}

.youtube-metadata-grid textarea.field{
  min-height:178px;
  resize:vertical;
  line-height:1.55;
}

.youtube-metadata-row{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:13px;
}

.youtube-upload-actions{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto auto;
  align-items:center;
  gap:12px;
  padding-top:0;
}

.youtube-metadata-save-note{
  grid-column:1 / -1;
  margin:0;
  color:var(--muted);
  font-size:13px;
  line-height:1.4;
}

.youtube-upload-credit-rule{
  grid-column:1 / -1;
  margin:0;
  color:var(--text);
  font-size:13px;
  font-weight:800;
  line-height:1.4;
}

.youtube-upload-actions .secondary-action,
.youtube-upload-actions .create-submit{
  width:auto;
  min-width:160px;
  min-height:46px;
}

.youtube-upload-actions .secondary-action{
  grid-column:2;
}

.youtube-upload-actions .create-submit{
  grid-column:3;
}

.youtube-upload-actions .create-submit{
  min-width:210px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  text-decoration:none;
  border-color:#ff0000;
  background:#ff0000;
  color:#fff;
  box-shadow:0 12px 26px rgba(255,0,0,.2);
}

.youtube-upload-actions .create-submit:hover{
  background:#cc0000;
  border-color:#cc0000;
}

.youtube-upload-actions .create-submit:disabled{
  opacity:.48;
  cursor:not-allowed;
  box-shadow:none;
}

.youtube-upload-actions .secondary-action:disabled{
  opacity:.52;
  cursor:not-allowed;
}

.youtube-status-modal{
  z-index:100;
}

.youtube-status-dialog{
  width:min(540px,100%);
  gap:18px;
  padding:24px;
  border-color:rgba(56,189,248,.38);
}

.youtube-status-success .done-check{
  background:#22c55e;
  color:#052e16;
}

.youtube-status-error .done-check{
  background:#f97316;
  color:#431407;
}

.youtube-status-dialog .done-head{
  grid-template-columns:56px minmax(0,1fr);
  gap:16px;
  padding-right:44px;
}

.youtube-status-dialog .done-check{
  width:54px;
  height:54px;
  font-size:31px;
}

.youtube-status-dialog .done-head strong{
  font-size:24px;
  line-height:1.2;
}

.youtube-status-dialog .done-head p{
  margin-top:7px;
  font-size:16px;
  line-height:1.45;
}

.youtube-status-close{
  justify-self:end;
  border:0;
  cursor:pointer;
}

.purchase-modal{
  position:fixed;
  inset:0;
  z-index:90;
  display:grid;
  place-items:center;
  padding:24px;
  background:rgba(7,24,39,.62);
  backdrop-filter:blur(7px);
}

.purchase-modal[hidden]{
  display:none;
}

.purchase-dialog{
  position:relative;
  width:min(680px,100%);
  display:grid;
  gap:14px;
  padding:18px;
  border:1px solid rgba(56,189,248,.38);
  border-radius:14px;
  background:var(--panel);
  box-shadow:0 22px 70px rgba(0,0,0,.34);
}

.purchase-head{
  display:grid;
  gap:5px;
  padding-right:42px;
}

.purchase-head strong{
  color:var(--ink);
  font-size:20px;
  font-weight:850;
}

.purchase-head p{
  margin:0;
  color:var(--muted);
  font-size:14px;
  line-height:1.4;
}

.purchase-summary{
  display:grid;
  grid-template-columns:1fr 1fr;
  overflow:hidden;
  border:1px solid var(--line);
  border-radius:12px;
}

.purchase-summary div{
  display:grid;
  gap:3px;
  padding:12px;
}

.purchase-summary div + div{
  border-left:1px solid var(--line);
}

.purchase-summary span{
  color:var(--muted);
  font-size:12px;
}

.purchase-summary strong{
  color:#38bdf8;
  font-size:18px;
  font-weight:850;
}

.purchase-options{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
}

.purchase-options form{
  display:contents;
}

.purchase-options button,
.purchase-options a{
  min-height:86px;
  display:grid;
  align-content:center;
  gap:4px;
  padding:12px;
  border:1px solid var(--line);
  border-radius:12px;
  background:#071827;
  color:var(--ink);
  cursor:pointer;
  text-align:left;
  text-decoration:none;
}

html[data-theme="light"] .purchase-options button,
html[data-theme="light"] .purchase-options a{
  background:#fff;
}

.purchase-options button:hover,
.purchase-options a:hover{
  border-color:#38bdf8;
  background:rgba(56,189,248,.12);
}

.purchase-options button:disabled{
  cursor:not-allowed;
  opacity:.58;
}

.purchase-options strong{
  font-size:15px;
  font-weight:850;
}

.purchase-options span{
  color:var(--muted);
  font-size:12px;
  line-height:1.35;
}

.purchase-disabled-note{
  margin:10px 0 0;
  color:var(--muted);
  font-size:13px;
}

@keyframes queue-spin{
  to{
    transform:rotate(360deg);
  }
}

@media (max-width:760px){
  .header{
    align-items:flex-start;
    flex-direction:column;
  }

  .header-actions{
    width:100%;
    justify-content:flex-start;
    flex-wrap:wrap;
  }

  .credit-estimate{
    grid-template-columns:1fr;
    max-width:none;
  }

  .credit-estimate > div + div{
    margin-top:10px;
    padding-top:12px;
    border-top:1px solid var(--line);
    border-left:0;
  }

  .credit-submit-cell{
    min-width:0;
  }

  .job-status.done{
    grid-template-columns:1fr;
  }

  .job-status .job-status-download{
    grid-column:1;
    grid-row:auto;
    justify-self:start;
  }

  .purchase-summary,
  .purchase-options{
    grid-template-columns:1fr;
  }

  .youtube-metadata-row{
    grid-template-columns:1fr;
  }

  .youtube-upload-dialog{
    padding:22px 18px;
  }

  .youtube-upload-dialog .done-head{
    grid-template-columns:1fr;
    justify-items:center;
    text-align:center;
    padding-right:0;
  }

  .youtube-upload-actions{
    grid-template-columns:1fr;
  }

  .youtube-upload-actions .secondary-action,
  .youtube-upload-actions .create-submit{
    grid-column:1;
    width:100%;
  }

  .purchase-summary div + div{
    border-top:1px solid var(--line);
    border-left:0;
  }
}

@media (max-width:420px){
  .language-select,
  .theme-toggle,
  .header-account-link,
  .login-button{
    flex:1 1 auto;
    min-width:0;
  }

  .language-select-wrap{
    flex:1 1 130px;
  }

  .language-select{
    width:100%;
  }
}
