/* Phase 2.6 — mobile repair and product experience */
html, body, #app { width: 100%; max-width: 100%; }
#app { overflow-x: clip; }
#app, .app-shell, .workspace, .chat-main, .chat-layout, .settings-grid, .settings-card { min-width: 0; }
.brand-text { color: #f5f7ff; font-weight: 900; letter-spacing: .075em; }
.sidebar .brand-text { min-height: 3rem; padding: .55rem .75rem 1.55rem; }
.topbar-brand.brand-text { letter-spacing: .08em; }
.avatar-trigger { padding: 0; border: 0; border-radius: 50%; background: transparent; cursor: pointer; }
.avatar-image, .avatar-image img, .profile-avatar.has-image img, .message-avatar.has-image img { overflow: hidden; object-fit: cover; }
.avatar-image img, .profile-avatar.has-image img, .message-avatar.has-image img { width: 100%; height: 100%; }
.plan-avatar { width: 2rem; height: 2rem; flex: 0 0 2rem; display: grid; place-items: center; overflow: hidden; border-radius: .65rem; background: linear-gradient(135deg,#8d6cff,#428fff); font-size: .75rem; font-weight: 800; }

/* Home */
.hero h2 span { display: inline-block; letter-spacing: -.07em; }
.availability { position: absolute; inset: 1rem 1rem auto auto; padding: .25rem .48rem; color: #aab7da; border: 1px solid rgba(143,164,255,.14); border-radius: 999px; background: rgba(3,9,23,.48); font-size: .61rem; font-weight: 750; }
.availability.live { color: #8ff2d0; border-color: rgba(64,220,166,.2); background: rgba(34,160,120,.08); }
.home-recent { margin-top: 1.1rem; padding: 1.1rem; border: 1px solid var(--vera-line); border-radius: 1.15rem; background: linear-gradient(145deg,rgba(16,30,62,.56),rgba(6,14,32,.62)); }
.home-recent > header { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.home-recent h2 { margin: .18rem 0 0; font-size: 1.2rem; }
.home-recent > header button { display: flex; align-items: center; gap: .35rem; color: #b6c3e6; border: 0; background: transparent; cursor: pointer; font-size: .76rem; }
.recent-projects { margin-top: .9rem; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .65rem; }
.recent-project { min-width: 0; min-height: 4.5rem; padding: .72rem; display: flex; align-items: center; gap: .65rem; color: #eef2ff; border: 1px solid rgba(145,173,255,.11); border-radius: .85rem; background: rgba(255,255,255,.025); text-align: start; cursor: pointer; }
.recent-project > span { width: 2rem; height: 2rem; flex: 0 0 2rem; display: grid; place-items: center; border-radius: .62rem; color: #c9d3ff; background: rgba(110,91,255,.14); }
.recent-project div { min-width: 0; flex: 1; }.recent-project strong,.recent-project small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.recent-project small { margin-top: .15rem; color: #8d9abc; font-size: .68rem; }.recent-project > .icon { width: .9rem; color: #8190b5; }
.recent-empty { margin-top: .9rem; min-height: 4.6rem; padding: .8rem; display: flex; align-items: center; gap: .75rem; border: 1px dashed rgba(145,173,255,.15); border-radius: .85rem; color: #9ca9c8; }.recent-empty > .icon { width: 1.5rem; }.recent-empty strong { display: block; color: #dfe6ff; font-size: .82rem; }.recent-empty p { margin: .15rem 0 0; font-size: .72rem; }

/* Avatar and settings */
.settings-grid { align-items: start; }
.settings-card { width: 100%; overflow: hidden; }
.profile-card { grid-row: span 2; }
.profile-summary { display: flex; align-items: center; gap: .85rem; min-width: 0; }
.profile-summary > div { min-width: 0; }.profile-summary h3,.profile-summary p { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.profile-summary h3 { margin: 0; }.profile-summary p { margin: .15rem 0 0; color: #95a3c4; font-size: .78rem; }
.profile-avatar { width: 4.6rem; height: 4.6rem; flex: 0 0 4.6rem; display: grid; place-items: center; overflow: hidden; border: 1px solid rgba(157,171,255,.24); border-radius: 1.35rem; background: linear-gradient(145deg,#8966ff,#3f91ff); box-shadow: 0 12px 32px rgba(68,88,255,.22); font-size: 1.25rem; font-weight: 850; }
.avatar-actions { margin-top: 1rem; display: flex; align-items: center; flex-wrap: wrap; gap: .6rem; }
.avatar-actions input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.text-danger { min-height: 2.65rem; padding: .55rem .75rem; color: #ffafbd; border: 0; background: transparent; cursor: pointer; }
.field-hint { margin: .55rem 0 1rem !important; color: #7f8eaf !important; font-size: .7rem !important; }
.profile-form { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: end; gap: .65rem; }
.profile-form label,.settings-field { min-width: 0; display: grid; gap: .38rem; color: #aab5d1; font-size: .72rem; }
.profile-form input,.settings-field select { width: 100%; min-width: 0; min-height: 2.8rem; padding: .65rem .75rem; color: #f3f6ff; border: 1px solid var(--vera-line); border-radius: .75rem; outline: 0; background: rgba(4,11,27,.52); }
.settings-field { margin-top: 1rem; }.settings-field .locale-select { display: block; max-width: 100%; }
.settings-card-icon { width: 2.45rem; height: 2.45rem; margin-bottom: 1rem; display: grid; place-items: center; border-radius: .78rem; color: #d7deff; background: rgba(100,85,255,.15); }
.account-card .secondary-button { margin-top: .4rem; }

/* Release 68 — quiet settings hierarchy and account menu. */
.settings-page{width:min(100%,46rem);margin:0 auto;padding:.5rem 0 2rem}.settings-root-head h2,.settings-subpage h2{margin:0;color:#f4f6ff;font-size:1.45rem}.settings-account-row,.settings-row{width:100%;border:0;color:#eef2ff;text-align:start;cursor:pointer}.settings-account-row{margin:1rem 0 1.25rem;padding:.8rem;display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:.75rem;align-items:center;border:1px solid var(--vera-line);border-radius:1rem;background:rgba(13,24,52,.65)}.settings-account-row .profile-avatar{width:2.7rem;height:2.7rem;flex-basis:2.7rem;border-radius:.85rem;box-shadow:none;font-size:.9rem}.settings-account-row span,.settings-row span{min-width:0}.settings-account-row strong,.settings-account-row small,.settings-row strong,.settings-row small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.settings-account-row small,.settings-row small{margin-top:.14rem;color:#91a1c8;font-size:.78rem}.settings-account-row em,.settings-row em{font-style:normal;color:#93a5d5;font-size:1.3rem}.settings-groups{display:grid;gap:1rem}.settings-groups section{overflow:hidden;border:1px solid var(--vera-line);border-radius:1rem;background:rgba(10,20,45,.52)}.settings-groups section>p{margin:.68rem .85rem .35rem;color:#8999c2;font-size:.67rem;font-weight:800;letter-spacing:.09em}.settings-row{min-height:3.7rem;padding:.62rem .82rem;display:grid;grid-template-columns:2rem minmax(0,1fr) auto;gap:.7rem;align-items:center;background:transparent}.settings-row+.settings-row{border-top:1px solid rgba(140,161,236,.1)}.settings-row-icon{width:2rem;height:2rem;display:grid;place-items:center;border-radius:.65rem;color:#bfcbff;background:rgba(102,87,255,.14)}.settings-row-icon .icon{width:1rem}.settings-subpage>header{display:flex;align-items:center;gap:.65rem;margin-bottom:1rem}.settings-back{width:2.5rem;height:2.5rem;border:1px solid var(--vera-line);border-radius:.75rem;color:#e9eeff;background:rgba(255,255,255,.035);font-size:1.7rem;cursor:pointer}.settings-profile-editor,.settings-language-editor{padding:1rem;border:1px solid var(--vera-line);border-radius:1rem;background:rgba(10,20,45,.58)}.settings-language-editor .settings-field{margin:0}.account-menu-backdrop{position:fixed;z-index:150;inset:0;background:rgba(1,6,18,.5)}.account-menu{position:absolute;top:calc(var(--topbar-height) - .3rem);right:1rem;width:min(22rem,calc(100vw - 2rem));padding:.75rem;border:1px solid rgba(142,163,255,.28);border-radius:1rem;background:linear-gradient(145deg,#101e45,#080f26);box-shadow:0 1.5rem 4rem rgba(0,0,0,.4)}.account-menu header{display:flex;gap:.7rem;align-items:center;padding:.35rem}.account-menu-avatar{width:2.7rem;height:2.7rem;display:grid;place-items:center;overflow:hidden;border-radius:.85rem;background:linear-gradient(145deg,#8966ff,#3f91ff);font-weight:800}.account-menu-avatar img{width:100%;height:100%;object-fit:cover}.account-menu header strong,.account-menu header small{display:block}.account-menu header small{margin-top:.12rem;color:#9cacca;font-size:.76rem}.account-menu-balance{margin:.7rem 0;padding:.7rem;border-block:1px solid rgba(148,166,239,.14)}.account-menu-balance span,.account-menu-balance strong{display:block}.account-menu-balance span{color:#98a9d0;font-size:.74rem}.account-menu-balance strong{margin-top:.12rem;color:#f2f4ff}.account-menu nav{display:grid}.account-menu nav button,.account-menu-signout{min-height:2.6rem;padding:.45rem .5rem;color:#e8edff;border:0;border-radius:.65rem;background:transparent;text-align:start;cursor:pointer}.account-menu nav button:hover{background:rgba(115,101,255,.14)}.account-menu-signout{width:100%;margin-top:.55rem;border-top:1px solid rgba(255,160,175,.16);border-radius:0;color:#ffb3bd}.logout-confirm{position:absolute;top:50%;left:50%;width:min(23rem,calc(100vw - 2rem));padding:1rem;border:1px solid rgba(142,163,255,.3);border-radius:1rem;background:#0d1836;transform:translate(-50%,-50%)}.logout-confirm h2{margin:0 0 1rem;font-size:1.05rem}.logout-confirm div{display:flex;justify-content:flex-end;gap:.6rem}.logout-confirm .text-danger{display:inline-flex;align-items:center;text-decoration:none}
@media(max-width:47.99rem){.route-settings{overflow-x:clip}.route-settings>.sidebar,.route-settings>.context-panel{display:none!important}.settings-page{padding-bottom:calc(var(--mobile-nav-reserve,5rem) + .75rem)}.account-menu{top:auto;right:.55rem;bottom:calc(var(--mobile-nav-reserve,5rem) + env(safe-area-inset-bottom));left:.55rem;width:auto;max-height:calc(100dvh - var(--mobile-nav-reserve,5rem) - 1rem);overflow:auto;border-radius:1.2rem}.account-menu-backdrop{backdrop-filter:blur(5px)}}

/* Rewards notification menu: real interaction with an explicit empty state until
   a server-side notification feed exists. */
.notifications-backdrop{position:fixed;z-index:150;inset:0;background:rgba(1,6,18,.5)}.notifications-menu{position:absolute;top:calc(var(--topbar-height) - .3rem);right:8.4rem;width:min(21rem,calc(100vw - 2rem));padding:1rem;border:1px solid rgba(142,163,255,.28);border-radius:1rem;background:linear-gradient(145deg,#101e45,#080f26);box-shadow:0 1.5rem 4rem rgba(0,0,0,.4)}.notifications-menu header{display:flex;align-items:center;gap:.65rem}.notifications-menu header>span,.notifications-empty>span{display:grid;place-items:center;border:1px solid rgba(137,126,255,.4);border-radius:.7rem;color:#d9d2ff;background:linear-gradient(135deg,rgba(114,75,255,.7),rgba(38,126,244,.55))}.notifications-menu header>span{width:2.3rem;height:2.3rem}.notifications-menu .icon{width:1.05rem}.notifications-menu h2,.notifications-menu p{margin:0}.notifications-menu h2{color:#f1f4ff;font-size:.95rem}.notifications-menu header p,.notifications-empty p{margin-top:.15rem;color:#93a5c5;font-size:.68rem;line-height:1.45}.notifications-empty{display:grid;justify-items:center;gap:.5rem;margin-top:.85rem;padding:1.35rem .85rem;border:1px dashed rgba(124,151,204,.34);border-radius:.8rem;background:radial-gradient(circle at 50% 0,rgba(91,70,224,.18),transparent 64%);text-align:center}.notifications-empty>span{width:2.7rem;height:2.7rem}.notifications-empty strong{color:#e7edff;font-size:.78rem}
@media(max-width:47.99rem){.notifications-menu{top:auto;right:.55rem;bottom:calc(var(--mobile-nav-reserve,5rem) + env(safe-area-inset-bottom));left:.55rem;width:auto;max-height:calc(100dvh - var(--mobile-nav-reserve,5rem) - 1rem);overflow:auto;border-radius:1.2rem}.notifications-backdrop{backdrop-filter:blur(5px)}}

/* Chat history drawer and attachments */
.history-trigger,.chat-new-mobile { display: none; }
.history-mobile-head,.history-backdrop { display: none; }
.composer-attachments { min-width: 0; }
.attachment-chip { max-width: 100%; }.attachment-chip > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.attachment-warning { margin: .35rem .2rem 0; padding: .48rem .58rem; color: #ffd59b; border: 1px solid rgba(255,187,92,.18); border-radius: .55rem; background: rgba(255,175,65,.065); font-size: .7rem; line-height: 1.35; }
.composer-input .primary-button:disabled { opacity: .42; cursor: not-allowed; }

/* Create sheet */
.sheet-backdrop { position: fixed; z-index: calc(var(--z-modal, 100) + 2); inset: 0; padding: 1rem; display: grid; place-items: end center; background: rgba(1,5,15,.68); backdrop-filter: blur(12px); }
.create-sheet { width: min(100%, 34rem); padding: 1rem; border: 1px solid rgba(145,159,255,.23); border-radius: 1.35rem; background: linear-gradient(160deg,#111c3b,#071126 78%); box-shadow: 0 26px 80px rgba(0,0,0,.56); }
.create-sheet header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }.create-sheet h2 { margin: .25rem 0 0; font-size: 1.3rem; }.sheet-close,.history-mobile-head button { width: 2.55rem; height: 2.55rem; flex: 0 0 auto; border: 1px solid var(--vera-line); border-radius: .8rem; background: rgba(255,255,255,.04); cursor: pointer; font-size: 1.3rem; }
.create-grid { margin-top: 1rem; display: grid; gap: .55rem; }.create-option { width: 100%; min-width: 0; min-height: 4.3rem; padding: .7rem .78rem; display: grid; grid-template-columns: 2.55rem minmax(0,1fr) auto; align-items: center; gap: .7rem; color: #edf1ff; border: 1px solid rgba(145,173,255,.12); border-radius: .9rem; background: rgba(255,255,255,.027); text-align: start; cursor: pointer; }.create-option > span { width: 2.55rem; height: 2.55rem; display: grid; place-items: center; border-radius: .75rem; color: #dce3ff; background: linear-gradient(145deg,rgba(133,101,255,.27),rgba(57,143,255,.13)); }.create-option div { min-width: 0; }.create-option strong,.create-option small { display: block; }.create-option small { margin-top: .15rem; color: #8f9dbe; font-size: .7rem; }.create-option > .icon { width: .9rem; color: #7f8eb2; }

@media (min-width: 48rem) {
  .sidebar .brand-text { justify-content: center; padding-inline: 0; font-size: .7rem; }
}
@media (min-width: 72rem) {
  .sidebar .brand-text { justify-content: flex-start; padding-inline: .7rem; font-size: 1.18rem; }
  .settings-grid { grid-template-columns: 1.25fr .75fr; }
  .sheet-backdrop { place-items: center; }
}

@media (max-width: 47.99rem) {
  :root { --mobile-gutter: clamp(.78rem, 3.6vw, 1rem); }
  .app-shell { width: 100%; max-width: 100%; }
  .sidebar,.context-panel { display: none !important; }
  .topbar { width: 100%; gap: .55rem; }
  .topbar-brand.brand-text { flex: 1; font-size: 1rem; }
  .topbar-actions { flex: 0 0 auto; }
  .avatar-button { width: 2.5rem; min-width: 2.5rem; }
  .workspace { width: 100%; max-width: 100%; padding-inline: max(var(--mobile-gutter),var(--safe-left)); }
  .hero { min-height: 0; padding: 2rem .9rem 1rem; }
  .hero::before { background: radial-gradient(19rem 15rem at 78% 4%,rgba(104,113,255,.35),transparent 58%),radial-gradient(18rem 14rem at 18% 100%,rgba(122,64,255,.21),transparent 64%),linear-gradient(to top,rgba(2,7,17,.62),transparent 54%); }
  .hero-copy { width: 100%; }
  .hero .eyebrow { font-size: .64rem; }.hero h2 { margin: .35rem 0 .4rem; font-size: clamp(2.45rem,14vw,3.75rem); line-height: .98; }.hero-description { max-width: 20rem; font-size: .85rem; line-height: 1.48; }
  .prompt-bar { width: 100%; margin-top: 1.15rem; }.prompt-bar-footer { min-width: 0; }.prompt-project { flex: 1; max-width: none; }
  .home-suggestions { width: 100%; margin-top: .75rem; padding-bottom: .2rem; scroll-snap-type: x proximity; }.home-suggestions button { flex: 0 0 auto; scroll-snap-align: start; }
  .home-products { margin-top: 1.1rem; }.home-section-head { margin-top: 0; }.home-section-head h2 { max-width: 17rem; }
  .tool-grid--products { grid-template-columns: repeat(2,minmax(0,1fr)); width: 100%; }.tool-card { width: 100%; min-width: 0; min-height: 10.8rem; }.tool-card:first-child { grid-column: 1/-1; min-height: 8.8rem; }.tool-card:first-child p { display: block; max-width: 13rem; }.availability { inset: .75rem .75rem auto auto; }
  .home-recent { padding: .9rem; }.home-recent > header { align-items: center; }.recent-projects { grid-template-columns: 1fr; }.recent-project { width: 100%; }.recent-projects .recent-project:nth-child(n+3) { display: none; }
  .settings-heading { margin-top: .35rem; }.settings-grid { grid-template-columns: minmax(0,1fr); width: 100%; padding-bottom: .5rem; }.settings-card { padding: 1rem; border-radius: 1rem; }.profile-summary { align-items: flex-start; }.profile-avatar { width: 4rem; height: 4rem; flex-basis: 4rem; border-radius: 1.15rem; }.avatar-actions { align-items: stretch; }.avatar-actions .secondary-button { max-width: 100%; }.profile-form { grid-template-columns: minmax(0,1fr); }.profile-form .primary-button { width: 100%; }.setting-row { min-width: 0; flex-wrap: wrap; }.setting-row > * { max-width: 100%; min-width: 0; }
  .bottom-nav { width: 100%; grid-template-columns: repeat(5,minmax(0,1fr)); padding-inline: max(.4rem,var(--safe-left)); gap: .1rem; }.bottom-nav .nav-link { width: 100%; min-width: 0; }.bottom-nav .nav-create { margin: 0; box-shadow: 0 6px 14px rgba(75,88,255,.22); }.bottom-nav .nav-label { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
  .workspace-chat { width: 100%; max-width: 100%; }
  .chat-layout { width: 100%; max-width: 100%; overflow: hidden; }.chat-main { width: 100%; max-width: 100%; }
  .history-trigger,.chat-new-mobile { width: 2.45rem; height: 2.45rem; flex: 0 0 2.45rem; padding: 0; display: grid; place-items: center; border: 1px solid var(--vera-line); border-radius: .72rem; background: rgba(255,255,255,.035); }
  .chat-header { display: grid; grid-template-columns: auto minmax(0,1fr) auto; gap: .65rem; }.chat-header > div { min-width: 0; }.chat-header h2,.chat-header p { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .chat-history { position: fixed; z-index: calc(var(--z-modal,100) + 1); inset: 0 auto 0 0; width: min(88vw,21rem); max-width: calc(100% - 2.4rem); padding: max(1rem,var(--safe-top)) .8rem max(1rem,var(--safe-bottom)); display: block; overflow-y: auto; border-right: 1px solid rgba(145,173,255,.2); background: rgba(5,13,31,.98); box-shadow: 25px 0 70px rgba(0,0,0,.48); transform: translateX(-105%); visibility: hidden; transition: transform .22s var(--ease),visibility .22s; }
  [dir="rtl"] .chat-history { inset: 0 0 0 auto; transform: translateX(105%); border-right: 0; border-left: 1px solid rgba(145,173,255,.2); }
  .history-open .chat-history { transform: translateX(0); visibility: visible; }.history-backdrop { position: fixed; z-index: var(--z-modal,100); inset: 0; width: 100%; border: 0; background: rgba(1,4,13,.66); }.history-open .history-backdrop { display: block; }.history-mobile-head { margin-bottom: .8rem; display: flex; align-items: center; justify-content: space-between; }.chat-history > h3 { display: none; }
  .messages { width: 100%; }.message { width: 100%; max-width: 100%; }.message-content,.message-bubble { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }.message-avatar.has-image { overflow: hidden; }
  .chat-welcome { min-height: 100%; padding: 1rem .25rem 5.25rem; }.chat-welcome h3 { max-width: 18rem; font-size: 1.6rem; }.chat-welcome .eyebrow { color: #aebaff; }.chat-suggestions { max-width: 100%; }
  .chat-composer { width: auto; max-width: none; min-width: 0; margin-inline: max(.55rem,var(--safe-left)) max(.55rem,var(--safe-right)); }.composer-tools { min-width: 0; }.composer-tools select { min-width: 0; max-width: calc(100% - 2.8rem); }.composer-input { min-width: 0; }.composer-input textarea { min-width: 0; width: 100%; }.composer-attachments { width: 100%; overflow-x: auto; }.attachment-picker { width: 100%; max-height: min(19rem,46vh); grid-template-columns: minmax(0,1fr); overflow-y: auto; }.attachment-picker > div { min-width: 0; flex-wrap: wrap; }.attachment-picker > button { width: 100%; }
  .library-heading { display: grid; grid-template-columns: minmax(0,1fr) auto; }.library-heading > div { min-width: 0; }.library-heading h2,.library-heading p { overflow-wrap: anywhere; }.library-toolbar,.library-categories,.asset-grid,.asset-card { min-width: 0; max-width: 100%; }.asset-card { grid-template-columns: auto minmax(0,1fr) auto; }.asset-card > div { min-width: 0; }.asset-card h3,.asset-card p { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .sheet-backdrop { padding: .65rem max(.55rem,var(--safe-right)) max(.55rem,calc(.55rem + var(--safe-bottom))) max(.55rem,var(--safe-left)); }.create-sheet { max-height: calc(100dvh - 1.2rem - var(--safe-top) - var(--safe-bottom)); overflow-y: auto; border-radius: 1.3rem; }
}

/* Full-viewport Chat workspace — local scroll ownership only. */
.route-chat,.route-chat .workspace-chat,.route-chat .chat-layout,.route-chat .chat-main,.route-chat .messages { width:100%; max-width:100%; min-width:0; box-sizing:border-box; }
.route-chat .workspace-chat { margin:0; padding:0; }
.route-chat .chat-layout { grid-template-columns:minmax(13.5rem,15.5rem) minmax(0,1fr); overflow:hidden; }
.route-chat .chat-header { min-width:0; min-height:4.65rem; padding-inline:clamp(1rem,3vw,3rem); }
.route-chat .messages { min-width:0; padding:clamp(1.25rem,2.8vw,2.5rem) clamp(1rem,4vw,4.5rem); scroll-behavior:smooth; overflow-x:hidden; }
.route-chat .message { width:min(100%,78rem); max-width:100%; min-width:0; }
.route-chat .message.user { width:min(100%,70rem); max-width:100%; }
.route-chat .chat-composer { width:min(calc(100% - 2rem),78rem); max-width:calc(100% - 2rem); min-width:0; box-sizing:border-box; }
.route-chat .chat-latest { position: absolute; z-index: var(--z-composer); inset: auto 1.35rem 6.4rem auto; display: none; min-height: 2.4rem; padding: .45rem .75rem; color: #eff4ff; border: 1px solid rgba(142,164,255,.34); border-radius: 999px; background: rgba(10,25,57,.95); box-shadow: 0 12px 28px rgba(0,0,0,.28); cursor: pointer; }
.route-chat .chat-latest.is-visible { display: inline-flex; align-items: center; }
.route-chat .chat-latest:focus-visible { outline: 2px solid #80b5ff; outline-offset: 3px; }
.route-chat .chat-latest { width:2.3rem; min-width:2.3rem; min-height:2.3rem; height:2.3rem; padding:0; display:none; place-items:center; font-size:1.2rem; line-height:1; }
.route-chat .chat-latest.is-visible { display:grid; }
.route-chat .composer-tools { min-height:2.4rem; padding:.05rem .15rem .35rem; gap:.4rem; }
.route-chat .composer-model-label { font-size:.62rem; }
.route-chat .composer-tools select { width:clamp(7.5rem,18vw,10.5rem); min-height:2.25rem; height:2.25rem; padding:.25rem .55rem; font-size:.78rem; }
.route-chat .composer-icon { width:2.25rem; min-width:2.25rem; min-height:2.25rem; height:2.25rem; padding:0; }
.route-chat .chat-main { position: relative; }
.route-chat .message-bubble { font-size: 1rem; line-height: 1.72; }
.route-chat .message-bubble,.route-chat .message-content,.route-chat .tool-card { min-width:0; max-width:100%; overflow-wrap:anywhere; }
.route-chat .message-bubble table,.route-chat .message-bubble pre,.route-chat .message-bubble .code-block { display:block; max-width:100%; overflow-x:auto; }
@media (max-width:71.99rem) and (min-width:48rem) { .route-chat .chat-layout { grid-template-columns:minmax(0,1fr); }.route-chat .history-trigger { width:2.45rem; height:2.45rem; flex:0 0 2.45rem; padding:0; display:grid; place-items:center; border:1px solid var(--vera-line); border-radius:.72rem; background:rgba(255,255,255,.035); }.route-chat .chat-history { position:fixed; z-index:var(--z-drawer); inset:0 auto 0 0; width:min(22rem,88vw); max-width:calc(100% - 2.4rem); overflow-y:auto; transform:translateX(-105%); visibility:hidden; }.route-chat .history-open .chat-history { transform:translateX(0); visibility:visible; }.route-chat .history-backdrop { position:fixed; z-index:calc(var(--z-drawer) - 1); inset:0; width:100%; border:0; background:rgba(1,4,13,.66); }.route-chat .history-open .history-backdrop { display:block; }.route-chat .history-mobile-head { display:flex; align-items:center; justify-content:space-between; }.route-chat .chat-history > h3 { display:none; }.route-chat .chat-composer { width:min(calc(100% - 2.5rem),72rem); } }
@media (max-width:47.99rem) { .route-chat .chat-layout { grid-template-columns:minmax(0,1fr); }.route-chat .chat-header { min-height:3.85rem; padding-block:.55rem; }.route-chat .chat-header .chat-kicker { display:none; }.route-chat .chat-header p:last-child { display:none; }.route-chat .messages { padding:.85rem max(.55rem,var(--safe-right)) .35rem max(.55rem,var(--safe-left)); }.route-chat .message,.route-chat .message.user { width:100%; margin-bottom:1rem; }.route-chat .message-bubble { padding:.8rem .86rem; font-size:.94rem; line-height:1.64; }.route-chat .chat-composer { width:auto; max-width:none; margin-inline:max(.5rem,var(--safe-left)) max(.5rem,var(--safe-right)); }.route-chat .composer-model-label { display:none; }.route-chat .composer-tools { min-height:2.2rem; padding-bottom:.25rem; }.route-chat .composer-tools select { width:min(8rem,calc(100% - 2.65rem)); min-height:2.15rem; height:2.15rem; }.route-chat .composer-icon { width:2.15rem; min-width:2.15rem; min-height:2.15rem; height:2.15rem; }.route-chat .chat-latest { inset:auto max(.7rem,var(--safe-right)) 5.65rem auto; }.route-chat .messages { scroll-behavior:auto; } }
@media (max-width:47.99rem) { .route-chat .workspace-chat,.route-chat .chat-layout,.route-chat .chat-main { width:100%!important; max-width:100%!important; min-width:0!important; }.route-chat .chat-layout { grid-template-columns:minmax(0,1fr)!important; }.route-chat .chat-history { position:fixed!important; width:min(88vw,21rem)!important; }.route-chat .chat-main { grid-column:1!important; } }
@media (max-width: 22.5rem) {
  .hero { padding-inline: .72rem; }.hero h2 { font-size: 2.55rem; }.hero-description { font-size: .8rem; }.tool-card { min-height: 9.8rem; padding: .78rem; }.bottom-nav .nav-link { padding-inline: .05rem; }.bottom-nav .nav-label { font-size: .54rem; }.chat-header { gap: .45rem; }.chat-header h2 { font-size: .85rem; }
}
@media (prefers-reduced-motion: reduce) { .chat-history { transition: none; } }

/* Phase 2.6.1 — durable mobile chat viewport geometry */
@media (max-width: 47.99rem) {
  :root { --mobile-nav-reserve: calc(4.65rem + var(--safe-bottom)); }
  .route-chat {
    height: var(--visual-height, 100dvh);
    min-height: 0;
    padding-bottom: var(--mobile-nav-reserve);
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .route-chat > .topbar { flex: 0 0 auto; }
  .route-chat > .workspace-chat {
    width: 100%;
    height: auto;
    min-height: 0;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .workspace-chat > .network-banner {
    margin: .55rem max(.7rem,var(--safe-right)) 0 max(.7rem,var(--safe-left));
    flex: 0 0 auto;
  }
  .workspace-chat > .chat-layout {
    height: auto;
    min-height: 0;
    flex: 1 1 auto;
  }
  .chat-main { min-height: 0; overflow: hidden; }
  .messages {
    min-height: 0;
    overflow-y: auto;
    scroll-padding-block-end: .75rem;
    overscroll-behavior: contain;
  }
  .chat-composer {
    position: relative;
    z-index: var(--z-composer);
    margin-top: .45rem;
    margin-bottom: .65rem;
    max-height: min(46dvh, 24rem);
    overflow-y: auto;
    flex: 0 0 auto;
  }
  .composer-tools select { min-height: 2.75rem; height: 2.75rem; }
  .composer-icon,
  .composer-input .primary-button,
  .stop-button {
    width: 2.75rem;
    min-width: 2.75rem;
    min-height: 2.75rem;
    height: 2.75rem;
    touch-action: manipulation;
  }
  .composer-input textarea { max-height: min(9rem, 24dvh); }
  .attachment-picker { max-height: min(15rem, 32dvh); }
  .bottom-nav { z-index: var(--z-bottom-nav); }
  .chat-history { z-index: var(--z-drawer); }
  .history-backdrop { z-index: calc(var(--z-drawer) - 1); }
  .sheet-backdrop { z-index: var(--z-modal); }
  .keyboard-open { --mobile-nav-reserve: 0px; }
  .keyboard-open .route-chat > .bottom-nav { display: none; }
  .keyboard-open .route-chat .chat-composer { margin-bottom: max(.4rem,var(--safe-bottom)); }
}

/* Vera Image production studio */
.image-studio{max-width:1480px;margin:0 auto;padding:1.4rem}.image-studio-head{display:flex;align-items:end;justify-content:space-between;gap:1rem;margin-bottom:1rem}.image-studio-head h2{font-size:clamp(1.8rem,3vw,2.7rem);margin:.2rem 0}.image-provider-state{padding:.45rem .7rem;border:1px solid rgba(97,151,255,.35);border-radius:999px;color:#bcd6ff;background:rgba(39,91,184,.12)}.image-studio-grid{display:grid;grid-template-columns:minmax(18rem,25rem) minmax(0,1fr);gap:1rem}.image-controls,.image-workspace{border:1px solid rgba(135,160,255,.18);border-radius:1.25rem;background:linear-gradient(145deg,rgba(13,27,59,.9),rgba(5,12,29,.94));box-shadow:inset 0 1px rgba(255,255,255,.04);padding:1rem}.image-controls{display:grid;gap:1rem;align-content:start}.image-controls label,.image-controls fieldset{display:grid;gap:.45rem}.image-controls fieldset{border:0;margin:0;padding:0}.image-controls textarea{min-height:9rem;resize:vertical}.image-controls textarea,.image-controls select{width:100%;border:1px solid rgba(141,164,237,.22);border-radius:.8rem;background:#09142d;color:#f7f9ff;padding:.75rem}.image-control-row{display:grid;grid-template-columns:1fr 1fr;gap:.65rem}.image-upload{min-height:3rem;display:flex!important;place-items:center;align-items:center;justify-content:center;border:1px dashed rgba(120,151,255,.4);border-radius:.8rem;cursor:pointer}.image-upload input{position:absolute;opacity:0;pointer-events:none}.segmented{display:flex;gap:.4rem;flex-wrap:wrap}.segmented input{position:absolute;opacity:0}.segmented span{display:block;padding:.55rem .75rem;border:1px solid rgba(133,156,233,.2);border-radius:.7rem;cursor:pointer}.segmented input:checked+span{border-color:#7b79ff;background:rgba(99,86,255,.22)}.image-generate{min-height:3.25rem}.image-workspace{min-height:40rem}.image-empty{min-height:23rem;display:grid;place-items:center;align-content:center;text-align:center;color:#9eacd2}.image-empty .icon{width:3rem}.image-result>img{display:block;width:100%;max-height:62vh;object-fit:contain;border-radius:1rem;background:#030816}.image-result-actions{display:flex;gap:.5rem;flex-wrap:wrap;margin:.7rem 0 1.2rem}.image-history{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.7rem}.image-history-card{min-width:0;padding:.55rem;border:1px solid rgba(135,160,255,.14);border-radius:.9rem;background:rgba(7,16,38,.72)}.image-history-card img,.image-state{width:100%;aspect-ratio:1/1;object-fit:cover;border-radius:.65rem;background:#060d20}.image-state{display:grid;place-items:center;color:#8292bd}.image-history-card strong,.image-history-card small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-top:.4rem}.image-history-card small{color:#8898bf}.image-error{color:#ffb4bf}.image-controls :focus-visible,.image-result-actions :focus-visible{outline:2px solid #77a8ff;outline-offset:2px}
@media(max-width:900px){.image-studio{padding:.75rem .75rem calc(var(--mobile-nav-height,5.6rem) + env(safe-area-inset-bottom) + 1rem)}.image-studio-head{align-items:start}.image-studio-grid{grid-template-columns:1fr}.image-workspace{min-height:24rem}.image-history{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:430px){.image-studio{padding-inline:.55rem}.image-studio-head{display:block}.image-provider-state{display:inline-block;margin-top:.5rem}.image-control-row{grid-template-columns:1fr}.image-history{grid-template-columns:1fr 1fr}.image-result-actions>*{flex:1;min-width:7rem}.image-controls,.image-workspace{border-radius:1rem;padding:.8rem}}

/* Phase 3.1 — typed Vera Image blocks inside Vera Chat */
.chat-image-card{width:min(100%,36rem);margin-top:.9rem;overflow:hidden;border:1px solid rgba(115,151,255,.24);border-radius:1rem;background:linear-gradient(145deg,rgba(14,28,61,.96),rgba(5,13,31,.98));box-shadow:0 18px 46px rgba(0,0,0,.24)}
.chat-image-card>header{padding:.72rem .78rem;display:flex;align-items:center;gap:.62rem;border-bottom:1px solid rgba(132,156,235,.13)}
.chat-image-card>header>span{width:2.3rem;height:2.3rem;display:grid;place-items:center;flex:0 0 auto;color:#dfe7ff;border-radius:.7rem;background:linear-gradient(145deg,rgba(130,83,255,.35),rgba(40,145,255,.2))}
.chat-image-card>header .icon{width:1.15rem}.chat-image-card>header strong,.chat-image-card>header small{display:block}.chat-image-card>header small{margin-top:.08rem;color:#91a3cb;font-size:.72rem}
.chat-image-preview{width:100%;padding:0;display:block;border:0;background:#030817;cursor:zoom-in}.chat-image-preview img{width:100%;max-height:32rem;aspect-ratio:1/1;display:block;object-fit:contain}
.chat-image-actions{padding:.65rem;display:flex;flex-wrap:wrap;gap:.42rem}.chat-image-actions a,.chat-image-actions button{min-height:2.55rem;padding:.5rem .7rem;display:inline-flex;align-items:center;justify-content:center;color:#dce5ff;border:1px solid rgba(137,160,239,.2);border-radius:.68rem;background:rgba(255,255,255,.035);font:inherit;font-size:.73rem;text-decoration:none;cursor:pointer}
.chat-image-actions a:hover,.chat-image-actions button:hover{border-color:rgba(117,147,255,.48);background:rgba(104,92,255,.13)}
.tool-progress{height:.22rem;margin:.15rem .75rem .75rem;overflow:hidden;border-radius:999px;background:rgba(126,153,239,.12)}.tool-progress i{width:45%;height:100%;display:block;border-radius:inherit;background:linear-gradient(90deg,#7967ff,#3ebeff);animation:tool-progress 1.25s ease-in-out infinite alternate}.chat-image-card.failed{border-color:rgba(255,112,139,.25)}
@keyframes tool-progress{from{transform:translateX(-25%)}to{transform:translateX(145%)}}
@media(max-width:47.99rem){.chat-image-card{width:100%;max-width:100%;border-radius:.85rem}.chat-image-preview img{max-height:70vw}.chat-image-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.chat-image-actions>*{width:100%;min-width:0}.message:has(.chat-image-card) .message-bubble{padding:.72rem}.message:has(.chat-image-card) .message-content{max-width:calc(100vw - 3.3rem - var(--safe-left) - var(--safe-right))}}
@media(prefers-reduced-motion:reduce){.tool-progress i{animation:none;width:100%}}

/* Phase 3.2 — usage and cost controls */
.credits-page,.credit-admin{width:min(100%,72rem);margin:0 auto;padding:1.4rem}.credits-page>header h2,.credit-admin>header h2{margin:.25rem 0;font-size:clamp(1.7rem,3vw,2.5rem)}.credit-balance{margin-top:1.2rem;padding:1.2rem;border:1px solid rgba(128,155,244,.2);border-radius:1.15rem;background:linear-gradient(145deg,rgba(18,32,69,.92),rgba(7,15,35,.94))}.credit-balance>strong{display:block;font-size:clamp(1.7rem,4vw,2.6rem)}.credit-balance>span,.credit-balance>small{color:#98a8ce}.credit-balance>div{height:.5rem;margin:.9rem 0 .55rem;overflow:hidden;border-radius:999px;background:rgba(255,255,255,.07)}.credit-balance i{height:100%;display:block;border-radius:inherit;background:linear-gradient(90deg,#785dff,#39baff)}.usage-metrics,.admin-summary{margin-top:.8rem;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.7rem}.usage-metrics article,.admin-summary article,.admin-config-card,.credit-ledger{padding:1rem;border:1px solid rgba(128,155,244,.16);border-radius:1rem;background:rgba(8,18,42,.76)}.usage-metrics span,.usage-metrics small,.admin-summary span{display:block;color:#92a2c8}.usage-metrics strong,.admin-summary strong{display:block;margin:.25rem 0;font-size:1.35rem}.credit-ledger{margin-top:.8rem}.credit-ledger ul{margin:0;padding:0;list-style:none}.credit-ledger li{padding:.7rem 0;display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:.8rem;border-bottom:1px solid rgba(129,151,225,.1)}.credit-ledger li:last-child{border:0}.credit-ledger small{color:#8494b9}.credit-ledger .credit{color:#72e2bd}.credit-ledger .debit{color:#ffb28c}.credit-admin{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.8rem}.credit-admin>header,.credit-admin>.admin-summary{grid-column:1/-1}.admin-config-card{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-content:start;gap:.65rem}.admin-config-card h3{grid-column:1/-1}.admin-config-card label{display:grid;gap:.3rem;color:#a9b5d3;font-size:.76rem}.admin-config-card input,.admin-config-card select{width:100%;min-height:2.7rem;padding:.55rem .65rem;color:#f3f6ff;border:1px solid rgba(138,160,235,.2);border-radius:.7rem;background:#09142d}.admin-config-card>input[name=reason],.admin-config-card>.primary-button{grid-column:1/-1}.tool-toggle{min-height:2.7rem;color:#e8edff;border:1px solid rgba(132,156,237,.2);border-radius:.7rem;background:rgba(255,255,255,.035);cursor:pointer}.tool-toggle.on{border-color:rgba(80,211,174,.35);background:rgba(45,175,138,.1)}
@media(max-width:47.99rem){.credits-page,.credit-admin{padding:.8rem .65rem calc(var(--mobile-nav-reserve,5rem) + .8rem)}.usage-metrics,.admin-summary,.credit-admin{grid-template-columns:1fr}.credit-admin>header,.credit-admin>.admin-summary{grid-column:auto}.admin-config-card{grid-template-columns:1fr}.admin-config-card h3,.admin-config-card>input[name=reason],.admin-config-card>.primary-button{grid-column:auto}.credit-ledger li{grid-template-columns:minmax(0,1fr) auto}.credit-ledger small{grid-column:1/-1}}

/* Phase 3.3 — commercial entitlement and billing surfaces */
.billing-page{width:min(100%,72rem);margin:0 auto;padding:1.4rem}.billing-page>header h2{margin:.25rem 0;font-size:clamp(1.7rem,3vw,2.5rem)}.billing-fx-note{display:block;margin-top:.55rem;color:#8295bf;line-height:1.45}.billing-plan{margin:1rem 0;padding:1.1rem;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.25rem 1rem;align-items:center;border:1px solid rgba(125,151,240,.2);border-radius:1.15rem;background:linear-gradient(145deg,rgba(18,32,69,.92),rgba(7,15,35,.94))}.billing-plan h3{margin:.2rem 0}.billing-plan>strong{font-size:2rem;color:#e8edff}.billing-plan>small{color:#91a3c9}.billing-buckets{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:.65rem;margin-bottom:1rem}.billing-buckets article,.billing-product,.billing-history,.billing-unavailable{padding:1rem;border:1px solid rgba(128,155,244,.16);border-radius:1rem;background:rgba(8,18,42,.76)}.billing-buckets span,.billing-product span,.billing-product small{display:block;color:#92a2c8}.billing-buckets strong{display:block;margin-top:.25rem;font-size:1.35rem}.billing-products{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.7rem}.billing-product{display:grid;gap:.55rem}.billing-product h3{margin:.2rem 0}.billing-product>strong{font-size:1.25rem}.billing-unavailable{margin:1rem 0;border-color:rgba(102,139,255,.24)}.billing-unavailable p{margin:.35rem 0 0;color:#9dadd2}.billing-history{margin-top:1rem}.billing-history ul,.compact-list{padding:0;margin:0;list-style:none}.billing-history li,.compact-list li{padding:.65rem 0;display:grid;grid-template-columns:minmax(0,1fr) auto auto auto;gap:.7rem;border-bottom:1px solid rgba(128,155,244,.1)}.billing-history li:last-child,.compact-list li:last-child{border:0}.billing-history small,.billing-history time{color:#8e9fc6}.billing-admin>header{grid-column:1/-1}.billing-admin .compact-list{grid-column:1/-1}.billing-admin .compact-list li{grid-template-columns:minmax(0,1fr) auto auto}
@media(max-width:47.99rem){.billing-page{padding:.8rem .65rem calc(var(--mobile-nav-reserve,5rem) + .8rem)}.billing-buckets{grid-template-columns:repeat(2,minmax(0,1fr))}.billing-products{grid-template-columns:1fr}.billing-history li{grid-template-columns:minmax(0,1fr) auto}.billing-history small,.billing-history time{grid-column:auto}.billing-admin>header{grid-column:auto}}

/* Focused iyzico billing flow */
.billing-security,.billing-profile-card,.billing-package-section{margin:1rem 0;padding:1.1rem;border:1px solid rgba(132,158,255,.2);border-radius:1.05rem;background:linear-gradient(145deg,rgba(17,31,67,.78),rgba(5,13,31,.88))}.billing-security{border-color:rgba(116,151,255,.3);background:linear-gradient(110deg,rgba(57,75,161,.22),rgba(10,20,48,.75))}.billing-security strong,.billing-profile-card h3,.billing-package-section h3{display:block;margin:.1rem 0 .3rem;color:#f2f5ff}.billing-security p,.billing-profile-card header p,.billing-package-section header p,.billing-history header p{margin:.3rem 0 0;color:#a9b8dc;line-height:1.5}.billing-profile-card>header>span,.billing-package-section header>span,.checkout-step{font-size:.74rem;font-weight:800;letter-spacing:.07em;color:#9baeff;text-transform:uppercase}.billing-profile-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.8rem;margin-top:1rem}.billing-profile-form label{display:grid;gap:.36rem;color:#dce5ff;font-size:.84rem;font-weight:700}.billing-profile-form input{width:100%;min-width:0;min-height:2.75rem;padding:.65rem .72rem;color:#f5f7ff;border:1px solid rgba(143,166,243,.28);border-radius:.72rem;background:rgba(3,10,27,.7);font:inherit}.billing-profile-form input:focus{outline:0;border-color:#7592ff;box-shadow:0 0 0 3px rgba(100,127,255,.16)}.billing-form-actions{grid-column:1/-1;display:flex;align-items:center;gap:.75rem;flex-wrap:wrap}.billing-form-actions output{color:#b7c7f5;font-size:.86rem}.billing-saved{margin:1rem 0 0;padding:.85rem;display:flex;justify-content:space-between;gap:1rem;border:1px solid rgba(99,219,178,.26);border-radius:.82rem;background:rgba(44,144,116,.09)}.billing-saved>div{min-width:0}.billing-saved span,.billing-saved small{display:block;color:#9ee7cf;font-size:.76rem}.billing-saved strong{display:block;margin:.25rem 0;color:#effff9}.billing-saved p{margin:.2rem 0;color:#c2d8d2;overflow-wrap:anywhere}.billing-package-section>header{margin-bottom:.8rem}.billing-products{grid-template-columns:1fr}.billing-product{grid-template-columns:minmax(0,1fr) auto;align-items:start;padding:1.2rem;border-color:rgba(125,142,255,.28);background:linear-gradient(145deg,rgba(20,36,78,.76),rgba(7,15,36,.92))}.billing-product>div:last-child{grid-column:1/-1;display:flex;justify-content:space-between;align-items:center;gap:1rem;padding-top:.65rem;border-top:1px solid rgba(141,160,243,.12)}.billing-product .primary-button{white-space:nowrap}.billing-product-value{text-align:right}.checkout-step{margin:.2rem 0}.payment-result{margin:1rem 0;padding:1rem;border:1px solid rgba(135,157,255,.28);border-radius:1rem;background:rgba(10,21,48,.8)}.payment-result>span{font-size:.76rem;color:#aebce1}.payment-result h3{margin:.25rem 0}.payment-result p{color:#b9c6e6;line-height:1.5}.payment-failed{border-color:rgba(243,147,147,.34);background:rgba(113,38,55,.16)}.payment-status{justify-self:start;padding:.25rem .5rem;border-radius:999px;font-size:.75rem;font-weight:800;color:#b9c8ed;background:rgba(112,137,230,.15)}.payment-status-paid{color:#a1edcf;background:rgba(53,171,126,.16)}.payment-status-failed{color:#ffc1c7;background:rgba(194,74,91,.18)}.billing-history header{margin-bottom:.65rem}.billing-history li{align-items:center}.billing-history li>div span,.billing-history li>div small{display:block}.billing-history li>div small{margin-top:.2rem}.billing-history a{color:#b9c8ff;font-size:.82rem}
@media(max-width:47.99rem){.billing-profile-form{grid-template-columns:1fr}.billing-saved{align-items:flex-start;flex-direction:column}.billing-product{grid-template-columns:1fr}.billing-product-value{text-align:left}.billing-product>div:last-child{align-items:flex-start;flex-direction:column}.billing-product .primary-button{width:100%}.billing-history li{grid-template-columns:minmax(0,1fr) auto}.billing-history li>a{grid-column:1/-1}}
/* Release 64 — phone-only billing compaction. Desktop and tablet retain the existing cadence. */
.billing-product-badge{display:none}
.billing-required-mobile,.billing-cta-mobile{display:none}
@media(max-width:47.99rem){
 .route-billing>.topbar{min-height:calc(3.55rem + var(--safe-top));padding-block:.34rem}.route-billing>.topbar .topbar-brand{font-size:.96rem}.route-billing>.topbar .avatar-button{width:2.25rem;height:2.25rem}
 .route-billing .workspace{padding-top:.62rem;padding-bottom:calc(var(--mobile-nav-reserve,5rem) + .65rem);min-width:0;overflow-x:clip}
 .billing-page{width:100%;max-width:100%;padding:.3rem 0 calc(var(--mobile-nav-reserve,5rem) + .65rem);box-sizing:border-box}.billing-page>header{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:.7rem;align-items:end}.billing-page>header .eyebrow{margin:0 0 .15rem;grid-column:1/-1;font-size:.66rem}.billing-page>header h2{margin:0;font-size:1.55rem;line-height:1.12}.billing-page>header>p{grid-column:1/-1;margin:.32rem 0 0;font-size:.88rem;line-height:1.45}.billing-page>header>.billing-fx-note{grid-column:1/-1;margin-top:.45rem;font-size:.72rem}.billing-currency{grid-column:2;grid-row:2;margin:0;display:flex;gap:.2rem;padding:.18rem;border:1px solid rgba(132,158,255,.2);border-radius:.7rem;background:rgba(8,18,42,.72)}.billing-currency button{min-height:2rem;padding:.25rem .48rem;font-size:.72rem;border:0;border-radius:.52rem;background:transparent;color:#acb9dc}.billing-currency button.active{color:#fff;background:rgba(103,91,255,.4)}
 .billing-plan{margin:.7rem 0;padding:.82rem .88rem;border-radius:.95rem}.billing-plan>strong{font-size:1.65rem}.billing-buckets{gap:.45rem;margin-bottom:.7rem}.billing-buckets article{padding:.68rem .72rem;border-radius:.82rem}.billing-buckets strong{font-size:1.15rem}
 .billing-security,.billing-profile-card,.billing-package-section{margin:.7rem 0;padding:.82rem;border-radius:.95rem}.billing-security p,.billing-profile-card header p,.billing-package-section header p{font-size:.86rem;line-height:1.42}.billing-profile-card header h3,.billing-package-section h3{font-size:1.05rem}.billing-profile-entry{margin-top:.7rem;padding:.78rem;border:1px solid rgba(121,145,240,.2);border-radius:.8rem;background:rgba(5,13,31,.52)}.billing-profile-entry strong{font-size:.94rem}.billing-profile-entry p{margin:.22rem 0 .65rem;color:#a9b8dc;font-size:.84rem;line-height:1.42}.billing-profile-entry .primary-button{min-height:2.55rem;width:100%;font-size:.86rem}.billing-saved{margin-top:.7rem;padding:.75rem;gap:.6rem}.billing-saved .secondary-button{min-height:2.35rem;padding:.45rem .72rem;font-size:.82rem}.billing-profile-form{margin-top:.75rem;gap:.58rem}.billing-profile-form input{min-height:2.55rem;padding:.54rem .65rem}.billing-profile-form label{gap:.28rem;font-size:.8rem}.billing-form-actions{gap:.55rem}.billing-form-actions .primary-button{min-height:2.6rem}
 .billing-package-section>header{margin-bottom:.6rem}.billing-required-mobile,.billing-cta-mobile{display:inline}.billing-required-desktop,.billing-cta-desktop,.billing-profile-required{display:none}.billing-products{gap:.5rem}.billing-product{position:relative;gap:.3rem;padding:.76rem;border-radius:.9rem}.billing-product h3{font-size:1rem}.billing-product p{margin:.18rem 0;color:#adbbdc;font-size:.84rem;line-height:1.38}.billing-product-value strong{font-size:1.28rem}.billing-product>div:last-child{gap:.32rem;padding-top:.45rem}.checkout-step{font-size:.66rem}.billing-product:has(.primary-button:disabled) .checkout-step{display:none}.billing-product .primary-button{min-height:2.45rem;padding:.5rem .7rem;font-size:.84rem}.billing-product .primary-button:disabled{width:auto;min-height:2.2rem;align-self:flex-start;padding:.38rem .68rem;color:#aeb9d8;background:rgba(255,255,255,.055);border:1px solid rgba(139,159,232,.18);box-shadow:none}.billing-product-badge{display:inline-flex!important;position:absolute;top:.75rem;right:.75rem;padding:.22rem .42rem;border-radius:999px;background:rgba(99,222,180,.18);color:#a9f0d3!important;font-size:.62rem!important;font-weight:800;letter-spacing:.04em;text-transform:uppercase}.billing-product-badge~h3{padding-right:5.6rem}
 .billing-history{margin-top:.7rem;padding:.8rem;border-radius:.9rem}.billing-history header{margin-bottom:.18rem}.billing-history h3{margin:0;font-size:1rem}.billing-history-note.is-empty{display:none}.billing-history-empty{margin:.24rem 0 0;color:#a9b8dc;font-size:.86rem}.billing-history li{padding:.5rem 0;gap:.45rem;font-size:.86rem}.route-billing{max-width:100%;overflow-x:clip}.route-billing>.sidebar,.route-billing>.context-panel{display:none!important;transform:none!important;width:0!important;pointer-events:none}
}
/* Release 67 — short landscape phones must not cross the tablet sidebar breakpoint. */
@media (max-width:47.99rem), (orientation:landscape) and (max-height:31.25rem) and (pointer:coarse){
 .route-billing .billing-required-mobile,.route-billing .billing-cta-mobile{display:inline!important}.route-billing .billing-required-desktop,.route-billing .billing-cta-desktop,.route-billing .billing-profile-required{display:none!important}
}
@media (orientation:landscape) and (max-height:31.25rem) and (pointer:coarse){
 .route-billing{padding-left:0!important;max-width:100%;overflow-x:clip}.route-billing>.sidebar,.route-billing>.context-panel{display:none!important}.route-billing>.workspace{width:100%;max-width:100%;min-width:0}.route-billing>.bottom-nav{display:grid!important}
}
.payment-detail-backdrop{position:fixed;z-index:80;inset:0;display:grid;place-items:center;padding:1rem;background:rgba(1,5,16,.72);backdrop-filter:blur(7px)}.payment-detail{position:relative;width:min(100%,34rem);max-height:min(80dvh,42rem);overflow:auto;padding:1.25rem;border:1px solid rgba(140,160,255,.33);border-radius:1rem;background:linear-gradient(145deg,#122351,#060d21);box-shadow:0 1.5rem 4rem rgba(0,0,0,.42)}.payment-detail>span{font-size:.76rem;font-weight:800;letter-spacing:.07em;text-transform:uppercase;color:#aebfff}.payment-detail h3{margin:.35rem 0}.payment-detail p{color:#bdc9e9;line-height:1.5}.payment-detail dl{margin:1rem 0 0;display:grid;grid-template-columns:8.5rem minmax(0,1fr);gap:.55rem .8rem;font-size:.88rem}.payment-detail dt{color:#95a6d2}.payment-detail dd{min-width:0;margin:0;color:#edf2ff;overflow-wrap:anywhere}.payment-detail-close{position:absolute;right:.75rem;top:.65rem;width:2rem;height:2rem;color:#dae3ff;border:0;border-radius:50%;background:rgba(255,255,255,.08);font-size:1.35rem;cursor:pointer}@media(max-width:47.99rem){.payment-detail-backdrop{align-items:end;padding:.5rem}.payment-detail{width:100%;max-height:82dvh;border-radius:1rem 1rem .65rem .65rem}.payment-detail dl{grid-template-columns:1fr;gap:.18rem}.payment-detail dd{margin-bottom:.55rem}}

/* Release 69 — shared premium product experience. */
:root{--topbar-height:4.5rem}
.topbar{min-height:var(--topbar-height);padding-block:.55rem}.topbar-title h1{font-size:1rem}.sidebar .nav-link{min-height:2.75rem}.nav-secondary{padding-top:.65rem;border-top:1px solid rgba(145,173,255,.1)}
.home-command{width:min(100%,64rem);margin:clamp(.25rem,2vw,1.4rem) auto 0;padding:clamp(1.15rem,3vw,2.3rem);border:1px solid rgba(145,173,255,.17);border-radius:1.25rem;background:rgba(8,18,40,.68);box-shadow:0 18px 55px rgba(0,0,0,.2)}.home-command-copy h2{margin:.25rem 0;font-size:clamp(1.8rem,3.4vw,2.8rem);letter-spacing:-.045em}.home-command-copy>p:last-child{max-width:42rem;margin:.4rem 0 0;color:#a9b5d2;line-height:1.55}.home-command .prompt-bar{max-width:none;margin-top:1.35rem;box-shadow:none}.home-command .home-suggestions{justify-content:flex-start;margin-top:.75rem}.home-products,.home-recent{width:min(100%,64rem);margin-inline:auto}.home-section-title{margin:1.6rem 0 .7rem}.home-section-title h2{margin:.15rem 0 0;font-size:1.2rem}.home-action-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:.55rem}.home-action{min-width:0;min-height:4.2rem;padding:.65rem;display:grid;grid-template-columns:2rem minmax(0,1fr) auto;gap:.55rem;align-items:center;color:#eaf0ff;border:1px solid rgba(145,173,255,.14);border-radius:.85rem;background:rgba(10,21,47,.6);text-align:start;cursor:pointer}.home-action>span:first-child{width:2rem;height:2rem;display:grid;place-items:center;color:#cbd5ff;border-radius:.6rem;background:rgba(111,92,255,.13)}.home-action span:nth-child(2){min-width:0}.home-action strong,.home-action small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.home-action strong{font-size:.83rem}.home-action small{margin-top:.12rem;color:#8292b8;font-size:.7rem}.home-action>.icon{width:.9rem}.home-action:disabled{cursor:default;opacity:.58}.home-action:not(:disabled):hover{border-color:rgba(130,121,255,.42);background:rgba(22,36,74,.76)}
.account-menu{background:#0b1530;box-shadow:0 1.5rem 4rem rgba(0,0,0,.46)}.account-menu-identity{width:100%;padding:.35rem;display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:.7rem;align-items:center;color:#f0f4ff;border:0;border-radius:.72rem;background:transparent;text-align:start;cursor:pointer}.account-menu-identity:hover{background:rgba(255,255,255,.045)}.account-menu-identity>span{min-width:0}.account-menu-identity strong,.account-menu-identity small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.account-menu-identity small{margin-top:.12rem;color:#9cacca;font-size:.76rem}.account-menu-identity em{color:#8fa0c7;font-style:normal}.account-menu-balance{position:relative;padding-right:6.2rem}.account-menu-balance>button{position:absolute;right:.1rem;top:50%;min-height:2.1rem;padding:.35rem .7rem;color:#fff;border:0;border-radius:.6rem;background:linear-gradient(135deg,#735dff,#398cff);transform:translateY(-50%);cursor:pointer;font-weight:750}.account-menu nav button.current{color:#fff;background:rgba(115,101,255,.14)}
.settings-profile-editor{position:relative;padding:0;border:0;background:transparent}.profile-identity{display:flex;align-items:center;gap:.9rem;padding:.85rem 0 1rem;border-bottom:1px solid rgba(145,173,255,.12)}.profile-identity h3{margin:0}.profile-identity p{margin:.2rem 0 0;color:#91a1c8}.profile-photo-trigger{position:relative;padding:0;border:0;border-radius:1rem;background:transparent;cursor:pointer}.profile-photo-trigger .profile-avatar{width:4.25rem;height:4.25rem;flex-basis:4.25rem}.profile-photo-trigger>span:last-child{position:absolute;right:-.2rem;bottom:-.15rem;width:1.65rem;height:1.65rem;display:grid;place-items:center;color:#fff;border:2px solid #071126;border-radius:.55rem;background:#526dff}.profile-photo-trigger>span:last-child .icon{width:.82rem}.settings-profile-editor>.field-hint{margin:.8rem 0;color:#8191b5}.settings-profile-editor .profile-form{padding:1rem;border:1px solid rgba(145,173,255,.14);border-radius:1rem;background:rgba(8,18,40,.55)}.profile-photo-backdrop{position:absolute;z-index:5;inset:0;background:transparent}.profile-photo-menu{position:absolute;top:5.4rem;left:.2rem;width:min(18rem,calc(100% - .4rem));padding:.35rem;border:1px solid rgba(145,173,255,.22);border-radius:.8rem;background:#0b1733;box-shadow:0 1rem 2.5rem rgba(0,0,0,.42)}.profile-photo-menu label,.profile-photo-menu button{width:100%;min-height:2.65rem;padding:.55rem .65rem;display:flex;align-items:center;gap:.6rem;color:#e8edff;border:0;border-radius:.6rem;background:transparent;text-align:start;cursor:pointer}.profile-photo-menu label:hover,.profile-photo-menu button:hover{background:rgba(255,255,255,.055)}.profile-photo-menu input{display:none}.settings-language-list{overflow:hidden;border:1px solid rgba(145,173,255,.14);border-radius:1rem;background:rgba(8,18,40,.55)}.settings-language-list button{width:100%;min-height:3.25rem;padding:.65rem .9rem;display:flex;align-items:center;justify-content:space-between;color:#e9eeff;border:0;border-bottom:1px solid rgba(145,173,255,.1);background:transparent;text-align:start;cursor:pointer}.settings-language-list button:last-child{border-bottom:0}.settings-language-list button[aria-selected="true"]{background:rgba(107,84,255,.11)}.settings-language-list strong{color:#7da1ff}
.chat-header{min-height:4.35rem;padding-block:.65rem}.chat-kicker{display:none}.chat-header h2{font-size:.98rem}.chat-header>div>p:last-child{font-size:.78rem}.chat-composer{box-shadow:0 14px 38px rgba(0,0,0,.3)}
.route-error-state{width:min(100%,38rem);margin:clamp(2rem,10vh,7rem) auto;padding:1.25rem;border:1px solid rgba(145,173,255,.18);border-radius:1rem;background:rgba(8,18,40,.62);text-align:center}.route-error-state h2{margin:0;font-size:1.25rem}.route-error-state p{margin:.45rem auto 1rem;color:#aebbd8;line-height:1.5}.route-error-state .primary-button{min-height:2.65rem}
.library-page{width:min(100%,78rem);margin:0 auto;padding:clamp(.4rem,1.8vw,1.35rem) 0 2rem}.library-heading{display:flex;align-items:end;justify-content:space-between;gap:1rem}.library-heading h2{margin:.18rem 0;font-size:clamp(1.65rem,3vw,2.35rem)}.library-heading p:last-child{max-width:42rem;margin:0;color:#aab7d3;line-height:1.45}.library-heading .upload-button{display:inline-flex;align-items:center;gap:.4rem;min-height:2.65rem;white-space:nowrap}.library-toolbar{display:flex;justify-content:space-between;gap:.8rem;align-items:center;margin:1rem 0}.library-categories{display:flex;gap:.38rem;min-width:0;overflow-x:auto;scrollbar-width:none}.library-categories::-webkit-scrollbar{display:none}.library-categories button{flex:0 0 auto;min-height:2.25rem;padding:.4rem .72rem;color:#aebbd8;border:1px solid rgba(145,173,255,.16);border-radius:999px;background:rgba(12,24,54,.54);font:inherit;font-size:.8rem;cursor:pointer}.library-categories button.active{color:#fff;border-color:rgba(121,103,255,.5);background:rgba(100,81,240,.24)}.library-project-filter{display:flex;align-items:center;gap:.45rem;color:#95a5cc;font-size:.78rem;white-space:nowrap}.library-project-filter select{min-width:9.5rem;min-height:2.3rem;padding:.35rem .55rem;color:#e8eeff;border:1px solid rgba(145,173,255,.18);border-radius:.65rem;background:#0b1732}.library-assets{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.7rem}.library-asset{position:relative;min-width:0;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.65rem;padding:.62rem;border:1px solid rgba(145,173,255,.14);border-radius:.95rem;background:rgba(8,18,40,.6)}.asset-preview{grid-column:1/-1;position:relative;min-width:0;aspect-ratio:1.55/1;overflow:hidden;border-radius:.68rem;background:#071127}.asset-preview img,.asset-preview video{display:block;width:100%;height:100%;object-fit:cover}.asset-video-label{position:absolute;right:.45rem;bottom:.45rem;padding:.18rem .42rem;border-radius:.4rem;background:rgba(2,8,21,.78);font-size:.68rem}.asset-copy{min-width:0}.asset-kind{display:block;color:#92a3d0;font-size:.68rem;font-weight:800;letter-spacing:.04em;text-transform:uppercase}.asset-copy h3{margin:.16rem 0;overflow:hidden;color:#eef2ff;font-size:.92rem;text-overflow:ellipsis;white-space:nowrap}.asset-copy p{margin:0;overflow:hidden;color:#8999bf;font-size:.72rem;text-overflow:ellipsis;white-space:nowrap}.asset-delete{align-self:start;width:2.1rem;height:2.1rem;padding:0}.asset-studio-link{margin-top:.48rem;padding:0;color:#b9c8ff;border:0;background:transparent;font:inherit;font-size:.75rem;font-weight:700;cursor:pointer}.asset-waveform{height:100%;display:flex;align-items:center;justify-content:center;gap:.22rem;padding:1rem;background:linear-gradient(145deg,rgba(126,99,255,.2),rgba(57,139,255,.12))}.asset-waveform i{width:.22rem;border-radius:999px;background:#bfaeff}.asset-waveform i:nth-child(1),.asset-waveform i:nth-child(6){height:20%}.asset-waveform i:nth-child(2),.asset-waveform i:nth-child(5){height:55%}.asset-waveform i:nth-child(3){height:82%}.asset-waveform i:nth-child(4){height:42%}.asset-file-icon{height:100%;display:grid;place-items:center;color:#b8c7ff;background:linear-gradient(145deg,rgba(85,117,214,.2),rgba(11,25,56,.55))}.asset-file-icon .icon{width:2rem;height:2rem}.library-asset--audio,.library-asset--file{grid-template-columns:4.75rem minmax(0,1fr) auto;align-items:center}.library-asset--audio .asset-preview,.library-asset--file .asset-preview{grid-column:auto;width:4.75rem;aspect-ratio:1}.library-asset--audio .asset-copy,.library-asset--file .asset-copy{align-self:center}.library-skeleton{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.7rem}.library-skeleton i{height:11rem;border-radius:.95rem;background:linear-gradient(90deg,rgba(255,255,255,.035),rgba(175,192,255,.11),rgba(255,255,255,.035));background-size:200% 100%;animation:library-sheen 1.2s linear infinite}@keyframes library-sheen{to{background-position:-200% 0}}
@media(max-width:71.99rem){.home-action-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:47.99rem){.library-page{width:100%;max-width:100%;padding:.2rem 0 calc(var(--mobile-nav-reserve,5rem) + .75rem)}.library-heading{align-items:center;gap:.65rem}.library-heading .eyebrow{margin:0 0 .12rem}.library-heading h2{font-size:1.42rem}.library-heading p:last-child{font-size:.83rem}.library-heading .upload-button{min-width:2.5rem;min-height:2.5rem;padding:.48rem .6rem}.library-heading .upload-button span{display:none}.library-toolbar{display:grid;gap:.55rem;margin:.7rem 0}.library-categories{width:calc(100% + .05rem);padding-bottom:.08rem}.library-project-filter{justify-content:space-between}.library-project-filter select{flex:1;min-width:0}.library-assets{grid-template-columns:1fr;gap:.52rem}.library-asset{grid-template-columns:4.3rem minmax(0,1fr) auto;align-items:center;padding:.55rem}.library-asset .asset-preview{grid-column:auto;width:4.3rem;aspect-ratio:1;border-radius:.62rem}.library-asset--image,.library-asset--video{grid-template-columns:5.5rem minmax(0,1fr) auto}.library-asset--image .asset-preview,.library-asset--video .asset-preview{width:5.5rem}.asset-copy h3{font-size:.88rem}.asset-delete{width:2rem;height:2rem}.library-skeleton{grid-template-columns:1fr}.library-skeleton i{height:5.4rem}.route-library .workspace{overflow-x:clip}.route-library{max-width:100%;overflow-x:clip}}

/* Video V1 — compact production workspace; provider availability is server-owned. */
.video-studio{width:min(100%,76rem);margin:0 auto;padding:clamp(.45rem,2vw,1.5rem) 0 2rem}.video-head{display:flex;align-items:end;justify-content:space-between;gap:1rem;margin-bottom:1rem}.video-head h2{margin:.18rem 0;font-size:clamp(1.65rem,3vw,2.35rem)}.video-head p:last-child{margin:0;color:#a9b7d5}.video-live-state{padding:.35rem .6rem;color:#abefd4;border:1px solid rgba(83,214,164,.25);border-radius:999px;background:rgba(50,156,116,.12);font-size:.76rem;font-weight:800}.video-layout{display:grid;grid-template-columns:minmax(20rem,.92fr) minmax(0,1.08fr);gap:1rem}.video-form,.video-output{min-width:0;padding:1rem;border:1px solid rgba(145,173,255,.16);border-radius:1rem;background:rgba(8,18,40,.62)}.video-form{display:grid;gap:.8rem;align-content:start}.video-form label{display:grid;gap:.35rem;color:#cbd5f1;font-size:.82rem;font-weight:700}.video-form textarea,.video-form select{width:100%;min-width:0;border:1px solid rgba(145,173,255,.2);border-radius:.7rem;background:#09152f;color:#f1f4ff;font:inherit}.video-form textarea{min-height:8rem;padding:.7rem;resize:vertical}.video-form select{min-height:2.55rem;padding:.45rem .55rem}.video-mode-tabs{display:flex;gap:.35rem;padding:.25rem;border:1px solid rgba(145,173,255,.15);border-radius:.8rem;background:rgba(3,10,25,.44)}.video-mode-tabs button{flex:1;min-height:2.35rem;color:#aebddd;border:0;border-radius:.58rem;background:transparent;font:inherit;cursor:pointer}.video-mode-tabs button.active{color:#fff;background:rgba(102,84,246,.35)}.video-controls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.55rem}.video-model-choice{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.5rem;margin:0;padding:0;border:0}.video-model-choice legend{margin-bottom:.35rem;color:#cbd5f1;font-size:.82rem;font-weight:700}.video-model-choice label{position:relative;min-height:4.15rem;padding:.65rem;border:1px solid rgba(145,173,255,.17);border-radius:.75rem;background:rgba(255,255,255,.025);cursor:pointer}.video-model-choice input{position:absolute;opacity:0}.video-model-choice span{display:block}.video-model-choice strong,.video-model-choice small{display:block}.video-model-choice small{margin-top:.18rem;color:#8798c1;font-weight:400;font-size:.7rem;line-height:1.35}.video-model-choice label:has(input:checked){border-color:rgba(119,103,255,.64);background:rgba(94,75,220,.16)}.video-audio{display:flex!important;grid-template-columns:auto 1fr;align-items:center}.video-notice,.video-error{margin:0;padding:.65rem .72rem;border-radius:.7rem;font-size:.82rem;line-height:1.4}.video-notice{color:#b7c4e6;border:1px solid rgba(145,173,255,.14);background:rgba(255,255,255,.025)}.video-error{color:#ffc0c9;border:1px solid rgba(236,121,140,.25);background:rgba(150,51,70,.14)}.video-form .primary-button{min-height:2.75rem}.video-output>header{display:flex;justify-content:space-between;align-items:center;margin-bottom:.75rem}.video-output h3{margin:.15rem 0;font-size:1.05rem}.video-result{display:grid;grid-template-columns:9rem minmax(0,1fr);gap:.7rem;padding:.65rem 0;border-top:1px solid rgba(145,173,255,.1)}.video-result:first-of-type{border-top:0}.video-result video,.video-result-placeholder{width:9rem;aspect-ratio:16/9;border-radius:.65rem;background:#061025;object-fit:cover}.video-result-placeholder{position:relative;display:grid;place-items:center;overflow:hidden;color:#aebcf0}.video-result-placeholder i{position:absolute;bottom:0;left:0;height:.22rem;background:linear-gradient(90deg,#745cff,#35a8ff)}.video-result strong,.video-result small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.video-result strong{margin-top:.08rem;color:#eff3ff;font-size:.84rem}.video-result small,.video-result p{margin:.25rem 0 0;color:#8f9fc6;font-size:.74rem}.video-result .secondary-button{min-height:2.15rem;margin-top:.55rem;padding:.35rem .6rem;font-size:.74rem}.video-empty{min-height:16rem;display:grid;place-items:center;align-content:center;gap:.5rem;color:#91a1c5;text-align:center}.video-empty .icon{width:2.2rem;height:2.2rem}.video-empty p{margin:0}
@media(max-width:47.99rem){.video-studio{width:100%;max-width:100%;padding:.2rem 0 calc(var(--mobile-nav-reserve,5rem) + .75rem)}.video-head{align-items:center;margin-bottom:.7rem}.video-head h2{font-size:1.42rem}.video-head p:last-child{font-size:.83rem}.video-layout{grid-template-columns:1fr;gap:.7rem}.video-form,.video-output{padding:.8rem;border-radius:.9rem}.video-controls{gap:.4rem}.video-controls label{font-size:.75rem}.video-model-choice{grid-template-columns:1fr 1fr}.video-model-choice label{min-height:3.85rem;padding:.55rem}.video-result{grid-template-columns:6.5rem minmax(0,1fr)}.video-result video,.video-result-placeholder{width:6.5rem}.route-video,.route-video .workspace{max-width:100%;overflow-x:clip}}

/* Reference rebuild: Image keeps the original form/result contracts while presenting a studio-scale workspace. */
.image-studio{max-width:1540px;padding:clamp(.65rem,1.7vw,1.6rem)}.image-studio-head{min-height:5.5rem;padding:0 .35rem}.image-studio-head>div{min-width:0}.image-studio-head .eyebrow{color:#9bb6ef;letter-spacing:.16em}.image-studio-head h2{font-size:clamp(2rem,3.2vw,3.05rem);letter-spacing:-.055em}.image-studio-head p:last-child{max-width:46rem;margin:.35rem 0 0;color:#97a9ce}.image-provider-state{border-color:rgba(75,196,255,.35);background:linear-gradient(135deg,rgba(47,143,230,.16),rgba(105,79,255,.14));box-shadow:inset 0 1px rgba(255,255,255,.08)}.image-studio-grid{grid-template-columns:minmax(19rem,23.5rem) minmax(0,1fr);gap:1.15rem;align-items:start}.image-controls{position:sticky;top:calc(var(--topbar-height,4rem) + .85rem);padding:1.15rem;border-color:rgba(116,145,255,.22);border-radius:1.15rem;background:linear-gradient(160deg,rgba(16,33,75,.96),rgba(7,15,37,.96));box-shadow:0 22px 55px rgba(0,0,0,.22),inset 0 1px rgba(255,255,255,.07)}.image-controls>label:first-child>span,.image-controls legend{color:#dfe8ff;font-size:.77rem;letter-spacing:.08em;font-weight:800;text-transform:uppercase}.image-controls textarea{min-height:11.5rem;padding:.9rem;line-height:1.55;border-color:rgba(109,151,255,.3);background:linear-gradient(145deg,#0b1837,#09132c)}.image-controls textarea::placeholder{color:#778bb8}.image-controls select{min-height:2.8rem;background:#091631}.image-control-row{gap:.55rem}.image-upload{min-height:3.65rem;color:#b9d6ff;border-color:rgba(99,172,255,.48);background:rgba(43,116,204,.08)}.image-upload:hover{border-color:#62baff;background:rgba(44,137,237,.14)}.segmented{gap:.35rem}.segmented span{min-width:3.3rem;padding:.5rem .6rem;color:#b8c5e5;background:rgba(255,255,255,.025);text-align:center;font-size:.76rem}.segmented input:checked+span{color:#fff;border-color:#7593ff;background:linear-gradient(135deg,rgba(96,79,236,.55),rgba(43,139,235,.35));box-shadow:0 6px 18px rgba(49,89,224,.18)}.image-generate{min-height:3.5rem;margin-top:.2rem;font-weight:850;letter-spacing:.01em}.image-workspace{position:relative;min-height:45rem;padding:clamp(1rem,2vw,1.65rem);overflow:hidden;border-color:rgba(112,142,255,.2);border-radius:1.25rem;background:radial-gradient(circle at 75% 10%,rgba(63,137,255,.12),transparent 22rem),linear-gradient(145deg,rgba(11,23,52,.94),rgba(5,12,29,.98));box-shadow:0 25px 70px rgba(0,0,0,.25),inset 0 1px rgba(255,255,255,.06)}.image-workspace:before{position:absolute;inset:0;content:"";pointer-events:none;opacity:.38;background-image:linear-gradient(rgba(143,168,255,.045) 1px,transparent 1px),linear-gradient(90deg,rgba(143,168,255,.045) 1px,transparent 1px);background-size:36px 36px;mask-image:linear-gradient(to bottom,black,transparent 50%)}.image-result,.image-empty,.image-workspace>h3,.image-history,.image-workspace>button{position:relative}.image-result{min-height:28rem;display:grid;place-items:center;padding:1.1rem;border:1px solid rgba(136,167,255,.16);border-radius:1rem;background:rgba(3,9,24,.44)}.image-result>img{max-height:min(62vh,40rem);border-radius:.8rem;box-shadow:0 20px 48px rgba(0,0,0,.45)}.image-result-actions{width:min(100%,42rem);justify-content:center;margin:1rem auto 0}.image-empty{min-height:31rem;border:1px dashed rgba(115,148,255,.23);border-radius:1rem;background:rgba(5,13,32,.34)}.image-empty .icon{width:3.6rem;height:3.6rem;padding:.9rem;border:1px solid rgba(106,150,255,.28);border-radius:1rem;color:#7ec6ff;background:rgba(54,122,235,.1)}.image-empty h3{margin:1.1rem 0 .25rem;color:#e8efff;font-size:1.45rem}.image-empty p{max-width:24rem;margin:0;color:#8fa0c5;line-height:1.6}.image-workspace>h3{margin:1.65rem 0 .8rem;color:#e7edff;font-size:1rem;letter-spacing:.03em}.image-history{grid-template-columns:repeat(4,minmax(0,1fr));gap:.8rem}.image-history-card{padding:.5rem;border-color:rgba(133,161,255,.2);border-radius:.85rem;background:rgba(8,18,42,.78);transition:transform .18s ease,border-color .18s ease}.image-history-card:hover{transform:translateY(-3px);border-color:rgba(109,161,255,.55)}.image-history-card img,.image-state{border-radius:.62rem}.image-history-card strong{font-size:.75rem;color:#dbe5ff}.image-history-card small{font-size:.67rem}.image-controls :focus-visible,.image-result-actions :focus-visible{outline-color:#9acbff}
/* Video uses the real generation controls and results; its large preview surface never advertises unsupported editing. */
.video-studio{width:min(100%,90rem);padding:clamp(.7rem,1.8vw,1.6rem) clamp(.65rem,1.2vw,1.1rem) 2rem}.video-head{min-height:5.3rem;padding:.1rem .25rem}.video-head .eyebrow{color:#a4b8f5;letter-spacing:.17em}.video-head h2{font-size:clamp(2rem,3vw,3rem);letter-spacing:-.055em}.video-head p:last-child{max-width:42rem;color:#99a9ce}.video-layout{grid-template-columns:minmax(20rem,23rem) minmax(0,1fr);gap:1.1rem;align-items:start}.video-form,.video-output{border-color:rgba(129,158,255,.22);border-radius:1.15rem;background:linear-gradient(155deg,rgba(14,29,67,.94),rgba(6,13,32,.97));box-shadow:0 23px 60px rgba(0,0,0,.22),inset 0 1px rgba(255,255,255,.06)}.video-form{position:sticky;top:calc(var(--topbar-height,4rem) + .85rem);padding:1.1rem}.video-mode-tabs{padding:.3rem;border-color:rgba(130,158,255,.2);background:#071127}.video-mode-tabs button{font-size:.78rem}.video-mode-tabs button.active{background:linear-gradient(135deg,rgba(101,82,246,.75),rgba(50,144,243,.52));box-shadow:0 5px 14px rgba(65,96,236,.22)}.video-form label{color:#d3def8;font-size:.75rem;letter-spacing:.03em}.video-form textarea{min-height:10.3rem;padding:.85rem;line-height:1.55;border-color:rgba(117,155,255,.28);background:#091733}.video-form textarea::placeholder{color:#788bb6}.video-form select{border-color:rgba(117,155,255,.22);background:#091733}.video-controls{gap:.45rem}.video-controls label{min-width:0}.video-model-choice{gap:.45rem}.video-model-choice label{min-height:4.7rem;padding:.7rem;border-color:rgba(128,158,255,.2);background:rgba(255,255,255,.028)}.video-model-choice label:has(input:checked){border-color:rgba(101,143,255,.72);background:linear-gradient(135deg,rgba(89,71,220,.27),rgba(33,128,216,.17));box-shadow:inset 0 1px rgba(255,255,255,.06)}.video-form .primary-button{min-height:3.25rem;margin-top:.15rem;font-weight:850}.video-output{min-height:40rem;padding:clamp(1rem,2vw,1.5rem);background:radial-gradient(circle at 80% 8%,rgba(66,143,255,.12),transparent 25rem),linear-gradient(155deg,rgba(11,25,58,.96),rgba(5,12,29,.98))}.video-output>header{padding-bottom:.85rem;border-bottom:1px solid rgba(143,170,255,.13)}.video-output>header .eyebrow{margin:0;color:#8da9e6;font-size:.65rem;letter-spacing:.14em}.video-output h3{font-size:1.25rem}.video-empty{position:relative;min-height:31rem;border:1px dashed rgba(129,164,255,.25);border-radius:1rem;background:linear-gradient(145deg,rgba(7,19,48,.66),rgba(4,11,28,.46));overflow:hidden}.video-empty:before{position:absolute;inset:14% 15%;content:"";border:1px solid rgba(118,154,255,.17);border-radius:.9rem;background:linear-gradient(145deg,rgba(82,117,217,.11),rgba(16,24,57,.06));box-shadow:0 0 80px rgba(65,101,255,.1)}.video-empty>*{position:relative}.video-empty .icon{width:3.4rem;height:3.4rem;padding:.85rem;border:1px solid rgba(108,161,255,.32);border-radius:1rem;color:#8ecaff;background:rgba(38,120,222,.13)}.video-empty p{max-width:20rem;color:#9cadd1;line-height:1.6}.video-result{grid-template-columns:minmax(10rem,15rem) minmax(0,1fr);gap:1rem;padding:1rem 0}.video-result video,.video-result-placeholder{width:100%;border-radius:.75rem;box-shadow:0 10px 28px rgba(0,0,0,.25)}.video-result strong{margin-top:.2rem;font-size:.95rem}.video-result .secondary-button{min-height:2.35rem}.video-live-state{padding:.46rem .76rem;border-color:rgba(85,218,174,.32);background:rgba(47,164,116,.13)}
@media(max-width:900px){.image-studio-grid{grid-template-columns:1fr}.image-controls,.video-form{position:static}.image-workspace{min-height:34rem}.image-history{grid-template-columns:repeat(3,minmax(0,1fr))}.video-layout{grid-template-columns:1fr}.video-output{min-height:28rem}.video-empty{min-height:23rem}}
@media(max-width:520px){.image-studio{padding:.45rem .55rem calc(var(--mobile-nav-height,5.6rem) + env(safe-area-inset-bottom) + 1rem)}.image-studio-head{min-height:0;padding:.45rem .15rem .8rem;display:block}.image-studio-head h2,.video-head h2{font-size:2rem}.image-provider-state{display:inline-flex;margin-top:.55rem}.image-controls{padding:.85rem;border-radius:1rem}.image-controls textarea{min-height:8.8rem}.image-workspace{min-height:26rem;padding:.75rem;border-radius:1rem}.image-result{min-height:20rem;padding:.55rem}.image-empty{min-height:21rem;padding:1.1rem}.image-history{grid-template-columns:repeat(2,minmax(0,1fr));gap:.55rem}.video-studio{padding:.45rem .55rem calc(var(--mobile-nav-reserve,5rem) + 1rem)}.video-head{display:block;min-height:0;padding:.45rem .15rem .8rem}.video-head .coming-badge,.video-head .video-live-state{display:inline-flex;margin-top:.55rem}.video-form,.video-output{padding:.82rem;border-radius:1rem}.video-controls{grid-template-columns:1fr 1fr}.video-controls label:last-child{grid-column:1/-1}.video-model-choice{grid-template-columns:1fr}.video-output{min-height:23rem}.video-empty{min-height:18rem}.video-result{grid-template-columns:1fr}.video-result video,.video-result-placeholder{width:100%;max-width:100%;aspect-ratio:16/9}}
@media(max-width:47.99rem), (orientation:landscape) and (max-height:31.25rem) and (pointer:coarse){
 .app-shell{max-width:100vw!important;overflow-x:clip}.app-shell>.sidebar,.app-shell>.context-panel{display:none!important;width:0!important;max-width:0!important;transform:none!important;visibility:hidden!important;pointer-events:none!important}.app-shell>.workspace{min-width:0;max-width:100%}
}
@media(max-width:47.99rem){
 :root{--topbar-height:3.75rem}.topbar{min-height:calc(var(--topbar-height) + var(--safe-top));padding-block:.35rem}.topbar-brand.brand-text{font-size:.95rem}.topbar .avatar-button{width:2.25rem;height:2.25rem;min-width:2.25rem}.project-switcher{display:none}
 .home-command{margin-top:0;padding:1rem;border-radius:1rem}.home-command-copy h2{font-size:1.65rem}.home-command-copy>p:last-child{font-size:.88rem}.home-command .prompt-bar{margin-top:1rem}.home-command .home-suggestions{overflow-x:auto;flex-wrap:nowrap}.home-action-grid{grid-template-columns:1fr 1fr}.home-action{min-height:4rem}.home-action:last-child{grid-column:1/-1}.home-section-title{margin-top:1.25rem}.home-recent{padding:.85rem}
 .account-menu{bottom:calc(var(--bottom-nav-height) + var(--safe-bottom) + .45rem);max-height:calc(100dvh - var(--bottom-nav-height) - var(--safe-bottom) - 1rem)}
 .settings-page{padding-top:.15rem}.settings-profile-editor .profile-form{padding:.8rem}.profile-photo-backdrop{position:fixed;z-index:170;inset:0;display:flex;align-items:flex-end;padding:.55rem;background:rgba(1,6,18,.58)}.profile-photo-menu{position:static;width:100%;padding:.45rem;border-radius:1rem;background:#0b1733}.profile-photo-menu label,.profile-photo-menu button{min-height:3rem}
}
