:root{
  --paper:#f5f1e8;
  --paper2:#fbf7ef;
  --ink:#0c0c0d;
  --ink2:rgba(12,12,13,.72);
  --ink3:rgba(12,12,13,.55);

  --gold:#d4af37;
  --yellow:#ffd54a;
  --green:#16a34a;
  --black:#0b0b0c;

  --border:rgba(12,12,13,.10);
  --border2:rgba(12,12,13,.14);
  --shadow:0 18px 42px rgba(0,0,0,.18);
  --radius:18px;
  --radius2:16px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  background:
    radial-gradient(900px 520px at 8% 0%, rgba(255,213,74,.55), transparent 58%),
    radial-gradient(900px 520px at 92% 6%, rgba(212,175,55,.35), transparent 60%),
    radial-gradient(1100px 620px at 50% 120%, rgba(22,163,74,.12), transparent 55%),
    linear-gradient(180deg, var(--paper2), var(--paper));
  color:var(--ink);
  font-family:var(--font);
}

/* Dark theme */
[data-theme="dark"] body{
  background:
    radial-gradient(900px 520px at 8% 0%, rgba(255,213,74,.16), transparent 58%),
    radial-gradient(900px 520px at 92% 6%, rgba(22,163,74,.12), transparent 60%),
    linear-gradient(180deg, #0b0c0d, #101214);
  color: rgba(255,255,255,.92);
}
[data-theme="dark"] .panel{
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.03));
  border-color: rgba(255,255,255,.10);
  box-shadow: 0 18px 42px rgba(0,0,0,.44);
}
[data-theme="dark"] .panel__head{
  background: linear-gradient(90deg, rgba(255,213,74,.16), rgba(255,255,255,.04) 38%, rgba(22,163,74,.10));
  border-bottom-color: rgba(255,255,255,.10);
}
[data-theme="dark"] .panel__meta{color: rgba(255,255,255,.55);}
[data-theme="dark"] .header__sub{color: rgba(255,255,255,.66);}
[data-theme="dark"] .header__sub strong{color: rgba(255,255,255,.92);}
[data-theme="dark"] .menu__link{
  color: rgba(255,255,255,.88);
  border-color: rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
}
[data-theme="dark"] .menu__link:hover{background: rgba(255,255,255,.06);}
[data-theme="dark"] .badge{background: rgba(255,255,255,.06); color: rgba(255,255,255,.78); border-color: rgba(255,255,255,.12);}
[data-theme="dark"] .uploader__label{background: rgba(255,255,255,.03); border-color: rgba(255,255,255,.16);}
[data-theme="dark"] .uploader__label:hover{background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.22);}
[data-theme="dark"] .preview{background: rgba(255,255,255,.03); border-color: rgba(255,255,255,.10);}
[data-theme="dark"] .btn{color: rgba(12,12,13,.92);}
[data-theme="dark"] .btn--ghost{background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.12); color: rgba(255,255,255,.88);}
[data-theme="dark"] .toggle{background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.12); color: rgba(255,255,255,.84);}
[data-theme="dark"] select{background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.12); color: rgba(255,255,255,.88);}
[data-theme="dark"] #outCanvas{background: #0b0c0d; border-color: rgba(255,255,255,.10);}
[data-theme="dark"] .footer{color: rgba(255,255,255,.55);}

.app{max-width:1280px; margin:0 auto; padding:22px 16px 16px;}

.header{
  display:flex; flex-direction:column; gap:8px;
  margin-bottom:18px;
}
h1{font-size:20px; margin:0; letter-spacing:-.02em}
.topbar{
  display:flex;
  justify-content:space-between;
  gap:14px;
  align-items:center;
}
.brand{
  display:flex;
  align-items:center;
  gap:12px;
  min-width: 0;
}
.brand__logo{
  width:46px;
  height:46px;
  border-radius:14px;
  border:1px solid var(--border);
  background: rgba(255,255,255,.9);
  object-fit: cover;
}
.brand__text{display:flex; flex-direction:column; gap:4px; min-width:0;}
.brand__text h1{white-space:nowrap; overflow:hidden; text-overflow:ellipsis;}
.menu{
  display:flex;
  gap:10px;
  align-items:center;
  flex-wrap:wrap;
  justify-content:flex-end;
}
.menu__link{
  text-decoration:none;
  color: rgba(12,12,13,.86);
  border:1px solid rgba(12,12,13,.14);
  background: rgba(255,255,255,.88);
  padding:10px 12px;
  border-radius:12px;
  font-size:12px;
  font-weight:700;
}
.menu__link:hover{background: rgba(255,255,255,.95);}
.badge{
  display:inline-flex; align-items:center;
  padding:4px 10px; border-radius:999px;
  border:1px solid var(--border);
  background:rgba(255,255,255,.82);
  color:rgba(12,12,13,.78);
  font-size:12px;
}
.header__sub{color:var(--ink2); font-size:13px;}
.header__sub strong{color:rgba(12,12,13,.92)}
.sep{margin:0 6px; color: var(--ink3);}

.showcase{
  border:1px solid var(--border);
  border-radius:var(--radius);
  background: linear-gradient(180deg, rgba(255,255,255,.82), rgba(255,255,255,.68));
  box-shadow: var(--shadow);
  overflow:hidden;
}
.showcase--hero{
  margin-bottom:14px;
  padding:16px 16px 14px;
}
.hero__lead{margin-bottom:14px;}
.showcase__eyebrow{
  margin:0 0 4px;
  font-size:11px;
  font-weight:700;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:var(--ink3);
}
.showcase__eyebrow--spaced{margin-top:14px;}
.showcase__title{
  margin:0 0 6px;
  font-size:18px;
  font-weight:800;
  font-family: Montserrat, var(--font);
  letter-spacing:-.02em;
}
.showcase__title--hero{
  font-size:clamp(1.15rem, 2.6vw, 1.45rem);
  line-height:1.25;
  max-width:36ch;
}
.showcase__sub{
  margin:0 0 14px;
  font-size:13px;
  color:var(--ink2);
  max-width:52ch;
}
.showcase__sub--hero{
  max-width:72ch;
  line-height:1.55;
}
.showcase__sub--hero strong{font-weight:700; color: rgba(12,12,13,.92);}
.hero__ctaRow{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:10px 16px;
  margin-bottom:2px;
}
.heroCta{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:11px 18px;
  border-radius:12px;
  border:1px solid rgba(12,12,13,.14);
  background:linear-gradient(180deg, rgba(255,213,74,.78), rgba(212,175,55,.58));
  color:rgba(12,12,13,.94);
  font-weight:800;
  font-size:13px;
  text-decoration:none;
  font-family: Montserrat, var(--font);
  transition: transform .12s ease, border-color .12s ease, filter .12s ease;
}
.heroCta:hover{
  filter:brightness(1.03);
  border-color:rgba(12,12,13,.22);
  transform: translateY(-1px);
}
.heroCta:focus-visible{
  outline:2px solid var(--green);
  outline-offset:2px;
}
.heroCta__meta{
  font-size:12px;
  color:var(--ink2);
}
.heroCta__meta a{color:inherit; font-weight:600;}
.heroCta__meta a:hover{color: var(--green);}
.heroCta__sep{margin:0 6px; color:var(--ink3);}

.heroLocal{
  display:grid;
  grid-template-columns: repeat(2, 1fr);
  gap:10px;
  margin-bottom:12px;
}
.heroLocal__card{
  padding:12px 12px 11px;
  border-radius:var(--radius2);
  border:1px solid var(--border2);
  background: rgba(255,255,255,.45);
}
.heroLocal__title{
  margin:0 0 8px;
  font-size:12px;
  font-weight:800;
  font-family: Montserrat, var(--font);
  letter-spacing:-.01em;
  color: rgba(12,12,13,.88);
}
.heroLocal__body{
  margin:0;
  font-size:12px;
  line-height:1.5;
  color:var(--ink2);
}
.heroLocal__break{display:block; margin-top:8px;}
.heroLocal__disclaim{font-style:normal; color:var(--ink3); font-size:11px;}
.heroLocal__list{
  margin:0;
  padding-left:1.1em;
  font-size:12px;
  line-height:1.45;
  color:var(--ink2);
}
.heroLocal__list li{margin-bottom:6px;}
.heroLocal__list li:last-child{margin-bottom:0;}
.heroLocal__list a{font-weight:600; color:inherit;}
.heroLocal__list a:hover{color: var(--green);}

.heroMicro{
  margin:0 0 10px;
  font-size:12px;
  line-height:1.5;
  font-style:italic;
  color:var(--ink3);
  max-width:68ch;
  padding:10px 12px;
  border-left:3px solid rgba(212,175,55,.65);
  background: rgba(255,255,255,.35);
  border-radius:0 var(--radius2) var(--radius2) 0;
}
.heroTrustLine{margin:0 0 12px; max-width:68ch;}

.heroRefs{
  margin:0 0 14px;
  border-radius:var(--radius2);
  border:1px dashed rgba(12,12,13,.18);
  background: rgba(255,255,255,.4);
  padding:0 12px;
}
.heroRefs__summary{
  cursor:pointer;
  font-size:12px;
  font-weight:700;
  padding:10px 0;
  color:var(--ink2);
  list-style-position:outside;
}
.heroRefs__list{
  margin:0 0 12px;
  padding-left:1.2em;
  font-size:11px;
  line-height:1.55;
  color:var(--ink2);
}
.heroRefs__list a{color: var(--green); font-weight:600;}
.heroRefs__list a:hover{text-decoration:underline;}
.heroRefs__note{display:block; font-weight:600; margin-bottom:4px; color:var(--ink3);}
.heroRefs__hoaLinks{display:block; margin-top:4px;}
.heroRefs__hoaLinks a{font-weight:600;}

.showcase__filmHint{margin:0 0 8px; font-size:11px; text-align:center;}
.showcase__film{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:12px;
  max-width:min(640px, 100%);
  margin:0 auto;
  padding:12px 10px 10px;
  border-radius:var(--radius2);
  background: rgba(255,255,255,.42);
  border:1px solid rgba(12,12,13,.1);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.6);
}
.showcase__fig{
  margin:0;
  border-radius:14px;
  overflow:hidden;
  border:1px solid var(--border2);
  background: linear-gradient(165deg, rgba(255,255,255,.88), rgba(245,240,230,.75));
  box-shadow: 0 6px 16px rgba(0,0,0,.07);
}
.showcase__frame{
  position:relative;
  width:100%;
  overflow:hidden;
  background:
    radial-gradient(ellipse 80% 60% at 50% 45%, rgba(255,255,255,.55), rgba(12,12,13,.05));
  border-bottom:1px solid rgba(12,12,13,.06);
}
.showcase__frame::before{
  content:"";
  display:block;
  padding-bottom:75%;
}
.showcase__frame img{
  position:absolute;
  left:0;
  top:0;
  width:100%;
  height:100%;
  object-fit:contain;
  object-position:center;
}
.showcase__cap{
  padding:7px 8px;
  font-size:10px;
  font-weight:700;
  letter-spacing:.02em;
  color:var(--ink2);
  border-top:1px solid var(--border);
  background: rgba(255,255,255,.65);
  text-align:center;
}

/* Before & After Studio — workflow intro */
.studio{
  margin-bottom:14px;
  padding:18px 18px 16px;
  border-radius:var(--radius);
  border:1px solid var(--border);
  background:
    linear-gradient(125deg, rgba(255,213,74,.14) 0%, transparent 38%),
    linear-gradient(315deg, rgba(22,163,74,.1) 100%, transparent 45%),
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(251,247,239,.82));
  box-shadow: var(--shadow);
  overflow:hidden;
}
.studio__head{margin-bottom:16px;}
.studio__headRow{display:flex; align-items:center; gap:12px; margin-bottom:8px;}
.studio__badge{
  display:inline-flex;
  padding:4px 11px;
  border-radius:999px;
  font-size:10px;
  font-weight:800;
  letter-spacing:.11em;
  text-transform:uppercase;
  color: rgba(12,12,13,.78);
  border:1px solid rgba(12,12,13,.12);
  background: linear-gradient(180deg, rgba(255,213,74,.5), rgba(212,175,55,.28));
  white-space:nowrap;
}
.studio__rule{
  flex:1;
  height:3px;
  border-radius:3px;
  background: linear-gradient(90deg, var(--gold), var(--green));
  opacity:.65;
  min-width:48px;
}
.studio__title{
  margin:0 0 10px;
  font-family: "Bebas Neue", Montserrat, var(--font);
  font-size:clamp(1.85rem, 4.5vw, 2.5rem);
  letter-spacing:.055em;
  line-height:1.02;
  color: rgba(12,12,13,.92);
}
.studio__title::after{
  content:"";
  display:block;
  width:min(200px, 55%);
  height:3px;
  margin-top:8px;
  border-radius:2px;
  background: linear-gradient(90deg, var(--gold), var(--green));
}
.studio__desc{
  margin:0;
  max-width:58ch;
  font-size:13px;
  line-height:1.55;
  color:var(--ink2);
}
.studioSteps{
  list-style:none;
  padding:0;
  margin:0;
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:12px;
  counter-reset: studio;
}
.studioStep{
  margin:0;
  padding:14px 12px 12px;
  border-radius:var(--radius2);
  border:1px solid var(--border2);
  background: rgba(255,255,255,.58);
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
  position:relative;
}
.studioStep__art{
  display:flex;
  align-items:center;
  justify-content:center;
  width:100%;
  margin-bottom:6px;
  color: var(--green);
}
.studioStep:nth-child(1) .studioStep__art{color: #1d4ed8;}
.studioStep:nth-child(2) .studioStep__art{color: #9a7b0a;}
.studioStep:nth-child(3) .studioStep__art{color: #15803d;}
.studioStep__svg{
  width:min(76px, 22vw);
  height:min(76px, 22vw);
}
.studioStep__num{
  position:absolute;
  top:8px;
  left:8px;
  width:22px;
  height:22px;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:11px;
  font-weight:800;
  font-family: Montserrat, var(--font);
  color: rgba(12,12,13,.88);
  background: linear-gradient(180deg, rgba(255,213,74,.75), rgba(212,175,55,.45));
  border:1px solid rgba(12,12,13,.12);
  line-height:1;
}
.studioStep__title{
  margin:0 0 6px;
  font-size:13px;
  font-weight:800;
  font-family: Montserrat, var(--font);
  letter-spacing:-.015em;
  color: rgba(12,12,13,.9);
}
.studioStep__text{
  margin:0;
  font-size:11.5px;
  line-height:1.45;
  color:var(--ink3);
  max-width:28ch;
}

[data-theme="dark"] .showcase{
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.03));
  border-color: rgba(255,255,255,.10);
}
[data-theme="dark"] .showcase__title{color: rgba(255,255,255,.94);}
[data-theme="dark"] .showcase__sub,
[data-theme="dark"] .showcase__eyebrow{color: rgba(255,255,255,.55);}
[data-theme="dark"] .showcase__sub--hero strong{color: rgba(255,255,255,.92);}
[data-theme="dark"] .heroCta{color: rgba(12,12,13,.94);}
[data-theme="dark"] .heroCta__meta{color: rgba(255,255,255,.62);}
[data-theme="dark"] .heroLocal__card{
  background: rgba(0,0,0,.22);
  border-color: rgba(255,255,255,.12);
}
[data-theme="dark"] .heroLocal__title{color: rgba(255,255,255,.9);}
[data-theme="dark"] .heroLocal__body,
[data-theme="dark"] .heroLocal__list{color: rgba(255,255,255,.72);}
[data-theme="dark"] .heroMicro{
  color: rgba(255,255,255,.58);
  background: rgba(0,0,0,.2);
  border-left-color: rgba(212,175,55,.5);
}
[data-theme="dark"] .heroRefs{
  border-color: rgba(255,255,255,.14);
  background: rgba(255,255,255,.03);
}
[data-theme="dark"] .heroRefs__summary{color: rgba(255,255,255,.78);}
[data-theme="dark"] .heroRefs__list{color: rgba(255,255,255,.65);}
[data-theme="dark"] .heroRefs__note{color: rgba(255,255,255,.5);}
[data-theme="dark"] .showcase__film{
  background: rgba(255,255,255,.04);
  border-color: rgba(255,255,255,.1);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.04);
}
[data-theme="dark"] .showcase__fig{
  border-color: rgba(255,255,255,.12);
  background: linear-gradient(165deg, rgba(255,255,255,.06), rgba(0,0,0,.25));
  box-shadow: 0 6px 20px rgba(0,0,0,.35);
}
[data-theme="dark"] .showcase__frame{
  background: radial-gradient(ellipse 80% 60% at 50% 45%, rgba(255,255,255,.08), rgba(0,0,0,.35));
  border-bottom-color: rgba(255,255,255,.08);
}
[data-theme="dark"] .showcase__cap{
  color: rgba(255,255,255,.78);
  background: rgba(0,0,0,.3);
  border-top-color: rgba(255,255,255,.10);
}
[data-theme="dark"] .studio{
  background:
    linear-gradient(125deg, rgba(255,213,74,.08) 0%, transparent 40%),
    linear-gradient(315deg, rgba(22,163,74,.08) 100%, transparent 45%),
    linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border-color: rgba(255,255,255,.1);
}
[data-theme="dark"] .studio__badge{
  color: rgba(255,255,255,.82);
  border-color: rgba(255,255,255,.14);
  background: linear-gradient(180deg, rgba(255,213,74,.22), rgba(212,175,55,.1));
}
[data-theme="dark"] .studio__title{color: rgba(255,255,255,.94);}
[data-theme="dark"] .studio__desc{color: rgba(255,255,255,.7);}
[data-theme="dark"] .studioStep{
  background: rgba(0,0,0,.22);
  border-color: rgba(255,255,255,.1);
}
[data-theme="dark"] .studioStep__title{color: rgba(255,255,255,.9);}
[data-theme="dark"] .studioStep__text{color: rgba(255,255,255,.58);}
[data-theme="dark"] .studioStep__num{
  color: rgba(12,12,13,.9);
  border-color: rgba(255,255,255,.12);
}
[data-theme="dark"] .studioStep:nth-child(1) .studioStep__art{color: #60a5fa;}
[data-theme="dark"] .studioStep:nth-child(2) .studioStep__art{color: #fbbf24;}
[data-theme="dark"] .studioStep:nth-child(3) .studioStep__art{color: #4ade80;}

.layout{
  display:grid;
  grid-template-columns: 420px 1fr;
  gap:14px;
  align-items:start;
}
.col{display:flex; flex-direction:column; gap:14px;}
.col--canvas .panel{position:sticky; top:14px;}

.panel{
  background: linear-gradient(180deg, rgba(255,255,255,.78), rgba(255,255,255,.62));
  border:1px solid var(--border);
  border-radius:var(--radius);
  box-shadow: var(--shadow);
  overflow:hidden;
}
.panel--wide{grid-column:1 / -1;}
.panel__head{
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 14px;
  border-bottom:1px solid var(--border);
  background:
    linear-gradient(90deg, rgba(255,213,74,.26), rgba(212,175,55,.14) 38%, rgba(22,163,74,.10));
}
.panel__label{display:flex; align-items:center; gap:10px; font-weight:600; font-size:13px;}
.panel__meta{color:var(--ink3); font-size:12px;}
.dot{width:10px; height:10px; border-radius:999px; display:inline-block;}
.dot--before{background:linear-gradient(180deg, #60a5fa, #2563eb);}
.dot--after{background:linear-gradient(180deg, #34d399, #16a34a);}
.dot--canvas{background:linear-gradient(180deg, #a78bfa, #7c3aed);}

.uploader{padding:14px;}
.uploader__input{position:absolute; width:1px; height:1px; opacity:0; pointer-events:none;}
.uploader__label{
  display:flex; align-items:center; gap:12px;
  border-radius:var(--radius2);
  border:1px dashed rgba(12,12,13,.22);
  padding:14px;
  background:rgba(255,255,255,.66);
  cursor:pointer;
  transition: border-color .15s ease, background .15s ease, transform .15s ease;
}
.uploader__label:hover{
  border-color:rgba(12,12,13,.30);
  background:rgba(255,255,255,.82);
  transform: translateY(-1px);
}
.uploader__icon{
  width:42px; height:42px; border-radius:12px;
  display:flex; align-items:center; justify-content:center;
  background:linear-gradient(180deg, rgba(255,213,74,.68), rgba(212,175,55,.50));
  border:1px solid rgba(12,12,13,.12);
  color: rgba(12,12,13,.92);
}
.uploader__icon svg{width:20px; height:20px;}
.uploader__title{font-weight:600; font-size:13px;}
.uploader__hint{color:var(--muted2); font-size:12px; margin-top:2px;}

.card{padding:14px; padding-top:0;}
.card__row{
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 0 10px;
  gap:10px;
}
.pill{
  font-size:12px; color:rgba(12,12,13,.78);
  border:1px solid var(--border);
  background:rgba(255,255,255,.84);
  padding:6px 10px;
  border-radius:999px;
  white-space:nowrap;
}
.segmented{
  display:inline-flex;
  border:1px solid var(--border);
  border-radius:999px;
  background:rgba(255,255,255,.86);
  overflow:hidden;
}
.segmented__btn{
  appearance:none; border:0; background:transparent;
  color:rgba(12,12,13,.72);
  padding:8px 10px;
  font-size:12px;
  cursor:pointer;
}
.segmented__btn[disabled]{opacity:.45; cursor:not-allowed}
.segmented__btn.is-active{
  background:rgba(12,12,13,.06);
  color:rgba(12,12,13,.92);
}

.card__body{padding:0 0 12px;}
.tab{display:none;}
.tab.is-active{display:block;}
.preview{
  width:100%;
  min-height:min(240px, 45vh);
  background:rgba(255,255,255,.76);
  border:1px solid var(--border);
  border-radius:var(--radius2);
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
  box-sizing:border-box;
}
/* Avoid height:100% on flex children — on mobile Safari it often resolves to 0 with auto-sized parents. */
.preview img,.preview video{
  display:block;
  max-width:100%;
  width:auto;
  height:auto;
  max-height:min(240px, 50vh);
  object-fit:contain;
  -webkit-touch-callout:none;
}

.controls{
  border-top:1px solid var(--border);
  padding-top:12px;
}
.controls__grid{
  display:grid;
  grid-template-columns: 1fr 1fr 1fr 1fr auto auto auto;
  gap:10px;
  align-items:end;
}
.control__label{font-size:12px; color:var(--ink3); margin-bottom:6px;}
input[type="range"]{width:100%;}
.hint{margin-top:10px; color:var(--ink3); font-size:12px;}

.btn{
  appearance:none;
  border:1px solid rgba(12,12,13,.16);
  background:linear-gradient(180deg, rgba(255,213,74,.70), rgba(212,175,55,.52));
  color:rgba(12,12,13,.92);
  padding:10px 12px;
  border-radius:12px;
  cursor:pointer;
  font-weight:600;
  font-size:12px;
  transition: transform .12s ease, background .12s ease, border-color .12s ease;
}
.btn:hover{
  transform: translateY(-1px);
  border-color: rgba(12,12,13,.24);
  background:linear-gradient(180deg, rgba(255,213,74,.82), rgba(212,175,55,.62));
}
.btn:active{transform:translateY(0);}
.btn--icon{
  display:inline-flex;
  align-items:center;
  gap:8px;
}
.btn--icon svg{width:16px; height:16px;}
.iconSlot{display:inline-flex; align-items:center; justify-content:center; width:16px; height:16px;}
.iconLoading{display:none;}
.btn.is-loading .iconNormal{display:none;}
.btn.is-loading .iconLoading{display:inline;}
.spin{animation: spin 0.9s linear infinite;}
@keyframes spin{from{transform:rotate(0deg)}to{transform:rotate(360deg)}}
.btn--ghost{
  border:1px solid rgba(12,12,13,.14);
  background:rgba(255,255,255,.86);
}
.btn--ghost:hover{
  border-color:rgba(12,12,13,.22);
  background:rgba(255,255,255,.92);
}

.canvasBar{
  display:flex;
  justify-content:space-between;
  gap:10px;
  padding:14px;
  border-bottom:1px solid var(--border);
}
.canvasBar__left,.canvasBar__right{display:flex; gap:10px; flex-wrap:wrap; align-items:end;}
.select{display:flex; flex-direction:column; gap:6px;}
.select__label{font-size:12px; color:var(--ink3);}
select{
  background:rgba(255,255,255,.90);
  border:1px solid rgba(12,12,13,.14);
  color:rgba(12,12,13,.90);
  padding:10px 10px;
  border-radius:12px;
  font-size:12px;
  min-width:220px;
}
.select--compact select{min-width: 160px;}
.select--compact input[type="range"]{width: 160px;}

.logoControls{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:end;
  padding:10px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.07);
  background:rgba(0,0,0,.14);
}
.toggle{
  display:flex; align-items:center; gap:8px;
  color:rgba(12,12,13,.78);
  font-size:12px;
  border:1px solid rgba(12,12,13,.14);
  background:rgba(255,255,255,.88);
  padding:10px 12px;
  border-radius:12px;
}
.toggle input{accent-color: var(--green);}

.stageWrap{padding:14px; display:flex; flex-direction:column; gap:10px;}
.stage{
  position:relative;
  margin:0 auto;
  width:min(520px, 100%);
}
#outCanvas{
  width:100%;
  height:auto;
  display:block;
  border-radius:18px;
  border:1px solid rgba(12,12,13,.14);
  background: var(--paper2);
  touch-action:none;
}
.stage__shadow{
  pointer-events:none;
  position:absolute; inset:-10px;
  border-radius:26px;
  box-shadow:0 26px 60px rgba(0,0,0,.55);
}
.smallMuted{color:var(--muted2); font-size:12px; text-align:center;}

.miniTools{
  padding:0 14px 14px;
  display:flex; flex-wrap:wrap; gap:10px;
}

.textTools{
  margin: 0 14px 14px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,.07);
  background: rgba(0,0,0,.14);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.textTools__title{
  grid-column: 1 / -1;
  font-weight: 700;
  letter-spacing: .02em;
  color: rgba(255,255,255,.86);
  font-size: 12px;
  text-transform: uppercase;
}
.textInput{
  display:flex;
  flex-direction:column;
  gap:6px;
}
.textInput span{
  font-size:12px;
  color: var(--muted2);
}
.textInput input{
  background:rgba(0,0,0,.25);
  border:1px solid var(--border);
  color:rgba(255,255,255,.90);
  padding:10px 10px;
  border-radius:12px;
  font-size:12px;
  width: 100%;
}
.row{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:center;
}
.row input{flex: 1 1 260px;}
.row .btn{white-space:nowrap;}
.textInput select{
  background:rgba(0,0,0,.25);
  border:1px solid var(--border);
  color:rgba(255,255,255,.90);
  padding:10px 10px;
  border-radius:12px;
  font-size:12px;
  width: 100%;
}
.textTools .toggle{
  grid-column: 1 / -1;
  justify-content: flex-start;
}
.textStatus{
  grid-column: 1 / -1;
  min-height: 18px;
  color: rgba(255,255,255,.74);
  font-size: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  white-space: normal;
  overflow-wrap: anywhere;
}
.textStatus .ok{color: rgba(22,163,74,.95);}
.textStatus .warn{color: rgba(212,175,55,.95);}
.textTabs{grid-column: 1 / -1;}
.textHistory{
  grid-column: 1 / -1;
  border: 1px solid rgba(255,255,255,.07);
  background: rgba(0,0,0,.12);
  border-radius: 16px;
  padding: 12px;
}
.historyList{
  margin-top: 10px;
  display:grid;
  grid-template-columns: 1fr;
  gap: 8px;
}
.historyItem{
  display:flex;
  gap:10px;
  align-items:center;
  justify-content:space-between;
  border:1px solid rgba(255,255,255,.07);
  background:rgba(0,0,0,.14);
  border-radius:14px;
  padding:10px 12px;
}
.historyItem__text{
  font-size:12px;
  color:rgba(255,255,255,.88);
  line-height:1.2;
}
.historyItem__actions{display:flex; gap:8px; flex-wrap:wrap;}
.btn.is-loading{
  opacity: .9;
  cursor: progress;
}

.frameControls{
  display:flex; align-items:center; justify-content:space-between;
  gap:10px;
  margin-bottom:10px;
}
.muted{color:var(--muted2); font-size:12px;}
.frames{
  display:grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap:10px;
}
.frame{
  border-radius:12px;
  overflow:hidden;
  border:1px solid var(--border);
  background:rgba(0,0,0,.25);
  cursor:pointer;
  transition: transform .12s ease, border-color .12s ease;
}
.frame:hover{transform: translateY(-1px); border-color:rgba(255,255,255,.16);}
.frame.is-active{border-color: rgba(34,197,94,.75);}
.frame img{width:100%; display:block; aspect-ratio: 1 / 1; object-fit:cover;}
.frame__t{
  padding:6px 8px;
  font-size:11px;
  color:rgba(255,255,255,.72);
  border-top:1px solid var(--border);
}

.footer{
  margin-top:14px;
  display:flex;
  flex-direction:column;
  gap:0;
  color:var(--ink3);
  font-size:12px;
}
.footer__main{
  display:flex;
  justify-content:space-between;
  gap:10px;
  flex-wrap:wrap;
  align-items:flex-start;
}
.footer__right{
  display:flex;
  flex-direction:column;
  align-items:flex-end;
  gap:8px;
  max-width:100%;
}
.footer__actionsLabel{
  margin:0;
  font-size:11px;
  font-weight:700;
  letter-spacing:.06em;
  text-transform:uppercase;
}
.footer__actions{
  display:flex;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:8px;
}
.footerBtn{
  display:inline-flex;
  flex-direction:column;
  align-items:flex-start;
  gap:2px;
  padding:8px 12px;
  min-height:44px;
  justify-content:center;
  border-radius:12px;
  border:1px solid rgba(12,12,13,.16);
  background:linear-gradient(180deg, rgba(255,213,74,.72), rgba(212,175,55,.52));
  color:rgba(12,12,13,.94);
  text-decoration:none;
  font-size:12px;
  font-weight:700;
  font-family: Montserrat, var(--font);
  box-shadow:0 2px 8px rgba(0,0,0,.08);
  transition: transform .12s ease, border-color .12s ease, filter .12s ease, box-shadow .12s ease;
}
.footerBtn:hover{
  filter:brightness(1.04);
  border-color:rgba(12,12,13,.24);
  transform:translateY(-1px);
  box-shadow:0 4px 12px rgba(0,0,0,.1);
}
.footerBtn:focus-visible{
  outline:2px solid var(--green);
  outline-offset:2px;
}
.footerBtn__title{
  font-size:11px;
  font-weight:800;
  letter-spacing:.04em;
  text-transform:uppercase;
  line-height:1.2;
}
.footerBtn__detail{
  font-size:11px;
  font-weight:600;
  opacity:.88;
  line-height:1.25;
  word-break:break-word;
  max-width:200px;
}
.footerBtn--social{
  background:linear-gradient(180deg, rgba(255,255,255,.92), rgba(245,240,232,.88));
  border-color:rgba(12,12,13,.12);
}
.footerBtn--social:hover{
  border-color:rgba(22,163,74,.35);
}
[data-theme="dark"] .footerBtn{
  background:linear-gradient(180deg, rgba(255,213,74,.35), rgba(212,175,55,.2));
  border-color:rgba(255,255,255,.14);
  color:rgba(255,255,255,.92);
  box-shadow:none;
}
[data-theme="dark"] .footerBtn__detail{opacity:.85;}
[data-theme="dark"] .footerBtn--social{
  background:rgba(255,255,255,.08);
  border-color:rgba(255,255,255,.14);
  color:rgba(255,255,255,.9);
}
[data-theme="dark"] .footerBtn--social:hover{border-color:rgba(74,222,128,.45);}
[data-theme="dark"] .footer__actionsLabel{color: rgba(255,255,255,.5);}
.kbd{
  display:inline-flex;
  padding:2px 6px;
  border-radius:8px;
  border:1px solid rgba(12,12,13,.14);
  background:rgba(255,255,255,.88);
  color:rgba(12,12,13,.78);
  font-size:11px;
}

@media (max-width: 920px){
  .layout{grid-template-columns:1fr;}
  .col--canvas .panel{position:static;}
  .topbar{flex-direction:column; align-items:stretch;}
  .menu{justify-content:space-between;}
  .brand__logo{width:42px; height:42px;}
  .app{padding:16px 12px 14px;}
  .panel__head{padding:12px;}
  .uploader{padding:12px;}
  .card{padding:12px; padding-top:0;}
  .canvasBar{padding:12px;}
  .stageWrap{padding:12px;}
  .miniTools{padding:0 12px 12px;}
  .textTools{margin:0 12px 12px; padding:12px;}
  select{min-width: 0; width: 100%;}
  .canvasBar{flex-direction:column; align-items:stretch;}
  .canvasBar__left,.canvasBar__right{justify-content:space-between;}
  .textTools{grid-template-columns:1fr;}
  .showcase__film{grid-template-columns:1fr; max-width:280px;}
  .studioSteps{grid-template-columns:1fr;}
  .studioStep__text{max-width:42ch;}
  .heroLocal{grid-template-columns:1fr;}
  .hero__ctaRow{flex-direction:column; align-items:flex-start;}
  .footer__right{align-items:stretch;}
  .footer__actions{justify-content:flex-start;}
}
