@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500&display=swap');
:root{--paper:#f7f6f1;--ink:#223b34;--muted:#68736e;--line:#dcded5;--accent:#db6b3e;--white:#fff;--mono:'IBM Plex Mono',monospace;--sans:'DM Sans','PingFang SC','Microsoft YaHei',sans-serif}
*{box-sizing:border-box}html{scroll-behavior:smooth;scroll-padding-top:90px}body{margin:0;background:var(--paper);color:var(--ink);font:16px/1.6 var(--sans);-webkit-font-smoothing:antialiased}a{color:inherit;text-decoration:none}button,input,select{font:inherit}button,a,summary,select,label[for]{-webkit-tap-highlight-color:transparent}a:focus-visible,button:focus-visible,summary:focus-visible,select:focus-visible,label:focus-visible{outline:3px solid var(--accent);outline-offset:5px}p,h1,h2,h3,figure{margin:0}h1,h2,h3{line-height:1.1;letter-spacing:-.035em}h1{font-size:clamp(46px,5vw,76px);font-weight:500}h2{font-size:clamp(34px,3.5vw,48px);font-weight:500}h3{font-size:21px;font-weight:600;letter-spacing:-.025em}em{font-style:normal;color:var(--accent)}.skip{position:fixed;left:12px;top:-100px;padding:12px;background:var(--ink);color:white;z-index:10}.skip:focus{top:12px}.site-header{max-width:1440px;margin:auto;display:flex;align-items:center;justify-content:space-between;gap:20px;padding:24px 5.5%;border-bottom:1px solid var(--line)}.brand{display:inline-flex;align-items:center;gap:10px;font-size:24px;font-weight:700;line-height:1;letter-spacing:-.8px;white-space:nowrap}.brand-mark{font-size:33px;color:var(--accent);transform:rotate(-12deg);line-height:1}.brand-suffix{font-family:var(--mono);font-size:12px;font-weight:400;letter-spacing:0;margin-left:5px;color:var(--muted)}.site-tabs{display:flex;align-items:center;gap:4px;padding:4px;border:1px solid var(--line);background:#eeeee8}.site-tabs a{padding:6px 10px;font:10px/1.3 var(--mono);letter-spacing:.25px;color:var(--muted);white-space:nowrap;transition:background .18s,color .18s}.site-tabs a:hover{color:var(--ink);background:#e1e5dc}.site-tabs a.active{background:var(--ink);color:var(--paper)}.header-actions{display:flex;align-items:center;gap:16px}.account-link{font-size:13px;font-weight:650;white-space:nowrap}.language-picker{display:inline-flex}.language-picker select{max-width:126px;border:1px solid var(--line);border-radius:0;background:transparent;color:var(--ink);padding:6px 25px 6px 8px;font:11px var(--mono);cursor:pointer}.small-button{display:inline-flex;align-items:center;gap:20px;background:var(--ink);color:var(--paper);padding:11px 18px;font-size:12px;font-weight:600}.hero{max-width:1440px;margin:auto;padding:76px 5.5% 65px;display:flex;gap:4%;align-items:center;min-height:650px}.hero-copy{width:44%;flex:none}.eyebrow{display:flex;align-items:center;gap:9px;font-family:var(--mono);font-size:10px;letter-spacing:1.8px;font-weight:500;margin-bottom:27px;text-transform:uppercase}.live-dot{height:6px;width:6px;border-radius:50%;background:var(--accent);box-shadow:0 0 0 4px #db6b3e15}.lead{max-width:470px;font-size:16px;line-height:1.8;color:var(--muted);margin-top:25px}.hero-actions{display:flex;align-items:center;gap:24px;margin-top:32px;flex-wrap:wrap}.button{display:inline-flex;align-items:center;justify-content:space-between;gap:24px;padding:17px 21px;background:var(--ink);color:var(--paper);font-size:13px;font-weight:600;transition:background .18s,transform .18s}.button:hover,.small-button:hover{background:#345b4c}.button:hover{transform:translateY(-2px)}.text-link{font-size:13px;display:flex;gap:10px;align-items:center}.checks{display:flex;gap:20px;flex-wrap:wrap;font-size:10px;color:var(--muted);margin-top:24px}.checks b{color:var(--ink);margin-right:4px}.hero-preview{width:52%;position:relative;box-shadow:0 25px 50px -30px #223b3480;background:#22282f;transform:rotate(-1.3deg);border:1px solid #4a5556}.preview-title{display:flex;justify-content:space-between;align-items:center;padding:10px 14px;color:#c1cac5;font:8px var(--mono);letter-spacing:1px}.preview-dots{font-size:8px;color:#6c7872;letter-spacing:3px}.hero-preview img{display:block;width:100%;height:auto}.hero-preview figcaption{color:#a5b4ae;background:#293431;padding:11px 14px;font-size:9px;line-height:1.4}.preview-stamp{position:absolute;bottom:-27px;right:20px;background:var(--accent);padding:14px 18px;transform:rotate(4deg);color:var(--white);min-width:108px}.preview-stamp span{display:block;font:27px var(--mono);line-height:1.2}.preview-stamp small{font:8px var(--mono);letter-spacing:1px}.spec-strip{max-width:1280px;margin:0 auto;border-top:1px solid var(--line);border-bottom:1px solid var(--line);display:flex;justify-content:space-between;padding:24px 18px;gap:20px}.spec-strip>span{display:flex;align-items:center;gap:22px;font-size:12px}.spec-strip small{font:9px var(--mono);color:#959e97}.section{max-width:1280px;margin:auto;padding:88px 18px;border-bottom:1px solid var(--line);display:flex;gap:10%}.section-heading{width:40%;flex:none}.section .eyebrow{margin-bottom:23px}.subnote{font-size:14px;color:var(--muted);margin-top:22px;max-width:330px}.feature-list{flex:1}.feature-list article{display:flex;gap:23px;padding:28px 0;border-bottom:1px solid var(--line)}.feature-list article:first-child{padding-top:0}.feature-list article:last-child{border-bottom:0;padding-bottom:0}.feature-number{font:11px var(--mono);color:var(--accent);padding-top:5px}.feature-list p,.steps p{font-size:14px;line-height:1.8;color:var(--muted);margin-top:11px}.guide-section{display:block;background:var(--paper)}.guide-section .section-heading{width:100%}.guide-body{display:flex;gap:8%;margin-top:42px;align-items:flex-start}.steps{list-style:none;padding:0;margin:0;width:48%;counter-reset:step}.steps li{counter-increment:step;position:relative;padding:0 0 26px 48px}.steps li:before{content:'0' counter(step);position:absolute;left:0;top:0;border:1px solid var(--line);padding:5px 7px;font:11px var(--mono);color:var(--accent)}.terminal{background:var(--ink);color:var(--paper);width:44%;padding:30px;position:relative;box-shadow:10px 10px 0 #e6e7de}.terminal p{font:10px var(--mono);letter-spacing:1px;color:#c6d1c5;border-bottom:1px solid #527264;padding-bottom:20px}.terminal pre{font:14px/2.2 var(--mono);margin:24px 0;overflow:auto}.terminal pre span{color:#a2b7a7;margin-right:18px;font-size:10px}.terminal small{font-size:11px;display:block;color:#b7c6ba;line-height:1.8}.terminal a{display:inline-block;font-size:12px;margin-top:26px;color:#efad89}.faq-section>div:first-child{width:40%;flex:none}.faq-section>div:last-child{flex:1}details{border-bottom:1px solid var(--line);padding:18px 0}details:first-child{padding-top:0}summary{list-style:none;cursor:pointer;display:flex;justify-content:space-between;gap:16px;font-size:16px;font-weight:500}summary::-webkit-details-marker{display:none}summary>span{color:var(--accent);font-weight:400;font-size:22px;line-height:1.2}details[open] summary>span{transform:rotate(45deg)}details p{font-size:14px;line-height:1.8;color:var(--muted);margin-top:16px}.closing{max-width:1280px;margin:60px auto;display:flex;justify-content:space-between;align-items:center;gap:30px;background:var(--ink);color:var(--paper);padding:54px 44px}.closing h2{font-size:38px}.closing p:not(.eyebrow){font-size:13px;color:#b9c8bd;margin-top:16px}.closing .eyebrow{font-size:9px;margin-bottom:15px;color:#b9c8bd}.light{background:var(--paper);color:var(--ink);white-space:nowrap}.light:hover{background:#e5eadd}footer{max-width:1440px;margin:auto;display:flex;justify-content:space-between;align-items:flex-start;gap:40px;padding:30px 5.5% 42px;border-top:1px solid var(--line)}footer .brand{font-size:20px}footer p{max-width:550px;font-size:10px;color:var(--muted);line-height:1.8}footer p a{text-decoration:underline;white-space:nowrap}footer>span{font-size:9px;color:var(--muted);white-space:nowrap}.legal{max-width:850px;margin:70px auto;padding:0 28px}.legal h1{font-size:48px}.legal h2{font-size:26px;margin:42px 0 14px}.legal p,.legal li{color:var(--muted);font-size:15px;margin-top:14px}.legal a{color:var(--ink);text-decoration:underline}.editor-page{height:100dvh;display:flex;flex-direction:column;overflow:hidden;background:#22282f}.editor-header{display:flex;align-items:center;gap:16px;background:var(--paper);padding:10px 18px;flex-shrink:0;flex-wrap:wrap}.editor-header .brand{font-size:20px}.editor-header .site-tabs{flex-shrink:0}.editor-status{flex:1;min-width:120px;font:10px var(--mono);color:var(--muted)}.editor-controls{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.tool-button,.editor-controls select{border:1px solid var(--line);padding:6px 11px;font-size:11px;line-height:1.5;background:transparent;color:var(--ink);cursor:pointer}.tool-button:hover{background:#e8ece3}.tool-button:disabled{opacity:.5;cursor:wait}.editor-note{display:flex;justify-content:space-between;gap:20px;padding:7px 18px;background:#e8ece3;color:var(--ink);font-size:10px}.editor-note a{white-space:nowrap;text-decoration:underline}.editor-stage{flex:1;min-height:0;position:relative}.editor-stage iframe{display:block;border:0;width:100%;height:100%;background:#22282f}.loading-overlay{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:#22282f;color:var(--paper);padding:28px;pointer-events:none}.loading-overlay[hidden]{display:none}.loading-inner{max-width:500px;text-align:center}.loading-inner h1{font-size:24px;margin:22px 0 15px}.loading-inner p{font-size:13px;line-height:1.8;color:#b3c0b8}.loading-inner button{color:var(--paper);pointer-events:auto;margin-top:20px}.loading-inner button:hover{color:var(--ink)}.spinner{margin:auto;border:2px solid #4c5b52;border-top-color:var(--accent);width:28px;height:28px;border-radius:50%;animation:spin 1s linear infinite}.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@keyframes spin{to{transform:rotate(360deg)}}
@media(min-width:1600px){.hero{min-height:720px}}@media(max-width:1350px){.section,.spec-strip,.closing{margin-left:5.5%;margin-right:5.5%}.hero-actions{gap:15px}.hero-preview{width:51%}.hero-copy{width:45%}.header-actions{gap:11px}.site-tabs a{padding-inline:8px}}@media(max-width:1000px){.hero{padding-top:55px;min-height:560px;gap:5%}h1{font-size:52px}.hero-copy{width:47%}.hero-preview{width:48%}.lead{font-size:14px}.hero-actions .button{padding:14px 16px}.checks{gap:12px}.section{gap:6%;padding-top:65px;padding-bottom:65px}.section-heading,.faq-section>div:first-child{width:40%}.closing{padding:35px}.closing h2{font-size:31px}.spec-strip>span{gap:12px}.editor-status{display:none}.site-header{flex-wrap:wrap}.site-header .site-tabs{order:3}.site-header .header-actions{margin-left:auto}}@media(max-width:720px){.site-header{padding:16px 6%;gap:10px}.brand{font-size:22px}.brand-suffix{font-size:10px}.brand-mark{font-size:28px}.site-header .site-tabs{order:3;width:100%;justify-content:stretch}.site-tabs a{flex:1;text-align:center;padding-block:8px}.header-actions{gap:9px}.header-actions .small-button{display:none}.language-picker select{max-width:112px}.hero{padding:48px 6% 60px;display:block;min-height:0}.hero-copy{width:100%}.hero h1{font-size:53px}.eyebrow{font-size:9px;margin-bottom:22px;letter-spacing:1px}.lead{font-size:15px}.hero-actions{margin-top:28px;gap:20px}.checks{font-size:10px;gap:18px}.hero-preview{width:100%;margin-top:47px;transform:rotate(-.7deg)}.preview-stamp{bottom:-20px}.spec-strip{flex-wrap:wrap;padding:20px 10px;row-gap:17px}.spec-strip>span{width:44%;font-size:10px}.section{display:block;padding:52px 4px}.section-heading,.faq-section>div:first-child{width:100%}h2{font-size:36px}.subnote{max-width:none}.feature-list{margin-top:33px}.feature-list h3{font-size:20px}.feature-list article{gap:19px}.guide-body{display:block;margin-top:33px}.steps,.terminal{width:100%}.terminal{margin-top:10px;padding:26px}.faq-section>div:last-child{margin-top:29px}.closing{display:block;margin-top:35px;margin-bottom:35px;padding:30px 25px}.closing h2{font-size:31px}.closing .button{margin-top:24px}footer{flex-wrap:wrap;padding:25px 6% 35px;gap:20px}footer p{order:3;max-width:none}footer>span{margin-left:auto;align-self:center}.legal{margin-top:42px}.legal h1{font-size:40px}.editor-header{gap:8px;padding:7px 10px}.editor-header .site-tabs{order:3;width:100%}.editor-controls{gap:5px;flex:1;justify-content:flex-end}.editor-controls select{width:95px;font-size:10px;padding:5px}.tool-button{padding:5px 7px;font-size:10px}.editor-header .brand{font-size:17px}.editor-header .brand-suffix,.editor-header .brand-mark{display:none}.editor-note{font-size:9px;padding:5px 10px}.editor-note a{display:none}#fullscreen-button{display:inline-flex}}@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}*,*:before,*:after{animation:none!important;transition:none!important}}

/* Mobile workspace: keep the canvas, not desktop control rows, as the primary surface. */
.editor-options{display:contents;border:0;padding:0}.editor-options>summary{display:none}.editor-option-body{display:flex;gap:8px;align-items:center}.editor-mobile-hint{display:none}
@media(max-width:720px){
  .editor-page{height:100dvh;height:var(--editor-viewport-height,100dvh);padding-top:env(safe-area-inset-top);padding-bottom:env(safe-area-inset-bottom)}
  .editor-header{position:relative;display:grid;grid-template-columns:1fr;gap:4px;padding:6px 8px;min-height:0}
  .editor-header .brand{font-size:16px;line-height:20px}.editor-header .site-tabs{order:3;width:100%;padding:2px;gap:2px}.editor-header .site-tabs a{padding:5px 4px;font-size:10px}
  .editor-controls{justify-content:flex-start;gap:4px;min-width:0;flex-wrap:nowrap;grid-row:2}.editor-controls>.tool-button{display:flex;align-items:center;justify-content:center;min-height:40px;padding:7px 8px;font-size:11px;white-space:nowrap;flex:1;min-width:0}.editor-controls>label{cursor:pointer}
  .editor-controls>[data-account-link]{max-width:14ch}
  .editor-options{display:block;flex:0 0 40px;margin:0}.editor-options>summary{display:flex;align-items:center;justify-content:center;height:40px;padding:4px;font-size:14px}.editor-options>summary::-webkit-details-marker{display:none}.editor-options>summary:after{content:none}
  .editor-option-body{display:none;position:absolute;top:72px;right:8px;width:min(320px,calc(100vw - 16px));max-height:60dvh;overflow:auto;background:var(--paper);border:1px solid var(--line);padding:14px;z-index:20;box-shadow:0 8px 24px #0003;flex-wrap:wrap;gap:12px}
  .editor-options[open]>.editor-option-body{display:flex}.editor-option-body .tool-button,.editor-option-body select{min-height:40px;font-size:12px;width:auto}.editor-mobile-hint{display:block;font-size:11px;color:var(--muted);line-height:1.5}
  .editor-note{display:none}.editor-stage{min-height:120px}.cloud-feedback{bottom:max(12px,env(safe-area-inset-bottom))}
}

@media(max-width:720px){.editor-controls>.tool-button>span{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.editor-option-body .language-picker select{font-size:16px;max-width:100%}}

.editor-page[data-immersive="true"] .editor-header{position:fixed;bottom:env(safe-area-inset-bottom);right:4px;z-index:30;width:auto;min-height:0;padding:2px;display:block;border:0}
.editor-page[data-immersive="true"] .editor-header>:not(.editor-controls),.editor-page[data-immersive="true"] .editor-controls>:not(#fullscreen-button),.editor-page[data-immersive="true"] .editor-note{display:none}
.editor-page[data-immersive="true"] #fullscreen-button{min-height:36px;background:var(--paper);font-size:11px;max-width:140px;overflow:hidden;text-overflow:ellipsis}

/* Real program-download progress; initialization has separate text, not a fabricated percentage. */
#load-progress{display:block;width:min(100%,320px);height:8px;margin:20px auto 8px;appearance:none;-webkit-appearance:none;border:0;border-radius:4px;background:#47524d;color:var(--accent)}
#load-progress::-webkit-progress-bar{background:#47524d;border-radius:4px}#load-progress::-webkit-progress-value{background:var(--accent);border-radius:4px}#load-progress::-moz-progress-bar{background:var(--accent);border-radius:4px}
#load-progress-label{font-variant-numeric:tabular-nums;color:#f7f6f1;font-weight:600;margin-bottom:12px}.loading-overlay[data-state="failed"] .spinner{display:none}.loading-inner #load-error{color:#ffc5a5;margin-top:12px}.loading-inner #compatibility-button{margin-left:8px}.loading-inner button[hidden]{display:none}
@media(max-width:720px){.loading-overlay{padding:20px}.loading-inner button{min-height:44px;padding:10px 12px}.loading-inner #compatibility-button{margin-left:4px}}

/* Public source and support context for answer engines and visitors. */
.faq-section summary h3{margin:0;font:inherit;letter-spacing:inherit}.source-section{background:#f1f1eb}.source-body{flex:1;max-width:590px}.byline{font:11px/1.7 var(--mono);letter-spacing:.2px;color:var(--muted);margin-bottom:25px}.source-body blockquote{margin:0;padding:22px 24px;border-left:3px solid var(--accent);background:var(--white)}.source-body blockquote p{font-size:16px;line-height:1.65;color:var(--ink)}.source-body cite{display:block;margin-top:13px;font-size:12px;font-style:normal;color:var(--muted)}.source-body a{color:var(--ink);text-decoration:underline;text-underline-offset:3px}.source-body ul{margin:22px 0 0;padding-left:18px;color:var(--muted);font-size:14px;line-height:2}@media(max-width:720px){.source-body{margin-top:33px}.source-body blockquote{padding:18px}.source-body blockquote p{font-size:15px}}
/* Native RTL shell; CAD coordinates, code and drawing canvas keep their LTR axis. */
html[dir="rtl"] .header-actions{margin-left:0;margin-inline-start:auto}
html[dir="rtl"] .source-body blockquote{border-left:0;border-inline-start:3px solid var(--accent)}
html[dir="rtl"] .source-body ul{padding-left:0;padding-inline-start:18px}
html[dir="rtl"] .eyebrow{letter-spacing:0}
html[dir="rtl"] .terminal,html[dir="rtl"] .editor-stage,html[dir="rtl"] code,html[dir="rtl"] pre{direction:ltr;text-align:left}
html[dir="rtl"] input[type="email"],html[dir="rtl"] input[type="url"]{direction:ltr;text-align:left}

/* CADCraft UI theme — append to the base styles bundle.
   LookRoll reference verified 2026-11-05: DM Sans, #d5fa83 accent,
   charcoal neutrals, 9–15px controls, 14px tiles, 20px pricing cards.
   Light-surface adaptation: preserve all DOM, behavior and native CAD iframe.
   Specificity intentionally survives account/AI/admin styles loaded afterward. */

html:root {
  --paper: #f8f9f6;
  --ink: #171a16;
  --muted: #60665d;
  --line: #dde2d8;
  --accent: #49651b;
  --white: #ffffff;
  --sans: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --theme-lime: #d5fa83;
  --theme-lime-hover: #c5ed6f;
  --theme-lime-soft: #f0f8e3;
  --theme-panel: #ffffff;
  --theme-soft: #f0f3ec;
  --theme-dark: #151518;
  --theme-error: #9b3028;
  --theme-error-soft: #fff1ed;
  --theme-focus: #415a12;
  --theme-radius: 20px;
  --theme-control-radius: 11px;
  --theme-shadow: 0 8px 30px rgb(24 33 15 / 5%), 0 1px 3px rgb(24 33 15 / 3%);
  --theme-shadow-raised: 0 18px 50px rgb(24 33 15 / 9%), 0 2px 6px rgb(24 33 15 / 4%);
  --admin-paper: var(--paper);
  --admin-panel: var(--theme-panel);
  --admin-ink: var(--ink);
  --admin-muted: var(--muted);
  --admin-line: var(--line);
  --admin-line-dark: #b7c2ac;
  --admin-pine: #49651b;
  --admin-pine-dark: #334a11;
  --admin-wash: var(--theme-lime-soft);
  --admin-alert: var(--theme-error);
  --admin-alert-wash: var(--theme-error-soft);
  --admin-orange: var(--theme-focus);
  --admin-sans: var(--sans);
}

body {
  background: var(--paper);
  color: var(--ink);
  text-rendering: optimizeLegibility;
}
body :is(h1, h2, h3) { text-wrap: balance; }
body :is(p, li) { overflow-wrap: break-word; }
body :is(button, a, summary, input, select, textarea) {
  transition: background-color .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease;
}
/* Two-tone ring: dark outer outline on light surfaces; white inner ring on dark. */
body :is(a, button, summary, input, select, textarea, label[tabindex]):focus-visible,
body .wai-panel :is(button, a, input, textarea, summary):focus-visible,
body #wai-sessions :is(button, summary):focus-visible,
body .billing-page :focus-visible {
  outline: 3px solid var(--theme-focus);
  outline-offset: 3px;
  box-shadow: 0 0 0 3px #fff;
}
body :is(input, textarea, select) {
  color: var(--ink);
  background-color: var(--theme-panel);
  border-color: #b8c4ac;
  border-radius: var(--theme-control-radius);
  accent-color: var(--accent);
}
body :is(input, textarea)::placeholder { color: #686e64; opacity: 1; }
body :is(.account-panel input, .ai-conversation textarea, .admin-dialog textarea):focus {
  border-color: var(--accent);
  outline: 3px solid var(--theme-focus);
  outline-offset: 3px;
}
body :is(.skip, .admin-skip) { border-radius: 10px; background: var(--theme-dark); color: #fff; }

/* Brand and shared navigation — engineering identity is retained. */
body .site-header {
  padding: 20px clamp(20px, 4.8vw, 72px);
  gap: 20px;
  background: rgb(248 249 246 / 96%);
  border-color: var(--line);
}
body .brand { font-weight: 700; letter-spacing: -.055em; }
body .brand-mark { color: var(--accent); }
body .brand-suffix { color: var(--muted); margin-left: 0; margin-inline-start: 4px; }
body .site-tabs {
  background: var(--theme-soft);
  border: 1px solid var(--line);
  border-radius: 14px;
  gap: 3px;
}
body .site-tabs a {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  color: #596151;
  border-radius: 10px;
  padding: 8px 12px;
}
body .site-tabs a:hover { background: #e4ebda; color: var(--ink); }
body .site-tabs a.active { background: var(--theme-dark); color: #fff; }
body .header-actions { min-inline-size: 0; gap: 14px; }
body .account-link { color: var(--ink); border-radius: 8px; }
body .account-link:hover { color: var(--accent); }
body .language-picker select {
  background-color: var(--theme-panel);
  border-color: var(--line);
  border-radius: 10px;
  font-family: var(--sans);
  font-size: 12px;
  padding-block: 8px;
  padding-inline: 10px 25px;
}
body :is(.button, .small-button) {
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--theme-lime);
  color: #14160c;
  font-weight: 700;
  box-shadow: 0 4px 14px rgb(94 127 31 / 9%);
  justify-content: center;
}
body .button { font-size: 14px; padding: 15px 24px; gap: 18px; }
body .small-button { font-size: 13px; padding: 10px 17px; gap: 12px; }
body :is(.button, .small-button):hover:not(:disabled):not([aria-disabled="true"]) {
  background: var(--theme-lime-hover);
  color: #14160c;
  box-shadow: 0 6px 20px rgb(94 127 31 / 14%);
  transform: none;
}
body .button.outline { background: var(--theme-panel); color: var(--ink); border-color: #b8c4ac; box-shadow: none; }
body .button.outline:hover:not(:disabled) { background: var(--theme-lime-soft); }
body .text-link { font-size: 14px; font-weight: 600; color: var(--ink); border-radius: 6px; }
body .text-link:hover { color: var(--accent); }

/* Homepage: generous editorial copy beside the original engineering preview. */
body .hero {
  padding: 82px clamp(20px, 4.8vw, 72px) 92px;
  gap: 5%;
  min-height: 640px;
  background: radial-gradient(ellipse at 90% 35%, rgb(213 250 131 / 15%), transparent 58%);
}
body .hero-copy { width: 43%; min-inline-size: 0; }
body .hero h1 { font-size: clamp(44px, 4.8vw, 72px); font-weight: 600; letter-spacing: -.06em; line-height: 1.05; }
body .hero h1 em { color: var(--accent); }
body .eyebrow { color: var(--accent); font-size: 11px; letter-spacing: .08em; margin-bottom: 22px; }
body .live-dot { width: 7px; height: 7px; background: var(--accent); box-shadow: 0 0 0 5px rgb(213 250 131 / 40%); }
body .lead { color: var(--muted); font-size: 17px; line-height: 1.85; margin-top: 24px; }
body .hero-actions { margin-top: 30px; gap: 22px; }
body .checks { font-size: 12px; line-height: 1.7; color: var(--muted); gap: 12px 20px; }
body .checks b { color: var(--accent); margin-right: 0; margin-inline-end: 4px; }
body .hero-preview {
  width: 52%;
  min-inline-size: 0;
  transform: none;
  border: 1px solid #30333b;
  border-radius: 22px;
  background: #22282f;
  box-shadow: 0 24px 65px rgb(21 21 24 / 16%), 0 2px 6px rgb(21 21 24 / 8%);
}
body .preview-title { border-radius: 21px 21px 0 0; color: #d5d9e1; background: var(--theme-dark); padding: 13px 16px; font-size: 9px; }
body .preview-dots { color: #abb1bc; }
body .hero-preview figcaption { border-radius: 0 0 21px 21px; background: var(--theme-dark); color: #d5d9e1; font-size: 11px; line-height: 1.65; padding: 12px 16px; }
body .preview-stamp {
  bottom: -22px;
  right: auto;
  inset-inline-end: 20px;
  transform: none;
  border-radius: 16px;
  background: var(--theme-lime);
  color: #14160c;
  border: 1px solid rgb(20 22 12 / 10%);
  box-shadow: 0 8px 24px rgb(24 33 15 / 12%);
}
body .preview-stamp span { font-weight: 600; }
body .preview-stamp small { letter-spacing: .06em; }
body .spec-strip {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--theme-panel);
  padding: 25px 28px;
  box-shadow: var(--theme-shadow);
}
body .spec-strip > span { font-size: 13px; gap: 14px; min-inline-size: 0; }
body .spec-strip small { color: var(--accent); font-size: 10px; }
body .section { padding-block: 92px; gap: 8%; border-color: var(--line); }
body .section h2 { font-size: clamp(32px, 3.2vw, 46px); font-weight: 600; line-height: 1.15; letter-spacing: -.045em; }
body .section h3 { font-size: 21px; font-weight: 600; line-height: 1.35; }
body .subnote { color: var(--muted); line-height: 1.85; }
body .feature-list { display: grid; gap: 16px; min-inline-size: 0; }
body .feature-list article,
body .feature-list article:first-child,
body .feature-list article:last-child {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 24px;
  background: var(--theme-panel);
  box-shadow: var(--theme-shadow);
  gap: 18px;
}
body .feature-number { border-radius: 8px; color: var(--accent); font-weight: 600; }
body .feature-list p, body .steps p { font-size: 14px; color: var(--muted); line-height: 1.85; }
body .guide-section { background: transparent; }
body .guide-body { gap: 8%; }
body .steps li { padding-left: 0; padding-inline-start: 56px; padding-bottom: 30px; }
body .steps li::before {
  left: auto;
  inset-inline-start: 0;
  border: 1px solid #c8dda9;
  border-radius: 10px;
  background: var(--theme-lime-soft);
  color: var(--accent);
  padding: 8px 9px;
}
body .terminal { background: var(--theme-dark); color: #f4f4f5; border: 1px solid #30333b; border-radius: 20px; box-shadow: var(--theme-shadow-raised); }
body .terminal p { color: #c9ced3; border-color: #3a3a40; }
body .terminal pre { color: #f4f4f5; }
body .terminal pre span { color: #bdc3ce; }
body .terminal small { color: #c9ced3; }
body .terminal a { color: var(--theme-lime); border-radius: 5px; }
body .faq-section details { border-color: var(--line); padding-block: 21px; }
body .faq-section summary { font-weight: 600; font-size: 16px; line-height: 1.5; border-radius: 6px; }
body .faq-section details p { color: var(--muted); line-height: 1.85; }
body .faq-section summary > span { color: var(--accent); flex-shrink: 0; }
body .source-section { background: transparent; }
body .source-body { min-inline-size: 0; }
body .source-body blockquote { background: var(--theme-panel); border-radius: 0 16px 16px 0; box-shadow: var(--theme-shadow); border-inline-start-color: var(--accent); }
body .source-body blockquote p { color: var(--ink); }
body .source-body :is(cite, ul, .byline) { color: var(--muted); }
body .source-body a { color: var(--accent); }
body .closing { border-radius: 26px; background: var(--theme-dark); color: #f4f4f5; padding: 50px 44px; box-shadow: var(--theme-shadow-raised); }
body .closing h2 { font-weight: 600; line-height: 1.18; }
body .closing p:not(.eyebrow), body .closing .eyebrow { color: #c9ced3; }
body .closing .button.light { background: var(--theme-lime); color: #14160c; }
body footer { padding: 35px clamp(20px, 4.8vw, 72px) 42px; border-color: var(--line); gap: 30px; }
body footer p { font-size: 12px; color: var(--muted); min-inline-size: 0; overflow-wrap: anywhere; }
body footer p a { white-space: normal; text-underline-offset: 3px; }
body footer > span { font-size: 11px; color: var(--muted); }
body .legal { max-width: 900px; padding-inline: 28px; }
body .legal h1 { font-weight: 600; line-height: 1.15; }
body .legal h2 { font-weight: 600; }
body .legal :is(p, li) { color: var(--muted); line-height: 1.85; }
body .legal a { color: var(--accent); text-underline-offset: 3px; overflow-wrap: anywhere; }

/* Sign-in and private cloud files. IDs and auth visibility are untouched. */
body .account-main { padding-block: 78px 100px; gap: clamp(36px, 6vw, 84px); }
body .account-intro { min-inline-size: 0; }
body .account-intro h1 { font-weight: 600; letter-spacing: -.055em; line-height: 1.08; }
body .account-intro p { color: var(--muted); }
body .account-panel { background: var(--theme-panel); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--theme-shadow-raised); padding: 34px; }
body .account-panel h2 { font-weight: 600; }
body .account-panel input { border-radius: 12px; border-color: #b8c4ac; color: var(--ink); background: var(--theme-panel); }
body .account-divider { color: var(--muted); }
body .account-divider::before, body .account-divider::after { background: var(--line); }
body .account-fine { color: var(--muted); }
body .account-fine a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
body .account-message { border-radius: 12px; background: var(--theme-lime-soft); color: #334a11; border: 1px solid #d3e3bb; }
body .account-message[data-error="true"] { background: var(--theme-error-soft); border-color: #efc5bf; color: var(--theme-error); }
body .cloud-main { max-width: 1200px; padding-block: 58px 90px; }
body .cloud-heading { align-items: center; border-color: var(--line); gap: 24px; padding-bottom: 30px; }
body .cloud-heading h1 { font-size: clamp(32px, 4vw, 48px); font-weight: 600; line-height: 1.15; }
body .cloud-heading p { color: var(--muted); overflow-wrap: anywhere; }
body .cloud-intro { border-left: 0; border-inline-start: 3px solid var(--accent); border-radius: 0 14px 14px 0; background: var(--theme-lime-soft); color: #3d5420; margin-top: 22px; }
body .cloud-file-row { margin-block: 12px; padding: 22px 24px; gap: 22px; border: 1px solid var(--line); border-radius: 16px; background: var(--theme-panel); box-shadow: var(--theme-shadow); }
body .cloud-file-row > :first-child { min-inline-size: 0; }
body .cloud-file-row p { color: var(--muted); }
body .cloud-file-actions { gap: 18px; }
body .cloud-file-actions a { color: var(--accent); font-size: 13px; font-weight: 600; }
body .cloud-feedback { inset-inline: 24px auto; left: auto; right: auto; background: var(--theme-panel); color: var(--ink); border: 1px solid #bac9aa; border-radius: 16px; box-shadow: var(--theme-shadow-raised); }
body .cloud-feedback[data-error="true"] { color: var(--theme-error); border-color: #db9690; }
body .cloud-feedback button { margin-left: 0; margin-inline-start: 14px; color: var(--accent); }
body :is(.tool-button, .editor-controls select) { border-radius: 9px; background-color: var(--theme-panel); border-color: #cdd7c3; color: var(--ink); }
body .tool-button:hover:not(:disabled):not([aria-disabled="true"]) { background: var(--theme-lime-soft); border-color: #b4cc95; color: var(--ink); }
body .cloud-save-button[data-armed="true"] { background: var(--theme-lime); color: #14160c; border-color: #bdd879; }

/* Billing and existing AI screens. Stronger selectors allow later ai.css loads. */
body.ai-page .ai-heading { border-color: var(--line); gap: 28px; padding-bottom: 30px; }
body.ai-page .ai-heading h1 { font-size: clamp(32px, 4vw, 48px); font-weight: 600; line-height: 1.15; letter-spacing: -.045em; }
body.ai-page .ai-section-links { gap: 18px; }
body.ai-page .ai-section-links a { color: var(--accent); font-weight: 600; border-radius: 6px; }
body.ai-page .ai-eyebrow { color: var(--accent); }
body.ai-page .ai-account-chip { border-left: 0; border-inline-start: 1px solid var(--line); padding-left: 0; padding-inline-start: 24px; color: var(--muted); }
body.ai-page .ai-account-chip strong { color: var(--ink); }
body :is(.ai-button, .wai-button, .wai-toggle) { border-radius: 11px; border-color: #bedb88; background: var(--theme-lime); color: #14160c; box-shadow: none; }
body :is(.ai-button, .wai-button, .wai-toggle):hover:not(:disabled):not([aria-disabled="true"]) { background: var(--theme-lime-hover); color: #14160c; border-color: #adc771; }
body :is(.ai-button.quiet, .wai-button.wai-quiet) { background: var(--theme-panel); color: var(--ink); border-color: #c8d3bd; }
body :is(.ai-button.quiet, .wai-button.wai-quiet):hover:not(:disabled) { background: var(--theme-lime-soft); color: var(--ink); border-color: #aec58f; }
body :is(.ai-link, .wai-link) { color: var(--accent); border-radius: 5px; text-align: start; }
body.ai-page .ai-link.danger { color: var(--theme-error); }
body.ai-page .ai-notice { background: var(--theme-lime-soft); border-left: 0; border-inline-start: 3px solid var(--accent); border-radius: 0 12px 12px 0; color: #3d5420; }
body.ai-page .ai-notice.warning { background: #fff6e5; color: #70500c; border-color: #967220; }
body.ai-page .ai-status { color: var(--muted); }
body.ai-page .ai-status[data-error="true"] { color: var(--theme-error); }
body.ai-page .ai-workspace { border-color: var(--line); border-radius: 20px; background: var(--theme-panel); box-shadow: var(--theme-shadow); }
body.ai-page .ai-projects { border-color: var(--line); background: var(--theme-soft); border-start-start-radius: 20px; border-end-start-radius: 20px; }
body.ai-page .ai-project-item { color: var(--ink); border-radius: 9px; border-left: 0; border-inline-start: 2px solid transparent; text-align: start; }
body.ai-page .ai-project-item:hover { background: #e5edd9; }
body.ai-page .ai-project-item.active { background: var(--theme-panel); border-inline-start-color: var(--accent); }
body.ai-page .ai-message.user { background: var(--theme-lime-soft); border-radius: 14px; }
body.ai-page .ai-message.assistant { border-left: 0; border-inline-start: 2px solid var(--accent); padding-left: 0; padding-inline-start: 14px; }
body.ai-page .ai-conversation textarea { background: var(--theme-panel); color: var(--ink); border-color: #b8c4ac; border-radius: 12px; }
body.ai-page .ai-table-scroll { border-color: var(--line); border-radius: 14px; background: var(--theme-panel); }
body.ai-page th { background: var(--theme-soft); color: var(--muted); text-align: start; }
body.ai-page :is(th, td) { border-color: var(--line); }
body.ai-page .ai-stat { background: var(--theme-panel); border-color: var(--line); border-radius: 16px; box-shadow: var(--theme-shadow); }
body.ai-page .ai-admin-filter :is(input, select) { border-radius: 10px; border-color: #b8c4ac; color: var(--ink); background: var(--theme-panel); }
body.ai-page .ai-billing-state[data-state="paid"] { color: #426018; }
body.ai-page .ai-billing-state:is([data-state="failed"], [data-state="expired"]) { color: var(--theme-error); }
body.billing-page .ai-main { max-width: 1340px; padding-block: 52px 76px; }
body.billing-page .ai-pricing { padding-top: 40px; }
body.billing-page .ai-pricing > h2 { font-weight: 600; }
body.billing-page .ai-pricing-switch { border-color: var(--line); border-radius: 999px; background: var(--theme-soft); padding: 5px; gap: 4px; margin-block: 30px 40px; }
body.billing-page .ai-pricing-switch button { border-radius: 999px; color: var(--ink); }
body.billing-page .ai-pricing-switch button:hover:not(:disabled) { background: #e4ebda; }
body.billing-page .ai-pricing-switch button[aria-pressed="true"] { background: var(--theme-dark); color: #fff; box-shadow: 0 2px 6px rgb(21 21 24 / 12%); }
body.billing-page .ai-pricing-switch button:focus-visible { outline: 3px solid var(--theme-focus); outline-offset: 3px; box-shadow: 0 0 0 3px #fff; }
body.billing-page .ai-save-badge { border: 0; border-radius: 999px; background: var(--theme-lime); color: #14160c; font-weight: 700; padding: 3px 7px; }
body.billing-page :is(.ai-plan-grid, .ai-topup-grid) { gap: 24px; }
body.billing-page .ai-plan,
body.billing-page .ai-plan:nth-child(2) {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--theme-panel);
  box-shadow: var(--theme-shadow);
  padding: 30px 26px;
}
body.billing-page .ai-plan:nth-child(2):not(.ai-topup) {
  border: 1px solid #a9c777;
  background: linear-gradient(145deg, #f0f8e3 0%, #fff 58%);
  box-shadow: 0 10px 35px rgb(78 108 32 / 10%);
}
body.billing-page .ai-plan h3 { font-size: 23px; font-weight: 600; }
body.billing-page .ai-price { font-family: var(--sans); font-size: clamp(28px, 2.8vw, 38px); font-weight: 700; letter-spacing: -.05em; }
body.billing-page .ai-price small { color: var(--muted); margin-left: 0; margin-inline-start: 7px; font-size: 12px; font-weight: 400; }
body.billing-page .ai-plan .ai-drawing-estimate { color: var(--accent); font-size: 17px; font-weight: 600; }
body.billing-page .ai-plan-features { border-color: var(--line); color: var(--ink); }
body.billing-page .ai-plan-features li::before { color: var(--accent); }
body.billing-page .ai-plan .ai-button { border-radius: 999px; background: var(--theme-lime); color: #14160c; font-weight: 700; }
body.billing-page .ai-plan .ai-button:hover:not(:disabled) { background: var(--theme-lime-hover); }
body.billing-page .ai-topup .ai-button.quiet { background: var(--theme-panel); border-color: #b4c59c; color: var(--ink); }
body.billing-page .ai-topup .ai-button.quiet:hover:not(:disabled) { background: var(--theme-lime-soft); }
body.billing-page .ai-popular { border-radius: 999px; background: var(--theme-lime); color: #14160c; border: 1px solid #bedb88; padding: 5px 12px; font-weight: 700; box-shadow: 0 3px 8px rgb(78 108 32 / 8%); }
body.billing-page .ai-plan-notes details { border-radius: 10px; }
body.billing-page :is(.ai-payment-history, .ai-ledger) { border-color: var(--line); }

/* Editor shell only. No dimensions, display, position or native canvas overrides. */
body.editor-page .editor-header { background: var(--paper); border-block-end: 1px solid var(--line); }
body.editor-page .editor-header .site-tabs { border-radius: 10px; background: var(--theme-soft); border-color: var(--line); }
body.editor-page .editor-header .site-tabs a { border-radius: 7px; }
body.editor-page .editor-note { background: #edf2e6; color: #49563d; }
body.editor-page .editor-option-body { border-radius: 14px; background: var(--theme-panel); border-color: var(--line); box-shadow: var(--theme-shadow-raised); }
body.editor-page .loading-inner { color: #f4f4f5; }
body.editor-page .loading-inner p { color: #c9ced3; }
body.editor-page .loading-inner .tool-button { background: #30333b; color: #f4f4f5; border-color: #677079; }
body.editor-page .loading-inner .tool-button:hover:not(:disabled) { background: var(--theme-lime); color: #14160c; border-color: var(--theme-lime); }
body.editor-page #load-progress { color: var(--theme-lime); }
body.editor-page #load-progress::-webkit-progress-value { background: var(--theme-lime); }
body.editor-page #load-progress::-moz-progress-bar { background: var(--theme-lime); }
body.editor-page .spinner { border-color: #52606c; border-top-color: var(--theme-lime); }
body.editor-page .loading-inner #load-error { color: #ffc4bc; }

/* Assistant and session rail: color, borders, radius and shadow ONLY.
   Parent owns all sizing, scroll, composer and conversation layouts. */
body .wai-panel { background: var(--theme-panel); color: var(--ink); border-color: var(--line); }
body .wai-header { background: var(--theme-soft); border-color: var(--line); }
body .wai-header h2 { color: var(--ink); }
body .wai-notice { border-color: var(--accent); border-radius: 0 10px 10px 0; background: var(--theme-lime-soft); color: #3d5420; }
body .wai-status[data-error="true"] { color: var(--theme-error); }
body .wai-modes label { border-radius: 10px; border-color: var(--line); background: var(--theme-panel); color: var(--ink); }
body .wai-modes label:has(input:checked) { border-color: #a9c777; background: var(--theme-lime-soft); }
body .wai-modes input { accent-color: var(--accent); }
body .wai-message.user { background: var(--theme-lime-soft); color: var(--ink); border-radius: 13px; }
body .wai-message.assistant { border-color: var(--accent); color: var(--ink); }
body .wai-pending { background-color: var(--theme-panel); background-image: none; border-color: #c0d0ab; border-inline-start-color: var(--accent); border-radius: 12px; }
body .wai-preview-viewport { border-color: var(--line); border-radius: 10px; }
body .wai-panel textarea { border-color: #b8c4ac; border-radius: 12px; background: var(--theme-panel); color: var(--ink); }
body .wai-coachmark { background: var(--theme-panel); color: var(--ink); border-color: #b7c99d; border-radius: 16px; box-shadow: var(--theme-shadow-raised); }
body .wai-coachmark-close { color: var(--ink); border-radius: 9px; }
body .wai-history-versions li { border-color: var(--line); border-radius: 10px; }
body .wai-history-versions time { color: var(--muted); }
body .wai-eta { background: var(--theme-lime-soft); color: #3d5420; border-radius: 9px; }
body #wai-sessions { background: var(--paper); color: var(--ink); border-color: var(--line); }
body #wai-session-list .wai-session-row { background: var(--theme-panel); color: var(--ink); border-color: var(--line); border-radius: 10px; }
body #wai-session-list .wai-session-row[aria-current="true"] { border-color: #a9c777; background: var(--theme-lime-soft); box-shadow: inset 3px 0 var(--accent); }
body #wai-sessions[dir="rtl"] .wai-session-row[aria-current="true"] { box-shadow: inset -3px 0 var(--accent); }
body #wai-session-list .wai-session-row:hover:not(:disabled) { background: #e5efda; }

/* Administration shares the same visual system without changing data tables. */
body.admin-page { background: var(--paper); color: var(--ink); }
body.admin-page :is(.admin-header, .admin-tabs-wrap) { background: var(--paper); border-color: var(--line); }
body.admin-page .admin-sidebar { background: var(--theme-soft); border-color: var(--line); }
body.admin-page :is(.admin-top-tabs, .admin-nav-item) { border-radius: 11px; }
body.admin-page .admin-top-tabs { background: var(--theme-soft); border-color: var(--line); }
body.admin-page .admin-nav-item { color: var(--ink); text-align: start; }
body.admin-page .admin-nav-item:hover:not(.is-active) { background: #e4ebda; border-color: #b8cba1; }
body.admin-page .admin-nav-item.is-active { background: var(--theme-dark); color: #fff; border-color: var(--theme-dark); }
body.admin-page :is(.admin-state-card, .admin-detail, .admin-dialog) { background: var(--theme-panel); border-color: var(--line); border-radius: 20px; box-shadow: var(--theme-shadow-raised); }
body.admin-page .admin-dialog::backdrop { background: rgb(21 21 24 / 55%); }
body.admin-page :is(.admin-primary-button, .admin-primary-link) { border-radius: 999px; background: var(--theme-lime); border-color: #bedb88; color: #14160c !important; }
body.admin-page :is(.admin-primary-button, .admin-primary-link):hover:not(:disabled) { background: var(--theme-lime-hover); transform: none; }
body.admin-page :is(.admin-secondary-button, .admin-pagination button, .admin-search-form button, .admin-filter-form > button:not(.admin-quiet-button)) { border-radius: 10px; background: var(--theme-panel); border-color: #b8c4ac; color: var(--ink); }
body.admin-page :is(.admin-search-form input, .admin-filter-form input, .admin-dialog textarea) { background: var(--theme-panel); border-color: #b8c4ac; border-radius: 10px; color: var(--ink); }
body.admin-page .admin-table-scroll { border: 1px solid var(--line); border-radius: 14px; background: var(--theme-panel); }
body.admin-page .admin-table th { background: var(--theme-soft); color: var(--muted); border-color: var(--line); text-align: start; }
body.admin-page .admin-table td { border-color: var(--line); }
body.admin-page .admin-table tbody tr:hover { background: var(--theme-lime-soft); }
body.admin-page .admin-avatar { border-radius: 10px; border-color: #bbcf9d; background: var(--theme-lime-soft); color: var(--accent); }
body.admin-page .admin-message { border-color: var(--line); border-radius: 14px; background: var(--theme-panel); }
body.admin-page .admin-message.is-inbound { border-left: 0; border-inline-start: 3px solid var(--accent); }
body.admin-page .admin-message.is-outbound { border-left: 0; border-inline-start: 3px solid #b7c2ac; }
body.admin-page .admin-mail-text { color: var(--ink); background: var(--theme-soft); border-radius: 10px; }
body.admin-page .admin-thread-button { border-radius: 10px; text-align: start; }
body.admin-page .admin-thread-button:hover { background: var(--theme-lime-soft); }
body.admin-page .admin-thread-button.is-active { background: var(--theme-dark); color: #fff; }
body.admin-page .admin-thread-button.is-active .admin-thread-summary span { color: #c9ced3; }
body.admin-page .admin-attachment { background: var(--theme-soft); border-radius: 10px; }
body.admin-page .admin-recipient-list { border-left: 0; border-inline-start: 3px solid var(--accent); background: var(--theme-lime-soft); border-radius: 0 10px 10px 0; }

/* State remains semantic: no display, pointer-events or editability changes. */
body :is(button, input, select, textarea):disabled,
body :is(.button, .ai-button, .wai-button, .tool-button, .wai-toggle)[aria-disabled="true"],
body .account-panel button:disabled,
body .wai-panel :is(button, textarea):disabled,
body #wai-sessions button:disabled,
body.admin-page button:disabled {
  background-color: #e9ede3;
  color: #60665d;
  border-color: #cad2c1;
  opacity: .72;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}
body :is(.ai-link, .wai-link):disabled { background: transparent; color: #6b7066; }

/* Multilingual flow and narrow public pages — no global overflow hiding. */
html[dir="rtl"] body .source-body blockquote,
html[dir="rtl"] body :is(.cloud-intro, .ai-notice, .wai-notice, .admin-recipient-list) { border-radius: 14px 0 0 14px; }
html[dir="rtl"] body .header-actions { margin-left: 0; margin-inline-start: auto; }
html[dir="rtl"] body :is(.eyebrow, .ai-eyebrow) { letter-spacing: 0; }
@media (max-width: 1100px) {
  body .hero { padding-block: 62px 78px; gap: 4%; }
  body .hero-copy { width: 46%; }
  body .hero-preview { width: 50%; }
  body .hero h1 { font-size: clamp(42px, 5.4vw, 58px); }
  body .lead { font-size: 16px; }
  body .site-header { gap: 16px; }
  body .site-header .site-tabs a { padding-inline: 10px; }
  body .section { gap: 6%; }
  body.billing-page :is(.ai-plan-grid, .ai-topup-grid) { gap: 16px; }
  body.billing-page .ai-plan { padding-inline: 20px; }
}
@media (max-width: 850px) {
  body .account-main { padding: 48px 24px 70px; }
  body .account-panel { margin-top: 34px; }
  body .cloud-main { padding: 40px 24px 70px; }
  body .cloud-heading { display: block; }
  body .cloud-heading .button { margin-top: 18px; }
  body .cloud-file-row { padding: 20px; gap: 16px; }
  body .cloud-feedback { inset-inline: 12px; }
}
@media (max-width: 740px) {
  body.billing-page :is(.ai-plan-grid, .ai-topup-grid) { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  body.billing-page .ai-plan,
  body.billing-page .ai-plan:nth-child(2) { padding: 28px 24px; }
  body.billing-page .ai-price { font-size: 35px; }
  body.billing-page .ai-pricing-switch { border-radius: 18px; margin-block: 24px 34px; }
  body.billing-page .ai-pricing-switch button { border-radius: 13px; }
  body.billing-page .ai-account-chip { border-inline-start: 0; padding-inline-start: 0; }
}
@media (max-width: 720px) {
  body .site-header { padding: 16px 20px; gap: 12px; }
  body .site-header .brand { font-size: 22px; }
  body .site-header .header-actions { margin-left: 0; margin-inline-start: auto; gap: 10px; }
  body .site-header .site-tabs { min-inline-size: 0; max-inline-size: 100%; overflow-x: auto; overflow-y: hidden; overscroll-behavior-inline: contain; scrollbar-width: thin; padding: 4px; }
  body .site-header .site-tabs a { flex: 1 0 auto; padding: 8px 12px; font-size: 12px; }
  body .site-header .language-picker select { max-inline-size: 108px; }
  body .hero { display: block; min-height: 0; padding: 48px 20px 66px; }
  body .hero-copy { width: 100%; }
  body .hero h1 { font-size: clamp(38px, 10.5vw, 58px); line-height: 1.08; }
  body .lead { font-size: 16px; }
  body .hero-actions { gap: 20px; }
  body .checks { gap: 10px 15px; font-size: 11px; }
  body .hero-preview { width: 100%; margin-top: 38px; border-radius: 18px; transform: none; }
  body .preview-title { border-radius: 17px 17px 0 0; font-size: 8px; padding: 11px 12px; }
  body .hero-preview figcaption { border-radius: 0 0 17px 17px; padding: 11px 12px; font-size: 10px; }
  body .preview-stamp { padding: 11px 14px; bottom: -20px; inset-inline-end: 14px; min-width: 98px; }
  body .preview-stamp span { font-size: 24px; }
  body .spec-strip { margin-inline: 20px; padding: 22px 18px; gap: 16px; }
  body .spec-strip > span { width: calc(50% - 8px); font-size: 11px; gap: 8px; }
  body .section { margin-inline: 20px; padding: 55px 0; }
  body .section h2 { font-size: 32px; }
  body .feature-list { margin-top: 28px; }
  body .feature-list article,
  body .feature-list article:first-child,
  body .feature-list article:last-child { padding: 21px 18px; gap: 14px; }
  body .section h3 { font-size: 19px; }
  body .terminal { padding: 24px; }
  body .terminal pre { font-size: 12px; }
  body .closing { margin: 35px 20px; padding: 32px 24px; border-radius: 22px; }
  body .closing h2 { font-size: 30px; }
  body .closing .button { white-space: normal; text-align: center; }
  body footer { padding: 28px 20px 35px; gap: 20px; }
  body footer > span { margin-left: 0; margin-inline-start: auto; }
  body .legal { padding-inline: 20px; }
  body .legal h1 { font-size: 36px; }
  body.billing-page .ai-main { padding: 34px 20px 50px; }
  body.ai-page .ai-heading { gap: 18px; }
  body.ai-page .ai-heading h1 { font-size: 32px; }
}
@media (max-width: 390px) {
  body .site-header { padding-inline: 16px; gap: 10px; }
  body .site-header .brand { font-size: 20px; }
  body .site-header .brand-mark { font-size: 25px; }
  body .site-header .header-actions { gap: 8px; }
  body .site-header .account-link { max-inline-size: 11ch; overflow: hidden; text-overflow: ellipsis; }
  body .site-header .language-picker select { max-inline-size: 96px; font-size: 11px; }
  body .hero { padding-inline: 16px; }
  body .hero h1 { font-size: 38px; }
  body .button { max-inline-size: 100%; padding-inline: 21px; overflow-wrap: anywhere; }
  body :is(.spec-strip, .section, .closing) { margin-inline: 16px; }
  body .account-main, body .cloud-main { padding-inline: 16px; }
  body .account-panel { padding: 26px 22px; }
  body .cloud-file-row { flex-wrap: wrap; padding: 18px; }
  body .cloud-file-actions { flex-direction: row; align-items: center; gap: 18px; flex-wrap: wrap; white-space: normal; }
  body.billing-page .ai-main { padding-inline: 16px; }
  body.billing-page .ai-plan, body.billing-page .ai-plan:nth-child(2) { padding-inline: 20px; }
  body.billing-page .ai-price { font-size: 31px; }
  body.billing-page .ai-price small { font-size: 11px; }
  body footer .brand { font-size: 19px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  body *, body *::before, body *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* Localized long words must wrap rather than enlarge the page. */
body :is(.hero, .section, .closing, .account-intro, .cloud-heading, .legal) :is(h1, h2, h3) {
  overflow-wrap: anywhere;
}
body .feature-list article > div { min-inline-size: 0; }
/* Translated labels contain nested spans: don't apply the percentage type to them. */
body .preview-stamp { max-inline-size: min(230px, calc(100% - 28px)); }
body .preview-stamp small,
body .preview-stamp small span {
  display: inline;
  font: 500 10px/1.5 var(--mono);
  letter-spacing: .025em;
  overflow-wrap: anywhere;
}
body .preview-stamp small { display: block; margin-block-start: 3px; }
body.billing-page .ai-plan .ai-button:disabled,
body.billing-page .ai-plan .ai-button[aria-disabled="true"],
body .ai-button:disabled,
body .wai-button:disabled,
body .wai-button.wai-quiet:disabled,
body .wai-toggle:disabled,
body .tool-button:disabled {
  background: #e9ede3;
  color: #60665d;
  border-color: #cad2c1;
  opacity: .72;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

body .cloud-feedback { inset-inline-start: 24px; inset-inline-end: auto; }
body.editor-page #workspace-ai-toggle {
  background: var(--theme-lime);
  color: #14160c;
  border-color: #bedb88;
  border-radius: 9px;
}
body.editor-page #workspace-ai-toggle:hover:not(:disabled) { background: var(--theme-lime-hover); }
body.editor-page #workspace-ai-toggle:disabled { background: #e9ede3; color: #60665d; border-color: #cad2c1; opacity: .72; }
@media (max-width: 850px) {
  body .cloud-feedback { inset-inline: 12px; }
}
