:root,
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0c0d12;
  --surface: #13151c;
  --surface-2: #181b24;
  --surface-3: #20232e;
  --border: #292c37;
  --border-soft: rgba(255,255,255,.07);
  --text: #f5f3f7;
  --muted: #9997a2;
  --muted-2: #6f6d78;
  --accent: #ff7b63;
  --accent-2: #9b7cfb;
  --accent-soft: rgba(255,123,99,.14);
  --violet-soft: rgba(155,124,251,.13);
  --success: #65d5a2;
  --shadow: 0 18px 55px rgba(0,0,0,.32);
  --sidebar: 248px;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f5f5f7;
  --surface: #ffffff;
  --surface-2: #f8f8fa;
  --surface-3: #eeeeF2;
  --border: #dedee5;
  --border-soft: rgba(20,18,24,.08);
  --text: #1d1b22;
  --muted: #686570;
  --muted-2: #8d8994;
  --accent: #ef644f;
  --accent-2: #795ee0;
  --accent-soft: rgba(239,100,79,.11);
  --violet-soft: rgba(121,94,224,.1);
  --success: #279b6c;
  --shadow: 0 18px 45px rgba(31,27,40,.09);
}

* { box-sizing: border-box; }
html { background: var(--bg); scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: Inter, "SF Pro Display", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
button, input, textarea, select { font: inherit; }
button { color: inherit; }
button, a, label { -webkit-tap-highlight-color: transparent; }
.icon { display: block; flex: 0 0 auto; }

.app-shell { min-height: 100dvh; background: var(--bg); }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 30; width: var(--sidebar); display: flex; flex-direction: column; padding: 24px 16px 18px; background: var(--surface); border-right: 1px solid var(--border); }
.sidebar-head { display: flex; align-items: center; justify-content: space-between; padding: 0 8px; }
.brand { display: flex; align-items: center; gap: 10px; min-width: max-content; color: var(--text); font-size: 17px; font-weight: 650; letter-spacing: -.35px; }
.brand b { color: var(--accent); font-weight: 750; }
.brand-mark { position: relative; width: 27px; height: 27px; border-radius: 9px; display: block; background: linear-gradient(135deg, #ff9a62, #f05c73 55%, #9573f3); box-shadow: 0 6px 18px rgba(239,100,79,.25); transform: rotate(-5deg); }
.brand-mark i { position: absolute; width: 5px; height: 13px; bottom: 6px; border-radius: 5px; background: #fff; transform: rotate(32deg); opacity: .95; }
.brand-mark i:nth-child(1) { left: 6px; height: 8px; }
.brand-mark i:nth-child(2) { left: 11px; height: 13px; }
.brand-mark i:nth-child(3) { left: 16px; height: 17px; }
.main-nav { display: grid; gap: 5px; margin-top: 34px; }
.main-nav button { position: relative; display: flex; align-items: center; gap: 13px; min-height: 44px; padding: 0 13px; border: 0; border-radius: 11px; background: transparent; color: var(--muted); cursor: pointer; text-align: left; transition: .18s ease; }
.main-nav button:hover { color: var(--text); background: var(--surface-2); }
.main-nav button.active { color: var(--text); background: linear-gradient(90deg, var(--accent-soft), transparent); }
.main-nav button.active::before { content: ""; position: absolute; left: -16px; width: 3px; height: 24px; border-radius: 0 4px 4px 0; background: var(--accent); }
.main-nav button.active .icon { color: var(--accent); }
.main-nav button span { flex: 1; font-weight: 560; }
.main-nav em { min-width: 23px; padding: 2px 6px; border-radius: 8px; background: var(--surface-3); color: var(--muted); font-size: 11px; font-style: normal; text-align: center; }
.sidebar-promo { margin-top: auto; padding: 15px; border: 1px solid var(--border); border-radius: 14px; background: radial-gradient(circle at 100% 0, var(--violet-soft), transparent 55%), var(--surface-2); }
.promo-icon { display: grid; place-items: center; width: 31px; height: 31px; margin-bottom: 11px; border-radius: 9px; color: #fff; background: linear-gradient(135deg, var(--accent), var(--accent-2)); }
.sidebar-promo strong { display: block; font-size: 12.5px; }
.sidebar-promo p { margin: 3px 0 11px; color: var(--muted); font-size: 11.5px; }
.sidebar-promo button { display: flex; align-items: center; gap: 5px; padding: 0; border: 0; background: transparent; color: var(--accent); font-size: 11.5px; font-weight: 700; cursor: pointer; }
.account-card { display: flex; align-items: center; gap: 9px; margin-top: 17px; padding: 13px 8px 0; border-top: 1px solid var(--border); }
.avatar { display: grid; place-items: center; width: 34px; height: 34px; flex: 0 0 auto; border-radius: 50%; background: linear-gradient(135deg, #ff9a62, #8d72e8); color: #fff; font-size: 11px; font-weight: 800; }
.account-card > span:nth-child(2) { min-width: 0; flex: 1; }
.account-card strong, .account-card small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-card strong { font-size: 12px; }.account-card small { color: var(--muted); font-size: 10.5px; }
.account-card button { padding: 3px; border: 0; background: transparent; color: var(--muted); cursor: pointer; }

.workspace { min-height: 100dvh; margin-left: var(--sidebar); }
.topbar { position: sticky; top: 0; z-index: 20; height: 72px; display: flex; align-items: center; gap: 22px; padding: 0 clamp(22px, 3vw, 44px); background: color-mix(in srgb, var(--bg) 88%, transparent); border-bottom: 1px solid var(--border-soft); backdrop-filter: blur(18px); }
.search { width: min(380px, 34vw); display: flex; align-items: center; gap: 9px; padding: 0 11px; height: 39px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--muted); }
.search input, .compact-search input { width: 100%; border: 0; outline: 0; background: transparent; color: var(--text); }
.search input::placeholder, .compact-search input::placeholder { color: var(--muted-2); }
.search kbd { padding: 2px 6px; border: 1px solid var(--border); border-radius: 5px; background: var(--surface-2); color: var(--muted); font-size: 10px; white-space: nowrap; }
.top-actions { display: flex; align-items: center; gap: 9px; margin-left: auto; }
.token-chip { height: 39px; display: flex; align-items: center; gap: 6px; padding: 0 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--text); cursor: pointer; }
.token-chip span { color: #ffc05f; }.token-chip small { color: var(--muted); }.token-chip b { font-size: 12.5px; }
.icon-button { width: 39px; height: 39px; display: grid; place-items: center; padding: 0; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); cursor: pointer; transition: .18s ease; }
.icon-button:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); color: var(--accent); }
.primary-button, .secondary-button { min-height: 39px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 15px; border-radius: 10px; cursor: pointer; font-weight: 680; transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.primary-button { border: 1px solid transparent; background: linear-gradient(120deg, #ff8e5e, #ee5e71); color: #fff; box-shadow: 0 7px 20px rgba(238,94,113,.18); }
.primary-button:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 10px 25px rgba(238,94,113,.28); }
.primary-button:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; }
.secondary-button { border: 1px solid var(--border); background: var(--surface); color: var(--text); }
.secondary-button:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.primary-button.large, .secondary-button.large { min-height: 44px; padding-inline: 19px; }
.page-content { width: min(1420px, 100%); margin: 0 auto; padding: 34px clamp(22px, 3vw, 44px) 70px; }
.page-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 26px; }
.page-heading h1 { margin: 0; font-size: clamp(24px, 2.2vw, 31px); line-height: 1.18; letter-spacing: -.8px; }
.page-heading p { margin: 7px 0 0; color: var(--muted); font-size: 13.5px; }
.saved { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; color: var(--success); font-size: 12px; }
.saved[hidden] { display: none; }

.hero-panel { min-height: 390px; display: grid; grid-template-columns: 1.05fr .95fr; overflow: hidden; position: relative; border: 1px solid var(--border); border-radius: 20px; background: radial-gradient(700px 390px at 78% 46%, var(--violet-soft), transparent 65%), linear-gradient(118deg, var(--surface), var(--surface-2)); box-shadow: var(--shadow); }
.hero-panel::after { content: ""; position: absolute; width: 350px; height: 350px; left: 38%; top: -72%; border: 1px solid var(--border-soft); border-radius: 50%; box-shadow: 0 0 0 45px rgba(255,255,255,.012), 0 0 0 90px rgba(255,255,255,.009); pointer-events: none; }
.hero-copy { position: relative; z-index: 2; display: flex; flex-direction: column; justify-content: center; padding: clamp(34px, 4vw, 58px); }
.eyebrow { width: fit-content; display: inline-flex; align-items: center; gap: 7px; padding: 6px 10px; border: 1px solid color-mix(in srgb, var(--accent) 26%, var(--border)); border-radius: 20px; background: var(--accent-soft); color: var(--accent); font-size: 10.5px; font-weight: 750; letter-spacing: .3px; text-transform: uppercase; }
.hero-copy h2 { max-width: 600px; margin: 18px 0 13px; font-size: clamp(36px, 4.4vw, 62px); line-height: .98; letter-spacing: -2.7px; }
.hero-copy p { max-width: 600px; margin: 0; color: var(--muted); font-size: clamp(14px, 1.3vw, 16px); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 25px; }
.marketplaces { display: flex; flex-wrap: wrap; gap: 10px 18px; margin-top: 27px; color: var(--muted-2); font-size: 9px; font-weight: 800; letter-spacing: .55px; }
.hero-preview { position: relative; min-height: 390px; }
.preview-glow { position: absolute; inset: 12% 9% 8% 6%; border-radius: 50%; background: radial-gradient(circle, rgba(155,124,251,.22), transparent 67%); filter: blur(15px); }
.preview-card { position: absolute; width: 212px; aspect-ratio: 3/4; border-radius: 14px; overflow: hidden; border: 1px solid rgba(255,255,255,.16); box-shadow: 0 26px 50px rgba(0,0,0,.34); }
.preview-card > img { width: 100%; height: 100%; display: block; object-fit: cover; }
.preview-card.front { left: 27%; top: 10%; transform: rotate(3deg); z-index: 2; }
.preview-card.back { left: 4%; top: 18%; transform: rotate(-8deg) scale(.86); opacity: .68; }
.floating-badge { position: absolute; z-index: 4; display: flex; align-items: center; gap: 7px; padding: 8px 10px; border: 1px solid rgba(255,255,255,.12); border-radius: 10px; background: color-mix(in srgb, var(--surface) 82%, transparent); box-shadow: var(--shadow); backdrop-filter: blur(12px); color: var(--text); font-size: 10px; font-weight: 700; }
.floating-badge.ready { left: 5%; bottom: 14%; }.floating-badge.ready .icon { color: var(--success); }.floating-badge.quality { right: 9%; top: 22%; color: #ffc56d; }

.product-visual { position: relative; width: 100%; height: 100%; min-height: 220px; overflow: hidden; isolation: isolate; background: linear-gradient(150deg, #f4b399, #bb615e 57%, #4e2532); color: #2d1721; }
.product-visual::before { content: ""; position: absolute; width: 90%; aspect-ratio: 1; right: -26%; bottom: -22%; border-radius: 50%; background: rgba(255,255,255,.19); box-shadow: 0 0 0 18px rgba(255,255,255,.07); }
.product-visual.violet { background: linear-gradient(150deg, #a496e8, #54448d 58%, #22203f); color: #fff; }
.product-visual.mint { background: linear-gradient(150deg, #c5ddc8, #7ba390 58%, #314b48); color: #17312c; }
.product-visual.blue { background: linear-gradient(150deg, #b8dff0, #4f8ead 58%, #203b54); color: #123041; }
.visual-copy { position: absolute; z-index: 3; top: 8%; left: 9%; display: flex; flex-direction: column; }
.visual-copy small { font-size: 6px; font-weight: 800; letter-spacing: 1.2px; opacity: .7; }
.visual-copy strong { max-width: 125px; margin-top: 5px; font-size: 23px; line-height: .88; letter-spacing: -1.2px; }
.visual-copy span { margin-top: 7px; font-size: 7px; font-weight: 650; opacity: .76; }
.product-object { position: absolute; z-index: 2; right: 8%; bottom: -5%; width: 48%; height: 64%; display: grid; place-items: center; border-radius: 45% 45% 16% 16%; background: linear-gradient(90deg, rgba(255,255,255,.82), rgba(255,255,255,.42) 45%, rgba(255,255,255,.72)); border: 1px solid rgba(255,255,255,.6); box-shadow: 0 17px 30px rgba(44,18,34,.22); transform: rotate(7deg); backdrop-filter: blur(6px); }
.product-object::before { content: ""; position: absolute; top: -10%; width: 65%; height: 14%; border-radius: 5px 5px 2px 2px; background: #e4d4c9; }
.product-object i { position: absolute; top: 29%; width: 72%; height: 1px; background: rgba(45,23,33,.18); }
.product-object b { color: rgba(45,23,33,.67); font-size: 18px; letter-spacing: -1px; }
.violet .product-object { border-radius: 32px; height: 43%; bottom: 13%; background: linear-gradient(120deg, #27242f, #111117); border-color: rgba(255,255,255,.16); }.violet .product-object::before { display: none; }.violet .product-object b { color: #fff; }
.mint .product-object { height: 52%; width: 58%; border-radius: 55% 28% 12% 10%; background: linear-gradient(120deg,#ebe0d2,#aa8c7a); }.mint .product-object::before { display: none; }
.blue .product-object { border-radius: 10px; background: linear-gradient(90deg,#f8f1d9,#d7c994); }
.visual-pill { position: absolute; z-index: 4; left: 9%; bottom: 8%; padding: 3px 7px; border-radius: 8px; background: rgba(255,255,255,.23); font-size: 6px; font-weight: 800; text-transform: uppercase; backdrop-filter: blur(4px); }

.stat-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; margin-top: 16px; }
.stat-grid article { display: flex; align-items: center; gap: 14px; padding: 17px 18px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }
.stat-icon { width: 39px; height: 39px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 11px; }.stat-icon.coral { color: var(--accent); background: var(--accent-soft); }.stat-icon.violet { color: var(--accent-2); background: var(--violet-soft); }.stat-icon.green { color: var(--success); background: color-mix(in srgb, var(--success) 12%, transparent); }.stat-icon.blue { color: #65a9e9; background: rgba(81,155,226,.12); }
.stat-grid article div { display: grid; grid-template-columns: auto auto; align-items: baseline; flex: 1; }.stat-grid small { grid-column: 1/-1; color: var(--muted); font-size: 10.5px; }.stat-grid strong { font-size: 22px; letter-spacing: -.5px; }.stat-grid em { justify-self: end; color: var(--muted-2); font-size: 9px; font-style: normal; }
.section-block { margin-top: 34px; }.section-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 13px; }.section-title h2 { margin: 0; font-size: 17px; letter-spacing: -.3px; }.section-title button { display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: transparent; color: var(--muted); font-size: 11px; cursor: pointer; }.section-title button:hover { color: var(--accent); }
.mode-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; }.mode-card { position: relative; display: flex; align-items: center; min-width: 0; gap: 12px; padding: 16px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); text-align: left; cursor: pointer; transition: .2s ease; }.mode-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 30%, var(--border)); box-shadow: var(--shadow); }.mode-card.featured { border-color: color-mix(in srgb, var(--accent) 30%, var(--border)); background: linear-gradient(110deg,var(--accent-soft),var(--surface) 45%); }.mode-card > em { position: absolute; top: -7px; right: 11px; padding: 2px 7px; border-radius: 7px; background: var(--accent); color: #fff; font-size: 7px; font-style: normal; font-weight: 800; letter-spacing: .5px; }
.mode-icon { width: 42px; height: 42px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 11px; background: var(--surface-2); color: var(--muted); }.mode-icon.cover { color: var(--accent); background: var(--accent-soft); }.mode-icon.infographic { color: var(--accent-2); background: var(--violet-soft); }.mode-icon.product { color: #61a9e9; background: rgba(81,155,226,.11); }.mode-icon.model { color: var(--success); background: color-mix(in srgb,var(--success) 11%,transparent); }
.mode-copy { min-width: 0; flex: 1; }.mode-copy strong,.mode-copy small { display: block; }.mode-copy strong { font-size: 12.5px; }.mode-copy small { overflow: hidden; margin-top: 3px; color: var(--muted); font-size: 10.5px; white-space: nowrap; text-overflow: ellipsis; }.mode-arrow { color: var(--muted-2); }
.recent-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; }.project-card { position: relative; display: grid; grid-template-columns: 106px 1fr; min-height: 142px; overflow: hidden; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }.project-card > .product-visual { min-height: 142px; }.project-info { min-width: 0; padding: 14px; }.status { display: flex; align-items: center; gap: 5px; width: fit-content; color: var(--success); font-size: 9px; }.status i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }.status.draft { color: #e2a95d; }.status.running { color: #62a6f5; }.status.error { color: #ee6b79; }.project-info h3 { overflow: hidden; margin: 10px 0 3px; font-size: 12px; white-space: nowrap; text-overflow: ellipsis; }.project-info p { margin: 0; color: var(--muted); font-size: 9.5px; }.project-info > div { display: flex; gap: 4px; margin-top: 13px; }.project-info button,.project-info a { width: 27px; height: 27px; display: grid; place-items: center; padding: 0; border: 1px solid var(--border); border-radius: 7px; background: var(--surface-2); color: var(--muted); cursor: pointer; text-decoration: none; }.project-info button:disabled { opacity: .38; cursor: not-allowed; }.project-info button .icon,.project-info a .icon { width: 14px; }.resume { width: 100%; min-height: 30px; display: flex; align-items: center; justify-content: center; gap: 5px; margin-top: 8px; padding: 6px 8px; border: 0; border-radius: 7px; background: var(--accent-soft); color: var(--accent); font-size: 9px; cursor: pointer; }

.creator-layout { display: grid; grid-template-columns: minmax(0,1fr) 330px; align-items: start; gap: 20px; }.creator-main { min-width: 0; }.mode-tabs { display: grid; grid-template-columns: repeat(5,1fr); gap: 7px; margin-bottom: 14px; }.mode-tabs button { min-height: 70px; display: grid; justify-items: center; align-content: center; gap: 6px; padding: 7px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); color: var(--muted); font-size: 10px; cursor: pointer; }.mode-tabs button:hover { color: var(--text); }.mode-tabs button.active { border-color: color-mix(in srgb,var(--accent) 42%,var(--border)); background: var(--accent-soft); color: var(--accent); }.form-card,.creator-summary { border: 1px solid var(--border); border-radius: 16px; background: var(--surface); }.form-card { padding: 22px; }.form-step { display: flex; align-items: center; gap: 11px; margin-bottom: 14px; }.form-step > span { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 8px; background: var(--accent-soft); color: var(--accent); font-size: 11px; font-weight: 800; }.form-step strong,.form-step small { display: block; }.form-step strong { font-size: 13px; }.form-step small { margin-top: 1px; color: var(--muted); font-size: 10.5px; }
.upload-zone { min-height: 165px; display: grid; place-items: center; align-content: center; gap: 5px; border: 1px dashed color-mix(in srgb,var(--accent) 33%,var(--border)); border-radius: 13px; background: linear-gradient(120deg,var(--accent-soft),transparent 55%); cursor: pointer; transition: .18s ease; }.upload-zone:hover { border-color: var(--accent); }.upload-zone input { position: absolute; width: 1px; height: 1px; opacity: 0; }.upload-symbol,.upload-success { width: 46px; height: 46px; display: grid; place-items: center; margin-bottom: 5px; border-radius: 13px; background: var(--surface); color: var(--accent); box-shadow: var(--shadow); }.upload-success { color: var(--success); }.upload-zone strong { font-size: 12px; }.upload-zone small { color: var(--muted); font-size: 10.5px; }.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; margin-top: 20px; }.form-card label:not(.upload-zone) { position: relative; display: block; }.form-card label > span { display: block; margin-bottom: 7px; font-size: 11px; font-weight: 650; }.form-card input,.form-card select,.form-card textarea { width: 100%; border: 1px solid var(--border); border-radius: 10px; outline: none; background: var(--surface-2); color: var(--text); transition: .18s ease; }.form-card input,.form-card select { height: 43px; padding: 0 12px; }.form-card textarea { resize: vertical; min-height: 115px; padding: 11px 12px; line-height: 1.5; }.form-card input:focus,.form-card select:focus,.form-card textarea:focus { border-color: color-mix(in srgb,var(--accent) 60%,var(--border)); box-shadow: 0 0 0 3px var(--accent-soft); }.form-card label:not(.upload-zone) > small { position: absolute; right: 9px; bottom: 7px; color: var(--muted-2); font-size: 9px; }.textarea-label { margin-top: 15px; }
.creator-summary { position: sticky; top: 92px; overflow: hidden; padding: 14px; }.summary-preview { position: relative; height: 295px; overflow: hidden; border-radius: 12px; }.summary-preview .product-visual { min-height: 295px; }.summary-preview > span { position: absolute; z-index: 6; left: 10px; bottom: 10px; padding: 5px 8px; border-radius: 8px; background: rgba(18,18,22,.6); color: #fff; font-size: 9px; backdrop-filter: blur(8px); }.summary-lines { display: grid; gap: 8px; padding: 15px 3px 11px; border-bottom: 1px solid var(--border); }.summary-lines div { display: flex; justify-content: space-between; color: var(--muted); font-size: 10.5px; }.summary-lines b { color: var(--text); }.generate { width: 100%; min-height: 45px; margin-top: 13px; font-size: 11.5px; }.clear-button { width: 100%; display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 8px; padding: 7px; border: 0; background: transparent; color: var(--muted); font-size: 10px; cursor: pointer; }.creator-summary > p { display: flex; align-items: flex-start; gap: 6px; margin: 8px 2px 0; color: var(--muted-2); font-size: 8.5px; }
.project-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 16px; }.filter-tabs,.segmented { display: flex; gap: 4px; padding: 4px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface); }.filter-tabs button,.segmented button { min-height: 32px; padding: 0 13px; border: 0; border-radius: 8px; background: transparent; color: var(--muted); font-size: 11px; cursor: pointer; }.filter-tabs button.active,.segmented button.active { background: var(--surface-3); color: var(--text); box-shadow: 0 2px 8px rgba(0,0,0,.08); }.compact-search { width: 230px; height: 38px; display: flex; align-items: center; gap: 8px; padding: 0 10px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--muted); }.projects-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; }.projects-grid .project-card { grid-template-columns: 1fr; min-height: 0; }.projects-grid .project-card > .product-visual { aspect-ratio: 4/3; min-height: 0; }.projects-grid .project-info { padding: 16px; }.projects-grid .project-info h3 { font-size: 14px; }
.balance-hero { display: flex; justify-content: space-between; align-items: center; padding: 28px 32px; border: 1px solid var(--border); border-radius: 18px; background: radial-gradient(420px 210px at 85% 20%,var(--violet-soft),transparent),var(--surface); }.balance-hero small { color: var(--muted); }.balance-hero strong { display: block; margin: 3px 0; font-size: 36px; letter-spacing: -1.5px; }.balance-hero strong span,.plans-grid strong span { color: #f2ae50; }.balance-hero p { margin: 0; color: var(--muted); font-size: 11px; }.balance-art { width: 88px; height: 88px; display: grid; place-items: center; border-radius: 25px; background: linear-gradient(135deg,var(--accent-soft),var(--violet-soft)); color: var(--accent); transform: rotate(5deg); }.plans-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin-top: 18px; }.plans-grid article { position: relative; padding: 25px; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); }.plans-grid article.best { border-color: color-mix(in srgb,var(--accent) 42%,var(--border)); background: linear-gradient(145deg,var(--accent-soft),var(--surface) 40%); }.plans-grid article > em { position: absolute; top: 13px; right: 13px; padding: 4px 8px; border-radius: 7px; background: var(--accent); color: #fff; font-size: 8px; font-style: normal; font-weight: 800; text-transform: uppercase; }.plans-grid h3 { margin: 0 0 18px; font-size: 15px; }.plans-grid strong { display: block; font-size: 27px; }.plans-grid p { margin: 3px 0 19px; color: var(--muted); }.plans-grid button { width: 100%; }
.settings-stack { display: grid; gap: 12px; max-width: 900px; }.settings-card { display: flex; align-items: center; justify-content: space-between; gap: 25px; padding: 20px; border: 1px solid var(--border); border-radius: 15px; background: var(--surface); }.settings-head { display: flex; align-items: center; gap: 13px; }.settings-head > span { width: 40px; height: 40px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 11px; background: var(--surface-2); color: var(--accent); }.settings-head h2 { margin: 0; font-size: 13px; }.settings-head p { max-width: 570px; margin: 4px 0 0; color: var(--muted); font-size: 10.5px; }.segmented button { display: flex; align-items: center; gap: 6px; white-space: nowrap; }.danger-ghost { display: flex; align-items: center; gap: 7px; padding: 8px 11px; border: 1px solid rgba(220,76,88,.24); border-radius: 9px; background: rgba(220,76,88,.08); color: #e76a76; font-size: 10.5px; cursor: pointer; white-space: nowrap; }.security-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; flex-wrap: wrap; }.secure-label { display: flex; align-items: center; gap: 7px; color: var(--success); font-size: 10px; }.secure-label i { width: 7px; height: 7px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 5px color-mix(in srgb,var(--success) 12%,transparent); }
.settings-card .secondary-button { min-height: 34px; padding: 0 11px; border-radius: 9px; font-size: 10.5px; white-space: nowrap; }
.faq-list { display: grid; gap: 9px; max-width: 900px; }.faq-list article { overflow: hidden; border: 1px solid var(--border); border-radius: 13px; background: var(--surface); }.faq-list article > button { width: 100%; min-height: 58px; display: flex; align-items: center; justify-content: space-between; padding: 0 18px; border: 0; background: transparent; cursor: pointer; text-align: left; }.faq-list article > button strong { font-size: 12px; }.faq-list article > button span { color: var(--muted); transition: .2s ease; }.faq-list article > div { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .25s ease; }.faq-list article > div p { min-height: 0; overflow: hidden; margin: 0; padding: 0 18px; color: var(--muted); font-size: 11px; }.faq-list article.open > div { grid-template-rows: 1fr; }.faq-list article.open > div p { padding-bottom: 18px; }.faq-list article.open > button span { transform: rotate(90deg); color: var(--accent); }.support-banner { max-width: 900px; display: flex; align-items: center; gap: 14px; margin-top: 16px; padding: 18px; border: 1px solid var(--border); border-radius: 14px; background: linear-gradient(110deg,var(--violet-soft),var(--surface)); }.support-banner > span { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; background: var(--surface); color: var(--accent-2); }.support-banner div { flex: 1; }.support-banner strong { font-size: 12px; }.support-banner p { margin: 2px 0 0; color: var(--muted); font-size: 10.5px; }

.modal-layer { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(7,7,10,.72); backdrop-filter: blur(9px); animation: fadeIn .2s ease; }.generation-modal { width: min(430px,100%); padding: 34px; border: 1px solid var(--border); border-radius: 20px; background: var(--surface); box-shadow: 0 30px 80px rgba(0,0,0,.45); text-align: center; }.generation-modal h2 { margin: 20px 0 7px; font-size: 20px; }.generation-modal > p { margin: 0; color: var(--muted); font-size: 11.5px; }.ai-orbit { position: relative; width: 72px; height: 72px; display: grid; place-items: center; margin: 0 auto; }.ai-orbit > span { width: 49px; height: 49px; display: grid; place-items: center; border-radius: 15px; background: linear-gradient(135deg,var(--accent),var(--accent-2)); color: #fff; box-shadow: 0 0 35px var(--accent-soft); }.ai-orbit > i { position: absolute; inset: 0; border: 1px solid var(--border); border-top-color: var(--accent); border-radius: 50%; animation: spin 1.2s linear infinite; }.progress-track { height: 7px; overflow: hidden; margin-top: 25px; border-radius: 9px; background: var(--surface-3); }.progress-track i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg,var(--accent),var(--accent-2)); transition: width .35s ease; }.progress-meta { display: flex; justify-content: space-between; gap: 10px; margin-top: 7px; color: var(--muted); font-size: 9px; }.done-icon { width: 62px; height: 62px; display: grid; place-items: center; margin: 0 auto; border-radius: 50%; background: color-mix(in srgb,var(--success) 13%,transparent); color: var(--success); }.modal-actions { display: flex; justify-content: center; gap: 8px; margin-top: 23px; }.toast { position: fixed; z-index: 150; right: 22px; bottom: 22px; display: flex; align-items: center; gap: 7px; padding: 11px 14px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface); box-shadow: var(--shadow); color: var(--success); font-size: 11px; animation: slideUp .25s ease; }
.toast[hidden] { display: none; }
.mobile-menu,.mobile-close,.mobile-logo { display: none; }.scrim { display: none; }

.skeleton-shell .sidebar { gap: 12px; }.skeleton-shell .workspace { padding: 30px 42px; }.sk { position: relative; overflow: hidden; min-height: 90px; border-radius: 14px; background: var(--surface); }.sk::after { content:""; position:absolute; inset:0; transform:translateX(-100%); background:linear-gradient(90deg,transparent,rgba(255,255,255,.055),transparent); animation: shimmer 1.3s infinite; }.sk-nav { min-height: 42px; margin-top: 25px; }.sk-top { min-height: 40px; width: 33%; }.sk-title { min-height: 31px; width: 26%; margin-top: 38px; }.sk-sub { min-height: 14px; width: 44%; margin-top: 10px; }.sk-hero { min-height: 360px; margin-top: 28px; }.skeleton-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; margin-top: 15px; }.skeleton-grid .sk { min-height: 85px; }

@keyframes shimmer { to { transform: translateX(100%); } }@keyframes spin { to { transform: rotate(360deg); } }@keyframes fadeIn { from { opacity:0; } }@keyframes slideUp { from { opacity:0; transform:translateY(8px); } }

@media (max-width: 1160px) {
  .hero-panel { grid-template-columns: 1.1fr .9fr; }.hero-copy h2 { font-size: 48px; }.preview-card { width: 180px; }.stat-grid { grid-template-columns: repeat(2,1fr); }.mode-grid { grid-template-columns: repeat(2,1fr); }.recent-grid,.projects-grid { grid-template-columns: repeat(2,1fr); }.creator-layout { grid-template-columns: minmax(0,1fr) 295px; }
}
@media (max-width: 860px) {
  :root { --sidebar: 228px; }.top-create { width: 39px; padding: 0; }.top-create span { display:none; }.search { flex: 1; width:auto; }.hero-panel { grid-template-columns: 1fr; }.hero-preview { min-height: 330px; }.preview-card.front { left: 42%; }.preview-card.back { left: 22%; }.floating-badge.ready { left: 22%; }.creator-layout { grid-template-columns: 1fr; }.creator-summary { position: static; display: grid; grid-template-columns: 190px 1fr; gap: 10px; }.summary-preview { grid-row: 1/6; height: 230px; }.summary-preview .product-visual { min-height:230px; }.summary-lines { align-self:end; }.creator-summary > p { align-self:start; }.mode-tabs { overflow-x:auto; grid-template-columns: repeat(5,120px); padding-bottom:4px; }
}
@media (max-width: 720px) {
  .sidebar { width: min(300px,86vw); transform: translateX(-105%); transition: transform .24s ease; box-shadow: 20px 0 60px rgba(0,0,0,.35); }.sidebar.is-open { transform:translateX(0); }.mobile-close,.mobile-menu { display:grid; }.scrim { position:fixed; inset:0; z-index:29; display:block; border:0; background:rgba(0,0,0,.48); backdrop-filter:blur(3px); }.workspace { margin-left:0; }.topbar { height:64px; padding:0 15px; gap:10px; }.mobile-logo { display:block; }.mobile-logo .brand > span:last-child { display:none; }.mobile-logo .brand { gap:0; }.search { display:none; }.token-chip small { display:none; }.page-content { padding:24px 15px 90px; }.page-heading { margin-bottom:20px; }.page-heading h1 { font-size:25px; }.page-heading p { font-size:12px; }.hero-panel { min-height:0; }.hero-copy { padding:28px 24px; }.hero-copy h2 { font-size:42px; letter-spacing:-2px; }.hero-preview { min-height:320px; }.stat-grid { grid-template-columns:1fr 1fr; }.mode-grid { grid-template-columns:1fr; }.recent-grid,.projects-grid { grid-template-columns:1fr; }.recent-grid .project-card { grid-template-columns:112px 1fr; }.form-row { grid-template-columns:1fr; }.creator-summary { grid-template-columns:135px 1fr; }.summary-preview { height:190px; }.summary-preview .product-visual { min-height:190px; }.visual-copy strong { font-size:18px; }.settings-card { align-items:flex-start; flex-direction:column; }.segmented { width:100%; }.segmented button { flex:1; justify-content:center; }.project-toolbar { align-items:stretch; flex-direction:column; }.compact-search { width:100%; }.plans-grid { grid-template-columns:1fr; }.support-banner { align-items:flex-start; flex-wrap:wrap; }.support-banner button { width:100%; }.skeleton-shell .workspace { margin:0; padding:25px 15px; }.skeleton-shell .sidebar { display:none; }.skeleton-grid { grid-template-columns:1fr 1fr; }
}

/* Stage 5: account wallet, subscription controls and contextual navigation. */
.sidebar-alert { margin-top: auto; padding: 15px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface-2); }
.sidebar-alert.subscription-alert { background: linear-gradient(135deg, rgba(255, 142, 94, .12), rgba(155, 124, 251, .11)), var(--surface-2); }
.sidebar-alert.balance-alert { background: linear-gradient(135deg, rgba(49, 133, 255, .10), rgba(139, 92, 246, .10)), var(--surface-2); }
.sidebar-alert.payment-alert { border-color: rgba(231, 106, 118, .25); background: rgba(220, 76, 88, .08); }
.sidebar-alert strong { display: block; font-size: 12.5px; }
.sidebar-alert p { margin: 3px 0 11px; color: var(--muted); font-size: 10.5px; }
.sidebar-alert button { display: flex; align-items: center; gap: 5px; padding: 0; border: 0; background: transparent; color: var(--accent); font-size: 10.5px; font-weight: 700; cursor: pointer; }
.main-nav + .account-card { margin-top: auto; }
.avatar { border: 0; cursor: pointer; }

.mode-new_card .mode-icon { color: #ff8a55; background: rgba(255, 138, 85, .13); }
.mode-edit_card .mode-icon { color: #9b9aa4; background: rgba(155, 154, 164, .12); }
.mode-photoshoot_product .mode-icon { color: #9b9aa4; background: rgba(155, 154, 164, .12); }

.balance-hero { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(360px, 1.5fr) 88px; gap: 24px; }
.balance-total { min-width: 0; }
.balance-split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.balance-split article { min-width: 0; display: flex; align-items: center; gap: 10px; padding: 13px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); }
.balance-split article > div { min-width: 0; }
.balance-split small,.balance-split b,.balance-split em { display: block; }
.balance-split small { color: var(--muted); font-size: 9px; }
.balance-split b { margin-top: 2px; font-size: 18px; }
.balance-split em { overflow: hidden; margin-top: 3px; color: var(--muted-2); font-size: 8px; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.token-kind { width: 35px; height: 35px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 10px; }
.token-kind.monthly { color: #ff835f; background: var(--accent-soft); }
.token-kind.bonus { color: #7f87ff; background: rgba(87, 112, 255, .12); }

.subscription-panel { display: flex; align-items: center; justify-content: space-between; gap: 22px; margin-top: 14px; padding: 19px 21px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }
.subscription-panel.active { border-color: color-mix(in srgb, var(--accent-2) 35%, var(--border)); background: linear-gradient(120deg, rgba(155, 124, 251, .10), transparent 42%), var(--surface); }
.subscription-main { display: flex; align-items: center; gap: 13px; min-width: 0; }
.subscription-icon { width: 43px; height: 43px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 12px; background: var(--accent-gradient); color: #fff; }
.subscription-main small { color: var(--muted); font-size: 9px; }
.subscription-main h2 { margin: 2px 0; font-size: 15px; }
.subscription-main p { margin: 0; color: var(--muted); font-size: 10px; }
.subscription-meta { display: flex; align-items: center; gap: 20px; }
.subscription-meta > span small,.subscription-meta > span b { display: block; }
.subscription-meta > span small { color: var(--muted); font-size: 8px; }
.subscription-meta > span b { margin-top: 2px; font-size: 10.5px; white-space: nowrap; }
.subscription-meta button:disabled { opacity: .55; cursor: default; }

.tariff-section.monthly .tariff-icon { background: linear-gradient(120deg, #f0448f, #ff765e); }
.tariff-section.bonus .tariff-icon { background: linear-gradient(120deg, #3185ff, #8b5cf6); }
.tariff-section.bonus .tariff-card.best { border-color: color-mix(in srgb, #6d6ff5 48%, var(--border)); background: linear-gradient(120deg, rgba(49,133,255,.12), rgba(139,92,246,.12)); }

.operations-section { margin-top: 34px; }
.operations-section .section-title > span { color: var(--muted); font-size: 9px; }
.operations-list { overflow: hidden; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }
.operation-row { display: grid; grid-template-columns: 35px minmax(0, 1fr) auto; align-items: center; gap: 11px; min-height: 62px; padding: 10px 15px; border-bottom: 1px solid var(--border); }
.operation-row:last-child { border-bottom: 0; }
.operation-icon { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 10px; }
.operation-icon.purchase { color: var(--success); background: color-mix(in srgb, var(--success) 12%, transparent); }
.operation-icon.spend { color: #8b82ed; background: rgba(139, 130, 237, .12); }
.operation-row > span:nth-child(2) { min-width: 0; }
.operation-row strong,.operation-row small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.operation-row strong { font-size: 11px; }
.operation-row small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.operation-row > b { font-size: 11px; }
.operation-row > b.positive { color: var(--success); }
.operation-row > b.negative { color: var(--text); }
.operations-empty { padding: 34px; color: var(--muted); text-align: center; }

.settings-avatar { color: #fff !important; background: var(--accent-gradient) !important; font-size: 11px; font-weight: 800; }
.legal-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.legal-links a { padding: 7px 9px; border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-size: 9px; text-decoration: none; }
.legal-links a:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); color: var(--accent); }

@media (max-width: 1080px) {
  .balance-hero { grid-template-columns: minmax(180px, .8fr) minmax(360px, 1.5fr); }
  .balance-art { display: none; }
  .subscription-panel { align-items: flex-start; flex-direction: column; }
  .subscription-meta { width: 100%; justify-content: space-between; }
}

@media (max-width: 720px) {
  .balance-hero { grid-template-columns: 1fr; gap: 16px; }
  .balance-split { grid-template-columns: 1fr 1fr; }
  .subscription-meta { align-items: stretch; flex-direction: column; gap: 10px; }
  .subscription-meta button { width: 100%; }
  .legal-links { width: 100%; justify-content: flex-start; }
  .legal-links a { flex: 1 1 auto; text-align: center; }
}

@media (max-width: 440px) {
  .balance-split { grid-template-columns: 1fr; }
  .operation-row { grid-template-columns: 32px minmax(0, 1fr) auto; padding-inline: 11px; }
  .operation-icon { width: 32px; height: 32px; }
}
@media (max-width: 440px) {
  .token-chip { padding:0 9px; }.theme-toggle { display:none; }.hero-copy h2 { font-size:36px; }.hero-actions > button { width:100%; }.hero-preview { min-height:280px; }.preview-card { width:150px; }.preview-card.front { left:37%; }.preview-card.back { left:12%; }.floating-badge.ready { left:8%; }.stat-grid { grid-template-columns:1fr; }.stat-grid article { padding:14px 16px; }.section-block { margin-top:28px; }.creator-summary { grid-template-columns:1fr; }.summary-preview { grid-row:auto; height:310px; }.summary-preview .product-visual { min-height:310px; }.mode-tabs { grid-template-columns:repeat(5,104px); }.mode-tabs button { min-height:64px; }.form-card { padding:16px; }.upload-zone { min-height:145px; }.balance-hero { padding:22px; }.balance-art { display:none; }.modal-actions { flex-direction:column-reverse; }.modal-actions button { width:100%; }.page-heading > .primary-button { width:39px; padding:0; }.page-heading > .primary-button span { display:none; }
}
@media (prefers-reduced-motion: reduce) { *,*::before,*::after { scroll-behavior:auto!important; animation-duration:.01ms!important; animation-iteration-count:1!important; transition-duration:.01ms!important; } }
@media (prefers-contrast: more) { :root { --border:#6f6f77; }.primary-button { border-color:#fff; } }

/* Stage 1 additions: keep the prototype's layout while applying the new brand accent. */
:root {
  --accent-gradient: linear-gradient(120deg, #ff8e5e 0%, #ee5e71 48%, #9b7cfb 100%);
  --accent-gradient-soft: linear-gradient(110deg, rgba(255, 142, 94, .15), rgba(155, 124, 251, .12));
}

.brand b,
.sidebar-promo button,
.eyebrow,
.mode-icon.cover,
.mode-icon.infographic,
.top-avatar-menu button:hover { color: transparent; background-image: var(--accent-gradient); background-clip: text; -webkit-background-clip: text; }
.mode-icon.edit { color: #f47773; background: var(--accent-soft); }
.mode-card.mode-edit_card .mode-icon { color: #9b9aa4; background: rgba(155, 154, 164, .12); }
.main-nav button.active::before,
.brand-mark,
.primary-button,
.promo-icon,
.ai-orbit > span,
.progress-track i { background: var(--accent-gradient); }
.primary-button { box-shadow: 0 7px 20px rgba(155, 124, 251, .22); }
.primary-button:hover:not(:disabled) { box-shadow: 0 10px 25px rgba(155, 124, 251, .30); }
.mode-tabs button.active,
.main-nav button.active { background: var(--accent-gradient-soft); }

.top-profile { position: relative; }
.brand-home { padding: 0; border: 0; background: transparent; cursor: pointer; text-align: left; }
.brand-home:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; border-radius: 6px; }
.header-create { margin-right: auto; }
.top-actions { margin-left: 0; }
.top-avatar { width: 39px; height: 39px; border: 1px solid var(--border); border-radius: 50%; background: var(--accent-gradient); color: #fff; font-size: 11px; font-weight: 800; cursor: pointer; }
.top-avatar-menu { position: absolute; top: calc(100% + 9px); right: 0; width: 225px; padding: 8px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); box-shadow: var(--shadow); }
.top-avatar-menu[hidden] { display: none; }
.top-avatar-menu strong,.top-avatar-menu small { display:block; padding: 4px 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-avatar-menu small { color: var(--muted); font-size: 10px; padding-bottom: 9px; border-bottom: 1px solid var(--border); }
.top-avatar-menu button { width:100%; display:flex; padding: 9px 8px; border:0; border-radius:7px; background:transparent; color:var(--text); cursor:pointer; text-align:left; }

.mode-tabs { grid-template-columns: repeat(var(--mode-count, 5), minmax(106px, 1fr)); overflow-x: auto; }
.mode-tabs button { min-width: 106px; }
.mode-group { margin-top: 16px; color: var(--muted); font-size: 11px; }
.mode-group b { color: var(--text); }
.mode-grid.extended { grid-template-columns: repeat(3, 1fr); }
.empty-projects { padding: 48px 22px; border: 1px dashed var(--border); border-radius: 14px; color: var(--muted); text-align: center; }

.project-badges { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 0 !important; }
.generation-badge { display: inline-flex; align-items: center; min-height: 20px; padding: 3px 8px; border-radius: 999px; color: #fff; font-size: 8.5px; font-weight: 700; line-height: 1.2; }
.generation-badge.create { background: linear-gradient(105deg, #f0448f, #ff765e); box-shadow: 0 4px 12px rgba(240, 68, 143, .2); }
.generation-badge.photo { background: linear-gradient(105deg, #3185ff, #8b5cf6); box-shadow: 0 4px 12px rgba(80, 102, 255, .2); }
.project-actions { display: flex; gap: 4px; margin-top: 13px; }
.project-filters { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 12px; }
.filter-block { display: grid; gap: 5px; }
.filter-block > span { color: var(--muted); font-size: 9px; }
.project-toolbar { align-items: flex-end; }

@media (max-width: 860px) { .mode-tabs { grid-template-columns: repeat(var(--mode-count, 5), 116px); } .mode-grid.extended { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px) { .top-profile { display:none; } .mode-grid.extended { grid-template-columns: 1fr; } .project-filters { align-items: stretch; flex-direction: column; } .filter-tabs { width: 100%; } .filter-tabs button { flex: 1; padding-inline: 8px; } .project-actions button,.project-actions a { font-size: 8px; padding-inline: 4px; } .project-detail-list div { grid-template-columns: 1fr; gap: 3px; } .project-preview-modal,.project-info-modal,.project-form-modal { padding: 22px; } }

/* Stage 1.1: persistent active labels, denser project previews and tariff groups. */
.main-nav button.active .icon,
.mode-tabs button.active .icon { color: #f47773; background: none; }
.mode-tabs button.active { color: var(--text); }
.mode-tabs button.active span { color: var(--text); }

.project-info > .project-badges { gap: 10px !important; margin-top: 0; }
.recent-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.project-card { grid-template-columns: 1fr; min-height: 0; }
.project-card > .product-visual,
.projects-grid .project-card > .product-visual { height: auto; min-height: 0; aspect-ratio: 3 / 4; }
.product-visual.project-image { background: var(--surface-2); }
.product-visual.project-image img { width: 100%; height: 100%; display: block; object-fit: cover; }
.draft-visual { display: grid; place-items: center; align-content: center; gap: 8px; background: radial-gradient(circle at 50% 28%, rgba(255, 255, 255, .08), transparent 35%), linear-gradient(145deg, #16161d, #09090d); color: #fff; text-align: center; }
.draft-visual span { padding: 7px 11px; border: 1px solid rgba(255, 255, 255, .16); border-radius: 999px; background: rgba(255, 255, 255, .06); font-size: 13px; font-weight: 800; text-transform: uppercase; }
.draft-visual small { max-width: 80%; color: rgba(255, 255, 255, .52); font-size: 9px; line-height: 1.3; }
.running-visual { display: grid; place-items: center; align-content: center; gap: 11px; background: radial-gradient(circle at 50% 40%, rgba(244, 119, 115, .13), transparent 42%), linear-gradient(145deg, #17171e, #09090d); color: #fff; text-align: center; }
.running-visual::before { display: none; }
.running-visual strong { max-width: 78%; font-size: 11px; line-height: 1.35; }
.running-visual time { min-width: 64px; color: rgba(255, 255, 255, .64); font-size: 13px; font-variant-numeric: tabular-nums; font-weight: 750; }
.running-spinner { width: 34px; height: 34px; border: 3px solid rgba(255, 255, 255, .14); border-top-color: #f47773; border-right-color: #a47cfb; border-radius: 50%; animation: generationSpin .85s linear infinite; }
@keyframes generationSpin { to { transform: rotate(360deg); } }
.project-info { min-height: 130px; padding: 13px; }
.projects-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.projects-grid .project-info { padding: 13px; }
.projects-grid .project-info h3 { font-size: 12.5px; }
.project-toolbar { justify-content: flex-start; }
.project-actions { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px !important; }
.project-actions button,
.project-actions a { width: auto; min-width: 0; height: 28px; display: inline-flex; align-items: center; justify-content: center; gap: 4px; padding: 0 6px; font-size: 8.5px; line-height: 1; }
.project-actions span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.project-actions button[disabled] { pointer-events: none; }
.project-preview-modal,
.project-info-modal,
.project-form-modal { width: min(620px, 100%); text-align: left; }
.project-preview-image { width: min(360px, 100%); aspect-ratio: 3 / 4; display: block; margin: 18px auto 0; object-fit: contain; border: 1px solid var(--border); border-radius: 14px; background: var(--surface-2); }
.project-preview-empty { min-height: 280px; display: grid; place-items: center; gap: 10px; margin-top: 18px; border: 1px dashed var(--border); border-radius: 14px; color: var(--muted); }
.project-detail-list { display: grid; gap: 8px; margin: 18px 0 0; }
.project-detail-list div { display: grid; grid-template-columns: 150px 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.project-detail-list dt { color: var(--muted); font-size: 10px; }
.project-detail-list dd { margin: 0; color: var(--text); font-size: 11px; line-height: 1.45; overflow-wrap: anywhere; }
.project-info-modal .modal-actions { flex-wrap: wrap; }
.project-modal-form { display: grid; gap: 16px; margin-top: 18px; }
.project-modal-form label span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 10px; }
.project-modal-form input { width: 100%; height: 44px; padding: 0 12px; border: 1px solid var(--border); border-radius: 10px; outline: none; background: var(--surface-2); color: var(--text); }
.project-modal-form input:focus { border-color: color-mix(in srgb, var(--accent) 60%, var(--border)); box-shadow: 0 0 0 3px var(--accent-soft); }
.danger-action { background: linear-gradient(135deg, #e84f62, #ff825e) !important; box-shadow: 0 7px 20px rgba(232, 79, 98, .18) !important; }
.edit-choice-list { display: grid; gap: 10px; margin-top: 18px; }
.edit-choice { width: 100%; display: grid; grid-template-columns: 28px 1fr 18px; align-items: center; gap: 11px; padding: 14px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-2); color: var(--text); text-align: left; cursor: pointer; }
.edit-choice:hover { border-color: var(--accent); background: var(--accent-soft); }
.edit-choice > .icon { color: var(--accent); }
.edit-choice strong,.edit-choice small { display: block; }
.edit-choice strong { font-size: 12px; }
.edit-choice small { margin-top: 4px; color: var(--muted); font-size: 10px; line-height: 1.4; }

/* Project cards share one content rhythm; a reserved slot keeps draft controls aligned. */
.project-card { display: flex; flex-direction: column; transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.project-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 28%, var(--border)); box-shadow: var(--shadow); }
.project-info,.projects-grid .project-info { display: flex; flex-direction: column; min-height: 214px; box-sizing: border-box; }
.project-actions { flex: 0 0 auto; }
.project-resume-slot { min-height: 18px; margin-top: 4px; }
.project-info .resume { width: 100%; min-width: 0; min-height: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; margin: 0; padding: 0 9px; border: 1px solid transparent; border-radius: 7px; background: var(--accent-soft); color: var(--accent); font-size: 9px; font-weight: 700; line-height: 1; cursor: pointer; transition: transform .16s ease, background .16s ease, border-color .16s ease, box-shadow .16s ease; }
.project-actions button,.project-actions a { transition: transform .16s ease, color .16s ease, border-color .16s ease, background .16s ease, box-shadow .16s ease; }
.project-actions button:not([disabled]):hover,.project-actions a:hover { transform: translateY(-1px); border-color: color-mix(in srgb, var(--accent) 42%, var(--border)); background: var(--accent-soft); color: var(--accent); box-shadow: 0 5px 12px rgba(18, 18, 28, .1); }
.project-info .resume:hover { transform: translateY(-1px); border-color: color-mix(in srgb, var(--accent) 36%, var(--border)); background: color-mix(in srgb, var(--accent-soft) 72%, var(--surface)); box-shadow: 0 5px 12px rgba(18, 18, 28, .1); }
.project-actions button:not([disabled]):active,.project-actions a:active,.project-info .resume:active { transform: translateY(0); box-shadow: none; }

@media (prefers-reduced-motion: reduce) {
  .project-card,.project-actions button,.project-actions a,.project-info .resume { transition: none; }
  .project-card:hover,.project-actions button:not([disabled]):hover,.project-actions a:hover,.project-info .resume:hover { transform: none; }
}

.tariff-groups { display: grid; gap: 30px; margin-top: 28px; }
.tariff-section { min-width: 0; }
.tariff-heading { display: flex; align-items: center; gap: 12px; margin-bottom: 13px; }
.tariff-heading h2 { margin: 0; font-size: 16px; }
.tariff-heading p { margin: 3px 0 0; color: var(--muted); font-size: 10.5px; }
.tariff-icon { width: 40px; height: 40px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 11px; color: #fff; }
.tariff-section.create .tariff-icon { background: linear-gradient(120deg, #f0448f, #ff765e); }
.tariff-section.photo .tariff-icon { background: linear-gradient(120deg, #3185ff, #8b5cf6); }
.tariff-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.tariff-card { position: relative; min-width: 0; padding: 17px 15px 15px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }
.tariff-card.best { border-color: color-mix(in srgb, var(--accent) 42%, var(--border)); background: var(--accent-gradient-soft); }
.tariff-section.photo .tariff-card.best { border-color: color-mix(in srgb, #6d6ff5 48%, var(--border)); background: linear-gradient(120deg, rgba(49,133,255,.12), rgba(139,92,246,.12)); }
.tariff-card > em { position: absolute; top: 10px; right: 9px; padding: 3px 6px; border-radius: 6px; background: var(--accent-gradient); color: #fff; font-size: 7px; font-style: normal; font-weight: 800; }
.tariff-card h3 { margin: 0 0 15px; font-size: 12px; }
.tariff-card strong { display: block; font-size: 25px; line-height: 1; }
.tariff-card small { color: var(--muted); font-size: 9px; }
.tariff-card p { margin: 15px 0 12px; color: var(--text); font-size: 12px; font-weight: 700; }
.tariff-card button { width: 100%; min-height: 35px; padding-inline: 8px; font-size: 10px; }

@media (max-width: 1160px) {
  .recent-grid,.projects-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tariff-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  .recent-grid,.projects-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .mobile-logo { display: none; }
  .top-profile { display: block; }
  .topbar { gap: 8px; }
  .header-create { margin-right: auto; }
  .top-actions { gap: 7px; }
  .top-avatar { width: 37px; height: 37px; }
  .recent-grid,.projects-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .recent-grid .project-card { grid-template-columns: 1fr; }
  .project-info,.projects-grid .project-info { min-height: 122px; padding: 10px; }
  .project-info h3,.projects-grid .project-info h3 { margin-top: 8px; font-size: 11px; }
  .project-info p { font-size: 8.5px; }
  .project-info > .project-badges { align-items: flex-start; gap: 8px !important; }
  .generation-badge { min-height: 18px; padding: 3px 6px; font-size: 7.5px; }
  .status { min-height: 18px; font-size: 8px; }
  .project-info > .project-actions { margin-top: 10px; }
  .project-info button { width: 25px; height: 25px; }
  .project-info .project-actions button,
  .project-info .project-actions a { width: 100%; height: 28px; padding: 0 4px; font-size: 8px; }
  .project-actions span { overflow: visible; text-overflow: clip; }
  .project-info .resume { width: 100%; min-height: 30px; height: 30px; padding: 0 6px; font-size: 8px; }
  .project-info .resume .icon { width: 13px; }
  .project-resume-slot { min-height: 16px; margin-top: 4px; }
  .project-toolbar { display: block; margin-bottom: 13px; }
  .project-filters { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; gap: 8px; }
  .filter-block { min-width: 0; }
  .filter-tabs { min-width: 0; padding: 3px; }
  .filter-tabs button { min-width: 0; min-height: 29px; padding-inline: 2px; font-size: 9px; }
  .page-heading { gap: 8px; }
  .page-create-button { min-height: 34px; padding-inline: 10px; font-size: 9.5px; white-space: nowrap; }
  .page-create-button .icon { width: 15px; height: 15px; }
  .tariff-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .tariff-card { padding: 15px 12px 12px; }
}

@media (max-width: 440px) {
  .page-heading > .page-create-button { width: auto; min-height: 34px; padding: 0 9px; }
  .page-heading > .page-create-button span { display: inline; }
}

/* Stage 2: explicit mode selection and mode-local builder fields. */
.eyebrow { justify-content: center; text-align: center; }
.eyebrow > span { display: block; }
.eyebrow > .icon { color: var(--accent); }
.marketplaces .wildberries { color: #b681ff; }
.marketplaces .ozon { color: #438cff; }
.marketplaces .yandex { color: #ffd348; }

.selection-intro { display: flex; align-items: center; gap: 12px; margin-bottom: 15px; }
.selection-intro > span { width: 44px; height: 44px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 12px; background: var(--accent-gradient); color: #fff; }
.selection-intro.photo > span { background: linear-gradient(120deg, #3185ff, #8b5cf6); }
.selection-intro strong,.selection-intro small { display: block; }
.selection-intro strong { font-size: 13px; }
.selection-intro small { margin-top: 2px; color: var(--muted); font-size: 10.5px; }
.mode-description { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 10px; margin: -12px 0 20px; padding: 13px 15px; border-left: 2px solid var(--accent); background: color-mix(in srgb, var(--accent-soft) 48%, transparent); }
.mode-description > span { width: 32px; height: 32px; display: grid; place-items: center; color: var(--accent); }
.mode-description p { margin: 0; color: var(--text); font-size: 11px; line-height: 1.55; }
.mode-description ul { display: grid; grid-template-columns: minmax(0, 1fr); gap: 5px; margin: 7px 0 0; padding: 0; list-style: none; }
.mode-description li { position: relative; padding-left: 10px; color: var(--muted); font-size: 9.5px; line-height: 1.4; }
.mode-description li::before { content: ""; position: absolute; top: .55em; left: 0; width: 4px; height: 4px; border-radius: 50%; background: var(--accent); }
.generation-select-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; max-width: 980px; }
.generation-choice { position: relative; min-width: 0; min-height: 96px; display: grid; grid-template-columns: 48px minmax(0, 1fr) auto 20px; align-items: center; gap: 13px; padding: 18px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); color: var(--text); cursor: pointer; text-align: left; transition: transform .18s ease, border-color .18s ease, background .18s ease; }
.generation-choice:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 34%, var(--border)); background: var(--surface-2); }
.choice-icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 13px; color: #fff; }
.choice-icon.create { background: linear-gradient(120deg, #f0448f, #ff765e); }
.choice-icon.photo { background: linear-gradient(120deg, #3185ff, #8b5cf6); }
.generation-choice > span:nth-child(2) { min-width: 0; }
.generation-choice strong,.generation-choice small { display: block; }
.generation-choice strong { font-size: 13px; }
.generation-choice small { margin-top: 4px; color: var(--muted); font-size: 10.5px; }
.generation-choice em { color: #f2ae50; font-size: 10px; font-style: normal; font-weight: 750; white-space: nowrap; }
.generation-choice > .icon { color: var(--muted); }
.compact-back { min-height: 36px; font-size: 10px; }
.compact-back .icon,.builder-navigation button .icon { transform: rotate(180deg); }

.builder-navigation { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: -8px 0 14px; }
.builder-navigation > button { display: inline-flex; align-items: center; gap: 6px; padding: 0; border: 0; background: transparent; color: var(--muted); font-size: 10.5px; cursor: pointer; }
.builder-navigation > button:hover { color: var(--text); }
.generation-type { display: inline-flex; align-items: center; min-height: 23px; padding: 3px 9px; border-radius: 999px; color: #fff; font-size: 8.5px; font-weight: 750; }
.generation-type.create { background: linear-gradient(105deg, #f0448f, #ff765e); }
.generation-type.photo { background: linear-gradient(105deg, #3185ff, #8b5cf6); }
.builder-fields { padding: 2px 22px; }
.field-block { padding: 21px 0; border-bottom: 1px solid var(--border); }
.field-block:last-child { border-bottom: 0; }
.field-heading { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: center; gap: 10px; margin-bottom: 13px; }
.field-heading > span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: var(--surface-2); color: #f47773; }
.field-heading strong,.field-heading small { display: block; }
.field-heading strong { font-size: 12.5px; }
.field-heading small { margin-top: 2px; color: var(--muted); font-size: 9.5px; }
.field-heading em { padding: 3px 7px; border-radius: 7px; font-size: 7.5px; font-style: normal; font-weight: 750; }
.field-heading em.required { background: var(--accent-soft); color: var(--accent); }
.field-heading em.optional { background: var(--surface-2); color: var(--muted); }
.field-input { display: block; min-width: 0; }
.field-input > span { display: block; margin-bottom: 6px; color: var(--muted); font-size: 9px; }
.field-input input,.field-input textarea { width: 100%; border: 1px solid var(--border); border-radius: 10px; outline: none; background: var(--surface-2); color: var(--text); transition: border-color .18s ease, box-shadow .18s ease; }
.field-input input { height: 43px; padding: 0 12px; }
.field-input textarea { min-height: 106px; padding: 11px 12px; resize: vertical; }
.field-input input:focus,.field-input textarea:focus { border-color: color-mix(in srgb, var(--accent) 60%, var(--border)); box-shadow: 0 0 0 3px var(--accent-soft); }
.file-control { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px; align-items: stretch; }
.file-control > label { min-width: 0; min-height: 76px; display: grid; grid-template-columns: 36px minmax(0, 1fr); align-content: center; column-gap: 10px; padding: 11px 13px; border: 1px dashed color-mix(in srgb, var(--accent) 34%, var(--border)); border-radius: 11px; background: var(--surface-2); cursor: pointer; transition: border-color .16s ease, background .16s ease, box-shadow .16s ease; }
.file-control > label input,.gallery-upload > label input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.file-control > label > span { width: 36px; height: 36px; display: grid; grid-row: 1 / 3; place-items: center; border-radius: 10px; background: var(--accent-soft); color: var(--accent); }
.file-control > label strong,.file-control > label small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-control > label strong { align-self: end; font-size: 11px; }
.file-control > label small { align-self: start; color: var(--muted); font-size: 8.5px; }
.file-control.ready > label { border-style: solid; border-color: color-mix(in srgb, var(--success) 42%, var(--border)); }
.file-control.ready > label > span { background: color-mix(in srgb, var(--success) 13%, transparent); color: var(--success); }
.file-control.drag-over > label,.gallery-upload.drag-over > label { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 14%, transparent); }
.file-control > .icon-button { align-self: center; }
.file-pick { align-self: center; min-height: 39px; font-size: 9px; }
.style-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; }
.style-choice { position: relative; min-width: 0; display: block; overflow: hidden; padding: 0; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); color: var(--text); cursor: pointer; text-align: left; }
.style-choice::before { content: none; }
.style-choice::after { content: ""; position: absolute; inset: 0; border: 2px solid transparent; border-radius: inherit; pointer-events: none; }
.style-choice.active::after { border-color: #ff7b63; }
.style-image { position: relative; display: block; width: 100%; aspect-ratio: 3 / 4; overflow: hidden; background: var(--surface-3); }
.style-image > img { width: 100%; height: 100%; display: block; object-fit: cover; }
.style-image > i { position: absolute; top: 7px; right: 7px; width: 23px; height: 23px; display: grid; place-items: center; border-radius: 50%; background: var(--accent-gradient); color: #fff; font-style: normal; }
.style-image > i:empty { display: none; }
.style-caption { min-height: 82px; display: block; padding: 9px 10px 10px; }
.style-caption strong,.style-caption small { display: block; }
.style-caption strong { font-size: 10px; }
.style-caption small { margin-top: 4px; color: var(--muted); font-size: 9px; line-height: 1.4; }
.style-choice.copy-style { grid-column: 1 / -1; justify-self: center; width: min(82%, 460px); aspect-ratio: 9 / 4; display: grid; grid-template-columns: 40% minmax(0, 1fr); align-items: stretch; }
.style-choice.copy-style .style-image { height: 100%; aspect-ratio: auto; min-height: 0; }
.style-choice.copy-style .style-caption { min-height: 0; display: flex; flex-direction: column; justify-content: center; padding: 16px; }
.style-choice.copy-style .style-caption strong { font-size: 11px; }
.style-choice.copy-style .style-caption small { font-size: 9px; }
.nested-control { margin-top: 13px; padding-top: 13px; border-top: 1px solid var(--border); }
.nested-control > strong { display: block; margin-bottom: 8px; font-size: 10.5px; }
.thumb-row { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(180px, .8fr); gap: 10px; align-items: end; }
.gallery-upload { display: grid; gap: 10px; }
.gallery-upload > label { min-height: 62px; display: flex; align-items: center; gap: 10px; padding: 11px 13px; border: 1px dashed color-mix(in srgb, var(--accent) 34%, var(--border)); border-radius: 11px; background: var(--surface-2); color: var(--accent); cursor: pointer; transition: border-color .16s ease, background .16s ease, box-shadow .16s ease; }
.gallery-upload > label span strong,.gallery-upload > label span small { display: block; }
.gallery-upload > label span strong { color: var(--text); font-size: 10.5px; }
.gallery-upload > label span small { color: var(--muted); font-size: 8.5px; }
.gallery-files { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.gallery-file { min-width: 0; padding: 9px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); }
.gallery-file-preview { position: relative; width: 100%; aspect-ratio: 3 / 2; overflow: hidden; border-radius: 7px; background: var(--surface-3); }
.gallery-file-preview img { width: 100%; height: 100%; display: block; object-fit: cover; }
.gallery-file-preview > span { position: absolute; left: 6px; top: 6px; width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; background: rgba(18,18,22,.68); color: #fff; font-size: 8px; }
.gallery-file-preview button { position: absolute; right: 6px; top: 6px; width: 24px; height: 24px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 50%; background: rgba(18,18,22,.68); color: #fff; cursor: pointer; }
.gallery-file .field-input { margin-top: 8px; }
.gallery-file .field-input input { height: 36px; font-size: 9px; }
.gallery-file .field-input > span { margin-bottom: 4px; }
.color-modes { display: inline-flex; gap: 4px; margin-bottom: 10px; padding: 4px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); }
.color-modes button { min-height: 31px; display: flex; align-items: center; gap: 5px; padding: 0 10px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); font-size: 9px; cursor: pointer; }
.color-modes button.active { background: var(--surface-3); color: var(--text); }
.color-entry { display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: 10px; align-items: end; }
.color-entry > input[type="color"] { width: 54px; height: 43px; padding: 4px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); cursor: pointer; }
.summary-checks { display: grid; gap: 6px; margin: 12px 3px 0; padding: 0; list-style: none; }
.summary-checks li { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 9px; }
.summary-checks li > span { width: 17px; height: 17px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; background: var(--surface-2); }
.summary-checks li.ready { color: var(--success); }
.summary-checks li.ready > span { background: color-mix(in srgb, var(--success) 13%, transparent); }
.summary-checks li.missing > span { background: var(--accent-soft); color: var(--accent); font-weight: 800; }
.error-icon { width: 62px; height: 62px; display: grid; place-items: center; margin: 0 auto; border-radius: 50%; background: rgba(220,76,88,.12); color: #e76a76; font-size: 25px; font-weight: 800; }
.result-preview { width: 150px; aspect-ratio: 3 / 4; display: block; margin: 0 auto; object-fit: cover; border: 1px solid var(--border); border-radius: 11px; }
.summary-preview { border: 1px solid var(--border); background: var(--surface-2); }
.summary-preview.empty { background: var(--surface-2); }
.summary-preview.has-image > img { width: 100%; height: 100%; display: block; object-fit: contain; background: var(--surface-3); }
.project-picker-modal { width: min(640px, 100%); max-height: min(720px, 88vh); overflow: hidden; padding: 0; text-align: left; }
.picker-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px; border-bottom: 1px solid var(--border); }
.picker-heading h2 { margin: 0; font-size: 18px; }
.picker-heading p { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.project-picker-grid { max-height: 560px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; overflow-y: auto; padding: 14px; }
.picker-project { min-width: 0; display: grid; grid-template-columns: 62px minmax(0, 1fr) 18px; align-items: center; gap: 10px; padding: 9px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); color: var(--text); cursor: pointer; text-align: left; }
.picker-project:hover { border-color: color-mix(in srgb, var(--accent) 42%, var(--border)); }
.picker-project > .product-visual { width: 62px; height: auto; min-height: 0; aspect-ratio: 3 / 4; border-radius: 7px; }
.picker-project strong,.picker-project small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.picker-project strong { font-size: 10.5px; }
.picker-project small { margin-top: 3px; color: var(--muted); font-size: 8.5px; }
.picker-project > .icon { color: var(--muted); }
.picker-empty { grid-column: 1 / -1; padding: 35px 15px; color: var(--muted); text-align: center; }

@media (max-width: 720px) {
  .generation-select-grid { grid-template-columns: 1fr; }
  .generation-choice { min-height: 88px; grid-template-columns: 44px minmax(0, 1fr) auto 18px; padding: 14px; }
  .choice-icon { width: 44px; height: 44px; }
  .builder-fields { padding-inline: 15px; }
  .field-heading { grid-template-columns: 32px minmax(0, 1fr); }
  .field-heading > em { grid-column: 2; justify-self: start; }
  .file-control { grid-template-columns: minmax(0, 1fr) auto; }
  .file-pick { grid-column: 1 / -1; width: 100%; }
  .style-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .style-choice.copy-style { width: min(88%, 420px); grid-template-columns: 40% minmax(0, 1fr); }
  .thumb-row { grid-template-columns: 1fr; }
  .creator-summary { display: block; }
  .creator-summary .summary-preview { height: 260px; }
  .creator-summary .summary-preview .product-visual { min-height: 260px; }
  .project-picker-grid { grid-template-columns: 1fr; }
}

@media (max-width: 440px) {
  .generation-choice { grid-template-columns: 42px minmax(0, 1fr) 18px; gap: 10px; }
  .generation-choice em { display: none; }
  .generation-choice strong { font-size: 12px; }
  .generation-choice small { font-size: 9.5px; }
  .builder-navigation { margin-top: -4px; }
  .field-block { padding-block: 18px; }
  .style-caption { min-height: 92px; padding-inline: 8px; }
  .style-choice.copy-style { width: 92%; grid-template-columns: 38% minmax(0, 1fr); }
  .gallery-files { grid-template-columns: 1fr; }
}

/* Stage 4: authentication and browser-data controls. */
.auth-shell { min-height: 100dvh; display: grid; place-items: center; padding: 28px 16px; background: var(--bg); }
.auth-panel { width: min(430px, 100%); padding: 29px; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow); }
.auth-brand { display: flex; align-items: center; justify-content: center; gap: 10px; font-size: 17px; font-weight: 680; }
.auth-brand b { color: var(--accent); }
.auth-heading { margin: 27px 0 19px; text-align: center; }
.auth-heading h1 { margin: 0; font-size: 25px; }
.auth-heading p { margin: 6px 0 0; color: var(--muted); font-size: 11px; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-2); }
.auth-tabs button { min-height: 34px; border: 0; border-radius: 8px; background: transparent; color: var(--muted); font-size: 10.5px; cursor: pointer; }
.auth-tabs button.active { background: var(--surface); color: var(--text); box-shadow: 0 3px 10px rgba(0,0,0,.12); }
.oauth-stack { display: grid; gap: 8px; margin-top: 15px; }
.oauth-legal { margin: 8px 4px 0; color: var(--muted-2); font-size: 8px; line-height: 1.45; text-align: center; }
.oauth-legal a { color: var(--muted); }
.oauth-button { min-height: 44px; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; align-items: center; gap: 9px; padding: 0 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); color: var(--text); font-size: 11px; font-weight: 670; text-decoration: none; cursor: pointer; text-align: left; }
.oauth-button > span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; color: #fff; font-size: 11px; font-weight: 800; }
.oauth-button.yandex > span { background: #fc3f1d; }
.oauth-button.vk > span { background: #2787f5; font-size: 9px; }
.oauth-button > .icon { color: var(--muted); }
.oauth-button:disabled { opacity: .48; cursor: not-allowed; }
.oauth-button small { color: var(--muted); font-size: 8px; font-weight: 500; }
.auth-divider { display: flex; align-items: center; gap: 10px; margin: 17px 0; color: var(--muted-2); font-size: 8.5px; }
.auth-divider::before,.auth-divider::after { content: ""; height: 1px; flex: 1; background: var(--border); }
.auth-form { display: grid; gap: 12px; }
.auth-form > label:not(.legal-consent) { display: grid; gap: 6px; }
.auth-form > label > span { font-size: 9.5px; font-weight: 650; }
.auth-form input:not([type="checkbox"]) { width: 100%; height: 43px; padding: 0 12px; border: 1px solid var(--border); border-radius: 10px; outline: none; background: var(--surface-2); color: var(--text); }
.auth-form input:focus { border-color: color-mix(in srgb, var(--accent) 55%, var(--border)); box-shadow: 0 0 0 3px var(--accent-soft); }
.legal-consent { display: grid; grid-template-columns: 17px minmax(0, 1fr); align-items: center; gap: 8px; color: var(--muted); font-size: 9px; }
.legal-consent input { width: 17px; height: 17px; margin: 0; accent-color: var(--accent); }
.legal-consent > span { line-height: 1.45; }
.legal-consent a { color: var(--text); }
.auth-submit { width: 100%; min-height: 44px; margin-top: 2px; }
.auth-foot { margin: 17px 0 0; color: var(--muted); font-size: 9.5px; text-align: center; }
.auth-foot button { padding: 0; border: 0; background: transparent; color: var(--accent); cursor: pointer; }
.auth-error { margin: 0 0 12px; padding: 9px 10px; border: 1px solid rgba(220,76,88,.22); border-radius: 9px; background: rgba(220,76,88,.08); color: #e76a76; font-size: 9.5px; }
.auth-notice,.auth-dev-note { margin: 0 0 12px; padding: 9px 10px; border: 1px solid color-mix(in srgb,var(--success) 28%,var(--border)); border-radius: 9px; background: color-mix(in srgb,var(--success) 9%,transparent); color: var(--text); font-size: 9.5px; line-height: 1.45; }
.auth-dev-note { border-color: color-mix(in srgb,var(--accent) 28%,var(--border)); background: var(--accent-soft); }
.auth-dev-note a { color: var(--accent); font-weight: 700; }
.auth-forgot { justify-self: end; margin-top: -4px; padding: 0; border: 0; background: transparent; color: var(--accent); font-size: 9.5px; cursor: pointer; }
.verification-code { text-align: center; font-size: 19px; font-weight: 750; font-variant-numeric: tabular-nums; }
.auth-loading { display: flex; align-items: center; gap: 11px; color: var(--muted); font-size: 11px; }
.auth-loading .brand-mark { animation: spin 1.7s linear infinite; }

progress.progress-track { width: 100%; height: 7px; display: block; appearance: none; border: 0; }
progress.progress-track::-webkit-progress-bar { border-radius: 9px; background: var(--surface-3); }
progress.progress-track::-webkit-progress-value { border-radius: 9px; background: var(--accent-gradient); transition: width .35s ease; }
progress.progress-track::-moz-progress-bar { border-radius: 9px; background: var(--accent-gradient); }

@media (max-width: 440px) {
  .auth-panel { padding: 24px 18px; }
  .auth-heading h1 { font-size: 23px; }
  .security-actions { width: 100%; justify-content: space-between; }
}

/* Stage 6: explicit subscription consent and upgrade confirmation. */
.subscription-modal { width: min(570px, 100%); padding: 0; overflow: hidden; text-align: left; }
.subscription-form { display: grid; gap: 14px; padding: 20px 22px 22px; }
.subscription-order { display: grid; grid-template-columns: 42px minmax(0, 1fr); gap: 12px; align-items: center; padding: 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); }
.subscription-order > span { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 11px; background: var(--accent-gradient); color: #fff; }
.subscription-order small,.subscription-order strong { display: block; }
.subscription-order small { color: var(--muted); font-size: 9px; }
.subscription-order strong { margin-top: 2px; font-size: 20px; }
.subscription-order p { margin: 3px 0 0; color: var(--muted); font-size: 9.5px; }
.upgrade-warning { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 10px; align-items: start; padding: 12px; border: 1px solid rgba(238, 169, 93, .28); border-radius: 10px; background: rgba(226, 169, 93, .08); color: #e2a95d; }
.upgrade-warning > span { width: 34px; height: 34px; display: grid; place-items: center; }
.upgrade-warning p { margin: 0; color: var(--text); font-size: 9.5px; }
.subscription-consent { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 9px; align-items: start; color: var(--muted); font-size: 9.5px; cursor: pointer; }
.subscription-consent input { width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }
.subscription-consent.warning { color: #e2a95d; }
.subscription-form .modal-actions { margin-top: 4px; }

@media (max-width: 440px) {
  .subscription-form { padding: 17px 16px 18px; }
  .subscription-order { grid-template-columns: 36px minmax(0, 1fr); padding: 12px; }
  .subscription-order > span { width: 36px; height: 36px; }
}

/* Stage 7: contextual generation examples. */
.field-title-line { display: flex; align-items: center; gap: 7px; }
.field-guide-button { position: relative; width: 24px; height: 24px; display: block; flex: 0 0 auto; padding: 0; border: 1px solid color-mix(in srgb, var(--accent) 32%, var(--border)); border-radius: 50%; background: var(--accent-soft); color: var(--accent); cursor: pointer; transition: transform .16s ease, border-color .16s ease, background .16s ease; }
.field-guide-button .icon { position: absolute; top: 50%; left: 50%; width: 15px; height: 15px; margin: 0; transform: translate(-50%, -50%); }
.field-guide-button:hover { transform: translateY(-1px); border-color: var(--accent); background: color-mix(in srgb, var(--accent) 18%, transparent); }
.field-guide-button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.example-guide-modal { width: min(900px, 100%); max-height: min(880px, 92vh); overflow: hidden; padding: 0; text-align: left; }
.example-guide-body { max-height: calc(92vh - 82px); overflow-y: auto; padding: 20px 22px 24px; }
.example-guide-body > p { margin: 0; color: var(--text); font-size: 12px; line-height: 1.65; }
.example-guide-media { display: grid; align-items: start; gap: 12px; margin-top: 18px; }
.example-guide-media.multiple { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.example-guide-media figure { min-width: 0; margin: 0; overflow: hidden; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.example-guide-media img { width: 100%; height: auto; max-height: 58vh; display: block; object-fit: contain; object-position: center; }
.example-guide-media figcaption { padding: 8px 10px; border-top: 1px solid var(--border); background: var(--surface-2); color: var(--muted); font-size: 9.5px; text-align: center; }

.style-choice.copy-style { display: block; overflow: visible; margin-bottom: 80px; }
.style-choice.copy-style .style-image { width: 100%; height: 100%; overflow: hidden; border-radius: inherit; }
.style-choice.copy-style .style-image > img { object-fit: contain; object-position: center; }
.style-choice.copy-style .style-caption { position: absolute; top: calc(100% + 7px); left: 0; width: 100%; min-height: 0; display: block; padding: 4px 8px 0; text-align: center; }
.style-choice.copy-style .style-caption strong { font-size: 11px; }
.style-choice.copy-style .style-caption small { font-size: 9px; }

@media (max-width: 720px) {
  .example-guide-modal { max-height: 94vh; }
  .example-guide-body { max-height: calc(94vh - 76px); padding: 17px 16px 20px; }
  .example-guide-media.multiple { grid-template-columns: 1fr; }
  .example-guide-media img { max-height: none; }
}

@media (max-width: 440px) {
  .field-title-line { align-items: flex-start; }
  .field-guide-button { width: 23px; height: 23px; }
  .style-choice.copy-style { margin-bottom: 94px; }
}

/* Cookie notice and preference controls. */
.cookie-banner { position: fixed; z-index: 140; right: 18px; bottom: 18px; left: calc(var(--sidebar) + 18px); display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; align-items: center; gap: 13px; max-width: 1080px; margin-left: auto; padding: 15px 16px; border: 1px solid var(--border); border-radius: 12px; background: color-mix(in srgb, var(--surface) 96%, transparent); box-shadow: 0 20px 55px rgba(0,0,0,.34); backdrop-filter: blur(18px); }
.cookie-banner-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; background: var(--accent-soft); color: var(--accent); }
.cookie-banner strong { display: block; font-size: 11.5px; }
.cookie-banner p { margin: 3px 0 0; color: var(--muted); font-size: 9.5px; line-height: 1.5; }
.cookie-banner a,.cookie-preferences-form a { color: var(--accent); }
.cookie-banner-actions { display: flex; align-items: center; justify-content: flex-end; gap: 4px; }
.cookie-banner-actions button { min-height: 24px; padding: 0 7px; border-radius: 6px; font-size: 7.5px; white-space: nowrap; }
.cookie-preferences-layer { position: fixed; inset: 0; z-index: 160; display: grid; place-items: center; padding: 18px; background: rgba(7,7,10,.72); backdrop-filter: blur(9px); animation: fadeIn .2s ease; }
.cookie-preferences-modal { width: min(590px, 100%); max-height: min(720px, 92dvh); overflow: auto; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); box-shadow: 0 30px 80px rgba(0,0,0,.45); }
.cookie-preferences-form { display: grid; gap: 10px; padding: 18px 22px 22px; }
.cookie-category { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; align-items: start; gap: 10px; padding: 13px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); cursor: pointer; }
.cookie-category input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--accent); }
.cookie-category strong,.cookie-category small { display: block; }
.cookie-category strong { font-size: 10.5px; }
.cookie-category small { margin-top: 3px; color: var(--muted); font-size: 9px; line-height: 1.45; }
.cookie-category em { padding: 4px 7px; border-radius: 8px; background: var(--surface-3); color: var(--muted); font-size: 8px; font-style: normal; white-space: nowrap; }
.cookie-category.locked { cursor: default; }
.cookie-preferences-form > p { margin: 2px 1px; color: var(--muted); font-size: 9px; line-height: 1.55; }
.cookie-modal-actions,.device-data-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.cookie-modal-actions { margin-top: 7px; }

@media (max-width: 920px) {
  .cookie-banner { left: 18px; grid-template-columns: 40px minmax(0, 1fr); }
  .cookie-banner-actions { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  .cookie-banner { right: 10px; bottom: 10px; left: 10px; max-height: calc(100dvh - 20px); grid-template-columns: 34px minmax(0, 1fr); gap: 10px; overflow-y: auto; padding: 13px; }
  .cookie-banner-icon { width: 34px; height: 34px; border-radius: 8px; }
  .cookie-banner-actions { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
  .cookie-banner-actions button:first-child { grid-column: 1 / -1; }
  .cookie-banner-actions button { width: 100%; padding-inline: 8px; }
  .cookie-preferences-layer { padding: 10px; }
  .cookie-preferences-modal { max-height: calc(100dvh - 20px); border-radius: 12px; }
  .cookie-preferences-form { padding: 15px 14px 16px; }
  .cookie-category { grid-template-columns: 20px minmax(0, 1fr); }
  .cookie-category em { grid-column: 2; justify-self: start; }
  .cookie-modal-actions { display: grid; grid-template-columns: 1fr; }
  .cookie-modal-actions button { width: 100%; }
  .device-data-actions { width: 100%; justify-content: space-between; }
}
