/* Studio 3.12.1 - final screen-only layout layer. No PDF geometry or data changes. */
@media screen {
  :root body.ks.ad { --studio-gutter:clamp(16px,2.2vw,32px); --studio-sticky-top:0px; align-items:start; }
  :root body.ks.ad .ks-main { width:100%; max-width:none; min-width:0; margin:0; padding:0 var(--studio-gutter) 64px; }
  :root body.ks.ad .studio-toolbar { top:var(--studio-sticky-top); margin:0 calc(-1 * var(--studio-gutter)) 24px; padding:10px var(--studio-gutter); gap:10px; min-height:58px; background:var(--panel); border-radius:0; border-bottom:1px solid var(--sep); justify-content:flex-start; }
  :root body.ks.ad .studio-toolbar .studio-location { flex:1 1 160px; min-width:0; max-width:100%; }
  :root body.ks.ad .studio-toolbar .ks-topsearch { width:auto; max-width:340px; flex:1 1 220px; min-width:140px; height:38px; }
  :root body.ks.ad .studio-toolbar .ks-topsearch input[type=search] { min-height:38px!important; height:38px!important; background:var(--fill)!important; font-size:13px!important; }
  :root body.ks.ad .studio-toolbar .studio-brand-select { flex:0 1 150px; min-width:100px; }
  :root body.ks.ad .studio-toolbar .studio-brand-select select { width:100%; }
  :root body.ks.ad .studio-toolbar .studio-appearance { flex:0 0 auto; margin:0; }
  :root body.ks.ad .studio-toolbar :is(.studio-brand-select select,.studio-appearance select,.studio-new) { min-height:38px;height:38px;font-size:13px; }
  :root body.ks.ad .studio-toolbar .studio-new { flex:0 0 auto; }
  :root body.ks.ad .studio-toolbar .studio-appearance select { width:106px; }
  :root body.ks.ad .studio-toolbar .studio-appearance>span { display:none; }
  /* Keep account and navigation controls accessible independently of the menu length. */
  :root body.ks.ad .ks-side { overflow:hidden; gap:8px; padding:12px 10px; background:var(--panel); border:1px solid var(--sep2); }
  :root body.ks.ad .ks-side-top { position:relative; flex:0 0 auto; align-items:center; gap:6px; padding:2px 2px 12px; margin:0; border-bottom:1px solid var(--sep2); }
  :root body.ks.ad .ks-collapse { position:static; opacity:1; flex:0 0 28px; }
  :root body.ks.ad .ks-brandmark { padding:4px; gap:8px; }
  :root body.ks.ad .studio-wordmark { width:155px; }
  :root body.ks.ad .ks-nav { overflow:auto; overscroll-behavior:contain; flex:1 1 auto; min-height:0; min-width:0; padding:2px 3px 8px; scrollbar-gutter:stable; }
  :root body.ks.ad .ks-nav a { min-height:36px; height:auto; padding:7px 9px; line-height:1.35; font-size:13px; }
  :root body.ks.ad .ks-nav a span { white-space:normal; overflow-wrap:anywhere; }
  :root body.ks.ad .ks-nav a[aria-current=page] { background:var(--tint-soft); color:var(--link)!important; font-weight:600; }
  :root body.ks.ad .ks-nav-group { line-height:1.4; margin:15px 8px 5px; font-size:11px; }
  :root body.ks.ad .ks-side-foot { flex:0 0 auto; margin:0; padding:8px 2px 0; }
  :root body.ks.ad .ks-me { min-height:40px!important; }
  :root body.ks.ad .ks-signout { min-height:32px; }
  @media(min-width:861px) {
    :root body.ks.ad { grid-template-columns:264px minmax(0,1fr); }
    :root.side-collapsed body.ks.ad { grid-template-columns:76px minmax(0,1fr); }
    :root.side-collapsed body.ks.ad .ks-side-top { flex-direction:column; }
    :root.side-collapsed body.ks.ad .ks-nav a { min-height:38px; width:38px; padding:0; }
    :root.side-collapsed body.ks.ad .ks-nav { padding-inline:0; scrollbar-gutter:auto; }
    :root.side-collapsed body.ks.ad .ks-side { padding:10px 7px; }
  }
  @media(min-width:861px) and (max-width:1220px) {
    :root body.ks.ad .studio-toolbar { flex-wrap:wrap; }
    :root body.ks.ad .studio-toolbar .studio-location { flex:1 0 100%; }
    :root body.ks.ad .studio-toolbar .ks-topsearch { flex:1 1 160px; max-width:none; }
  }
  @media(max-width:860px) {
    :root body.ks.ad,:root.side-collapsed body.ks.ad { display:block; }
    :root body.ks.ad .ks-main,:root.side-collapsed body.ks.ad .ks-main { padding:72px var(--studio-gutter) calc(90px + env(safe-area-inset-bottom)); }
    :root body.ks.ad .studio-toolbar { position:relative; top:auto; display:flex; flex-wrap:wrap; margin-bottom:18px; padding-block:10px; }
    :root body.ks.ad .studio-toolbar .studio-location { display:none; }
    :root body.ks.ad .studio-toolbar .ks-topsearch { flex:1 0 100%; max-width:none; }
    :root body.ks.ad .studio-toolbar .studio-brand-select { flex:1 1 100px; }
    :root body.ks.ad .studio-toolbar .studio-new { flex:1 1 auto; }
    :root body.ks.ad .studio-toolbar .studio-appearance select { width:94px; }
    :root body.ks.ad .studio-toolbar :is(.studio-new,select) { min-height:44px; height:44px; }
    :root body.ks.ad .ks-side { padding:12px; }
    :root body.ks.ad .ks-nav a,:root.side-collapsed body.ks.ad .ks-nav a { min-height:44px; width:auto; margin:0; justify-content:flex-start; padding:10px; font-size:14px; }
    :root.side-collapsed body.ks.ad .ks-brandmark>span { display:flex; }
    :root.side-collapsed body.ks.ad .ks-nav-group { height:auto; margin:15px 8px 5px; font-size:11px; background:transparent; }
    :root body.ks.ad .ks-collapse { display:none; }
    :root body.ks.ad .ks-drawer-close { width:40px;height:40px; }
    :root body.ks.ad .ks-side-top { flex-direction:row; }
  }
  @media(max-width:360px) {
    :root body.ks.ad .studio-toolbar .studio-new { order:3; flex:1 0 100%; }
  }
  /* All dashboard sections stay individual cards, not one white slab. */
  :root body.ks.ad .studio-recent,:root body.ks.ad .studio-docs { background:transparent; border:0; box-shadow:none; border-radius:0; }
  :root body.ks.ad .studio-recent { margin:32px 0; }
  :root body.ks.ad .studio-section-head { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:flex-end; gap:8px 16px; margin:0 0 16px; }
  :root body.ks.ad .studio-section-head h2 { margin:0; font-size:20px; }
  :root body.ks.ad .studio-docs { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,240px),1fr)); gap:16px; }
  :root body.ks.ad .studio-doc-card { display:flex; flex-direction:column; min-width:0; overflow:hidden; padding:0 0 14px; border:1px solid var(--sep); background:var(--panel); }
  :root body.ks.ad .studio-doc-cover { border-radius:0; height:178px; background:var(--fill2); border-bottom:1px solid var(--sep2); }
  :root body.ks.ad .studio-doc-cover :is(img,svg) { width:auto; max-width:100%; height:100%; object-fit:contain; padding:12px; }
  :root body.ks.ad .studio-doc-cover>svg[aria-hidden=true] { width:54px;height:54px;padding:0; }
  :root body.ks.ad .studio-doc-card h3 { padding:0 14px; margin:14px 0 8px; font-size:14px!important; white-space:normal; overflow-wrap:anywhere; line-height:1.4; }
  :root body.ks.ad .studio-doc-meta { padding:0 14px; margin-top:auto; gap:6px; flex-wrap:wrap; }
  :root body.ks.ad .studio-doc-cover-label { position:absolute; bottom:8px; right:8px; background:var(--panel); color:var(--label2); font-size:10px; border:1px solid var(--sep); padding:3px 6px; border-radius:5px; }
  :root body.ks.ad .studio-home-hero { grid-template-columns:minmax(0,1.5fr) minmax(0,1fr); min-height:0; margin-bottom:20px; }
  :root body.ks.ad .studio-home-hero-copy { padding:clamp(22px,3vw,40px); }
  :root body.ks.ad .studio-home-hero h1 { font-size:clamp(30px,3.1vw,42px); max-width:22ch; }
  :root body.ks.ad .studio-home-hero-copy>p { margin-bottom:18px; }
  :root body.ks.ad .studio-home-hero-meta { margin-top:18px; }
  :root body.ks.ad .studio-home-hero-visual { min-height:0; contain:paint; }
  :root body.ks.ad .studio-home-hero-preview { width:42%;height:auto;aspect-ratio:210/297;max-height:82%;top:10%; }
  :root body.ks.ad .studio-home-hero-preview img { object-fit:contain; }
  :root body.ks.ad .studio-home-hero-preview--back { left:9%; transform:rotate(-9deg); }
  :root body.ks.ad .studio-home-hero-preview--front { left:48%;top:8%;transform:rotate(7deg); }
  :root body.ks.ad .studio-home-floating-label { left:12%;right:8%;bottom:16px;width:auto;max-width:100%; }
  :root body.ks.ad .studio-home-featured-grid { grid-template-columns:repeat(auto-fit,minmax(min(100%,245px),1fr)); align-items:stretch; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-card { display:flex; flex-direction:column; height:100%; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-art { height:210px; min-height:0; flex:none; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-description { display:flex;flex-direction:column; flex:1; padding:16px; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-meta { margin-top:auto; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-description .row { display:flex; flex-wrap:wrap; margin-top:12px; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-description .btn { flex:1 1 90px; min-height:36px; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-description p { min-height:0; margin-bottom:16px; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-description h3 { overflow-wrap:anywhere; }
  :root body.ks.ad .studio-home-featured-grid .studio-template-art img { object-fit:contain; }
  :root body.ks.ad .cols2 { gap:20px; }
  :root body.ks.ad .list-row .grow { min-width:0; }
  :root body.ks.ad .list-row .title { line-height:1.4; overflow-wrap:anywhere; }
  @media(max-width:1100px) { :root body.ks.ad .studio-home-hero { grid-template-columns:minmax(0,1fr); } :root body.ks.ad .studio-home-hero-visual { display:none; } }
  @media(max-width:560px) { :root body.ks.ad .studio-home-featured-grid .studio-template-art { height:190px; } :root body.ks.ad .studio-doc-cover { height:160px; } :root body.ks.ad .studio-home-hero h1 { font-size:30px; } }
  /* Shared controls: no clipped labels or narrow columns. Intentionally scrolling tables/canvases remain scrollable. */
  :root body.ks.ad .ad-head>div:first-child { min-width:0; overflow-wrap:anywhere; }
  :root body.ks.ad .ad-actions { gap:8px; }
  :root body.ks.ad .ad-actions .btn { white-space:normal; line-height:1.35; }
  :root body.ks.ad .ks-main :is(.card-p,.grp,.side-p) { min-width:0; }
  :root body.ks.ad .ks-main .tool-embedded { margin:16px 0 0; width:100%; min-width:0; }
  :root body.ks.ad .tool-frame-wrap { width:100%; min-width:0; background:var(--panel); }
  :root body.ks.ad .tool-frame { background:var(--panel); width:100%; }
  :root body.ks.ad .tool-embedded>.row { gap:8px; margin:0; padding:10px 12px; border-radius:10px; background:var(--panel); border:1px solid var(--sep); }
  :root body.ks.ad .tool-saved { overflow-wrap:anywhere; flex:1 1 160px; }
  :root body.ks.ad .tool-embedded .tool-frame-wrap { border-radius:12px; }
  :root body.ks.ad .tool-embedded [data-tool-reload] { flex:0 0 auto; }
  :root body.ks.ad :is(#smart-costing,#product-intelligence) { scroll-margin-top:80px; }
  @media(max-width:860px) { :root body.ks.ad :is(#smart-costing,#product-intelligence) {scroll-margin-top:84px;} :root body.ks.ad .card-p:has(.tool-embedded){padding:14px;} }
  /* Login is an independent composition. A single focus ring, readable logo and clean autofill. */
  :root body.studio-login .wrap { display:grid; grid-template-columns:minmax(0,1.08fr) minmax(0,1fr); padding:12px; gap:12px; min-height:100dvh; align-items:stretch; }
  :root body.studio-login .hero { min-height:calc(100dvh - 24px); border-radius:20px; }
  :root body.studio-login .hero > .studio-hero-logo { padding:10px 12px; background:rgba(255,255,255,.88); border-radius:10px; width:176px; height:auto; object-fit:contain; }
  :root body.studio-login .side { background:var(--panel); min-width:0; padding:36px clamp(24px,4vw,64px); gap:22px; border:1px solid var(--sep); box-shadow:none; border-radius:20px; }
  :root body.studio-login .card { width:100%; max-width:430px; }
  :root body.studio-login .mark { margin-bottom:28px; display:flex; flex-direction:column; align-items:flex-start; }
  :root body.studio-login .studio-login-icon { width:48px;height:48px; margin-bottom:12px; }
  :root body.studio-login .studio-login-wordmark { width:245px; max-width:100%; }
  :root[data-color-scheme=dark] body.studio-login .studio-login-wordmark { filter:invert(1) brightness(1.1); }
  :root body.studio-login h1 { font-size:clamp(30px,3vw,38px); margin:0 0 10px; }
  :root body.studio-login .sub { margin-bottom:24px; }
  :root body.studio-login .fields { display:grid; gap:14px; background:transparent; border:0; box-shadow:none; border-radius:0; }
  :root body.studio-login .fields label { padding:0; border:0; border-radius:0; background:transparent; box-shadow:none; }
  :root body.studio-login .fields label:focus-within { box-shadow:none; }
  :root body.studio-login .fields span { font-size:13px; margin:0 0 7px; font-weight:500; color:var(--label); }
  :root body.studio-login .fields input { display:block; width:100%; min-height:48px; height:48px; padding:10px 12px; border:1px solid var(--sep-strong); background:var(--panel2); border-radius:9px; font-size:16px; line-height:1.4; }
  :root body.studio-login .fields input:focus { border-color:var(--tint); outline:none!important; box-shadow:0 0 0 3px var(--tint-soft-2)!important; }
  :root body.studio-login .fields input:-webkit-autofill { -webkit-text-fill-color:var(--label); box-shadow:inset 0 0 0 100px var(--panel2)!important; }
  :root body.studio-login .fields input:-webkit-autofill:focus { box-shadow:inset 0 0 0 100px var(--panel2),0 0 0 3px var(--tint-soft-2)!important; }
  :root body.studio-login .password-field { position:relative; }
  :root body.studio-login .password-field input { padding-right:64px; }
  :root body.studio-login .password-toggle { position:absolute; right:5px; bottom:5px; min-height:38px; padding:0 10px; background:transparent; border:0; border-radius:6px; color:var(--link); font:600 12px/1 var(--sf-text); cursor:pointer; }
  :root body.studio-login .btn { min-height:48px; margin-top:20px; }
  :root body.studio-login .foot { margin:22px 0 0; text-align:left; }
  :root body.studio-login .studio-appearance { width:100%; max-width:430px; }
  :root body.studio-login .studio-appearance select { min-height:42px; }
  @media(max-width:900px) {
    :root body.studio-login .wrap { display:flex;flex-direction:column; padding:0;gap:0; }
    :root body.studio-login .hero { min-height:0; height:clamp(150px,26dvh,250px); border-radius:0 0 16px 16px; }
    :root body.studio-login .hero>.studio-hero-logo { width:104px;padding:5px 8px;top:12px;left:16px; }
    :root body.studio-login .hero .cap { left:18px; right:18px; bottom:16px; padding-right:96px; }
    :root body.studio-login .hero .cap b { font-size:25px; max-width:18ch; }
    :root body.studio-login .hero .cap span { display:none; }
    :root body.studio-login .dots { right:10px; bottom:6px; }
    :root body.studio-login .dots button { width:30px;height:36px; }
    :root body.studio-login .side { min-height:0;flex:1; border:0; border-radius:0; padding:26px 20px max(22px,env(safe-area-inset-bottom)); justify-content:flex-start; }
    :root body.studio-login .studio-login-icon { display:none; }
    :root body.studio-login .mark { margin-bottom:20px; }
    :root body.studio-login .studio-login-wordmark { width:215px; }
    :root body.studio-login .foot { font-size:12px; }
  }
}
@media screen {
 :root body.ks.ad .ks-main>.studio-toolbar { width:calc(100% + 2 * var(--studio-gutter)); max-width:none; }
 /* Tab strips can scroll intentionally, but their individual chips never break the page. */
 :root body.ks.ad .studio-main .studio-appearance { min-width:0; }
 :root body.ks.ad .studio-docs .studio-doc-card { height:100%; }
 :root body.ks.ad .studio-doc-cover svg[role=img] { width:auto; max-width:100%; height:100%; padding:12px; }
 :root body.ks.ad .studio-toolbar .studio-location strong { white-space:nowrap; }
 @media(max-width:860px){ :root body.ks.ad .ks-main>.studio-toolbar { width:calc(100% + 2 * var(--studio-gutter)); max-width:none; } }
}
@media screen {
 :root body.studio-login .studio-appearance>span{display:block;color:var(--label2);font-size:13px;}
 :root body.ks.ad .quick{grid-template-columns:repeat(auto-fit,minmax(min(100%,178px),1fr));}
 :root body.ks.ad .quick a{min-width:0;overflow-wrap:anywhere;line-height:1.35;}
 :root body.ks.ad .quick a svg{flex:none;}
 @media(max-width:560px){:root body.ks.ad .quick{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;}:root body.ks.ad .quick a{padding:10px;justify-content:flex-start;}}
}
