/* Al Muallim Atelier — presentation layer only. */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');
:root{--at-paper:#f5f3ed;--at-surface:#fffefa;--at-ink:#182d29;--at-muted:#5e6c65;--at-line:#dfe5dc;--at-green:#17664f;--at-soft:#e4eee4;--at-orange:#f1a06e;--at-shadow:0 14px 45px #24392e09;--ui-sidebar:0px;--ui-radius:24px}
html{scroll-behavior:smooth;scroll-padding-top:180px}
body.am-dashboard,body.am-design,body.am-creative{background:var(--at-paper)!important;color:var(--at-ink)!important;font-family:'DM Sans',system-ui,sans-serif!important;font-size:14px!important;line-height:1.6;--bg-base:var(--at-paper);--bg-midnight:var(--at-surface);--bg-card:var(--at-surface);--bg-card-hover:var(--at-soft);--bg-surface:var(--at-soft);--text-primary:var(--at-ink);--text-secondary:var(--at-muted);--text-muted:var(--at-muted);--border:var(--at-line);--border-active:var(--at-green);--gold:var(--at-green);--gold-hover:#12553f;--gold-glow:#17664f12;--bg:var(--at-paper);--card:var(--at-surface);--line:var(--at-line);--ink:var(--at-ink);--muted:var(--at-muted);color-scheme:light}
html[data-theme=dark] body.am-dashboard{--at-paper:#111d19;--at-surface:#192922;--at-ink:#f0f2e8;--at-muted:#a6b8ad;--at-line:#304238;--at-green:#a8d5ae;--at-soft:#25382c;--at-shadow:0 14px 45px #0002;color-scheme:dark}
body.am-dashboard::before,body.am-design::before,body.am-creative::before{content:'';position:fixed;inset:0;pointer-events:none;background:radial-gradient(ellipse at 92% 0%,#b8d5bb25,transparent 42%);z-index:-1}
body.am-dashboard h1,body.am-design h1,body.am-creative h1{font-family:Manrope,system-ui,sans-serif!important;font-weight:800!important;font-size:clamp(30px,3.6vw,53px)!important;line-height:1.12;letter-spacing:-2.1px!important;color:var(--at-ink)}
body.am-dashboard h2,body.am-design h2,body.am-creative h2{font-family:Manrope,system-ui,sans-serif!important;letter-spacing:-.7px;font-size:23px;font-weight:750;color:var(--at-ink)}
body.am-dashboard h3,body.am-design h3,body.am-creative h3{font-family:Manrope,system-ui,sans-serif!important;color:var(--at-ink)}
.am-dashboard .workspace-sidebar,.am-design header#workspaceNav,.am-creative>aside{position:sticky!important;inset:auto!important;top:16px!important;width:calc(100% - 64px)!important;max-width:1664px;margin:16px auto 0!important;padding:18px 24px 14px!important;background:var(--at-surface)!important;color:var(--at-ink)!important;border:1px solid var(--at-line)!important;border-radius:24px!important;box-shadow:0 8px 30px #182d2910!important;z-index:60;overflow:visible!important;display:grid!important;grid-template-columns:auto 1fr;gap:12px 24px!important;backdrop-filter:blur(20px)}
.am-dashboard .workspace-brand{margin:0!important;color:var(--at-ink)!important;gap:12px;grid-column:1;grid-row:1}.am-dashboard .workspace-brand img{height:38px;width:32px}.am-dashboard .workspace-brand span{font-family:Manrope,sans-serif;font-size:14px;font-weight:800}.am-dashboard .workspace-brand small{font-size:8px;letter-spacing:2px;color:var(--at-muted);margin-top:2px}
.am-dashboard .nav-caption{display:none}.am-dashboard .sidebar-foot{grid-column:2;grid-row:1;padding:0!important;margin:0!important;text-align:right;color:var(--at-muted);align-self:center}.am-dashboard .sidebar-foot small{display:inline;margin-left:14px;color:var(--at-muted);font-size:10px}.am-dashboard .live-dot{background:#70ad81;box-shadow:0 0 0 4px #70ad8115}
.am-dashboard .nav-tabs,.am-design header nav{grid-column:1/-1;grid-row:2;display:flex!important;flex-direction:row!important;gap:6px!important;margin:0!important;width:100%;padding-top:12px!important;border-top:1px solid var(--at-line)!important;overflow-x:auto!important;scrollbar-width:none}
.am-dashboard .tab-btn,.am-design header nav a,.am-creative>aside>a{background:transparent!important;color:var(--at-muted)!important;border:0!important;padding:10px 15px!important;border-radius:12px!important;min-height:40px!important;font-size:12px!important;font-weight:600;white-space:nowrap!important;justify-content:center;gap:8px;transition:background .2s,color .2s,transform .2s}
.am-dashboard .tab-btn.active,.am-design header nav a.active,.am-creative>aside>a[aria-current]{background:var(--at-green)!important;color:var(--at-surface)!important}.am-dashboard .tab-btn:hover,.am-design header nav a:hover,.am-creative>aside>a:hover{background:var(--at-soft)!important;color:var(--at-ink)!important}.am-dashboard .tab-badge{background:#ffffff25!important;color:inherit!important;border-radius:6px;font-size:10px;padding:1px 6px}
.am-design header#workspaceNav>img{height:38px;width:32px;grid-column:1;grid-row:1}.am-design header#workspaceNav>strong{position:static!important;grid-column:2;grid-row:1;max-width:none!important;font-size:13px!important;align-self:center;color:var(--at-ink)!important}.am-design header#workspaceNav>strong small{font-size:9px;color:var(--at-muted);letter-spacing:1.8px;display:block}.am-design .sidebar-note{display:none}
.am-creative>aside{grid-template-columns:40px 1fr!important;gap:6px 12px!important}.am-creative>aside img{height:40px;width:32px;grid-column:1;grid-row:1}.am-creative>aside strong{grid-column:2;grid-row:1;align-self:center;font-family:Manrope,sans-serif;color:var(--at-ink);font-size:13px}.am-creative>aside>a{grid-row:2;grid-column:auto}.am-creative>aside{display:flex!important;flex-wrap:wrap;align-items:center!important}.am-creative>aside strong{margin-right:auto}.am-creative>aside>a{font-size:11px!important;padding:9px 11px!important}
.am-dashboard header.workspace-topbar{width:auto!important;margin:20px 48px 0!important;padding:0!important;min-height:28px!important;background:none!important;border:0!important;box-shadow:none!important;max-width:1600px}.am-dashboard .brand-box{display:none}.am-dashboard .header-badges{width:100%;justify-content:flex-end}.am-dashboard .status-pill{background:transparent!important;border:0!important;color:var(--at-muted)!important;font-size:10px!important}.am-dashboard .header-badges>.status-pill:nth-child(3){display:none}
.am-dashboard .app-body{margin:0 auto!important;padding:25px 48px 64px!important;width:100%;max-width:1696px!important}.am-dashboard .workspace-heading{margin:0 0 28px!important;gap:24px;align-items:flex-end}.am-dashboard .workspace-heading h1{margin:7px 0 12px!important}.am-dashboard .workspace-heading p{font-size:14px!important;color:var(--at-muted)}.am-dashboard .eyebrow,.am-design .eyebrow,.am-creative header small{font-size:10px!important;text-transform:uppercase;font-weight:700;letter-spacing:2px;color:var(--at-green)}
.am-dashboard .heading-controls{display:flex;gap:8px;flex-wrap:wrap}.am-dashboard .btn,.am-design button,.am-design .button,.am-creative button,.am-creative .button{border-radius:12px!important;min-height:42px!important;padding:11px 17px!important;border:1px solid var(--at-line)!important;background:var(--at-surface);color:var(--at-ink);font-family:inherit;font-weight:600!important;font-size:12px!important;box-shadow:none!important;text-decoration:none;transition:transform .2s,background .2s,border-color .2s,box-shadow .2s}
.am-dashboard .btn-gold,.am-design .primary,.am-creative .primary{background:var(--at-green)!important;color:var(--at-surface)!important;border-color:var(--at-green)!important}.am-dashboard .btn-gold:hover,.am-design .primary:hover,.am-creative .primary:hover{box-shadow:0 5px 15px #17664f22!important;transform:translateY(-2px)}
.am-dashboard .workspace-overview{gap:14px;margin-bottom:26px;grid-template-columns:repeat(4,minmax(0,1fr))}.am-dashboard .overview-card{padding:22px 24px;border-radius:20px;border:1px solid var(--at-line);background:var(--at-surface);box-shadow:var(--at-shadow);position:relative;overflow:hidden;transition:transform .25s,border-color .25s}.am-dashboard .overview-card:hover{transform:translateY(-4px);border-color:var(--at-green)}.am-dashboard .overview-card>span{text-transform:uppercase;font-size:10px;letter-spacing:1.3px;font-weight:700}.am-dashboard .overview-card>strong{font-family:Manrope,sans-serif;font-weight:800;font-size:38px;letter-spacing:-1.6px;color:var(--at-ink)}.am-dashboard .overview-card>small{font-size:11px}.am-dashboard .overview-card:nth-child(2){background:var(--at-soft)}.am-dashboard .overview-card:nth-child(4)::after{content:'';position:absolute;width:85px;height:85px;border:16px solid #f1a06e28;border-radius:50%;right:-22px;top:-22px;pointer-events:none}
.am-dashboard .direct-upload-card{border:1px dashed #91ac9b!important;background:var(--at-surface)!important;border-radius:24px!important;padding:30px!important;margin-bottom:26px!important;box-shadow:none}.am-dashboard .drop-zone-content{display:grid;grid-template-columns:52px 1fr;align-items:center;text-align:left;max-width:none;gap:0 20px}.am-dashboard .upload-icon{grid-column:1;grid-row:1/4;width:52px;height:52px;background:var(--at-soft);color:var(--at-green);margin:0;border-radius:16px}.am-dashboard .drop-title{grid-column:2;font-family:Manrope,sans-serif;font-size:22px;font-weight:800;letter-spacing:-.7px;color:var(--at-ink)}.am-dashboard .drop-sub{grid-column:2;margin:4px 0!important;font-size:12px!important;color:var(--at-muted)}.am-dashboard .upload-help{grid-column:2;color:var(--at-muted)}.am-dashboard .direct-upload-card .batch-actions{justify-content:flex-end}.am-dashboard .cadence-banner{border:0!important;border-radius:20px!important;background:var(--at-soft)!important;padding:22px 26px!important;color:var(--at-ink)}.am-dashboard .cadence-title{font-family:Manrope,sans-serif;font-weight:800}.am-dashboard .cadence-desc{color:var(--at-muted)}
.am-dashboard .week-strip{gap:10px;margin:24px 0}.am-dashboard .day-tile{border-radius:16px!important;padding:16px!important;border:1px solid var(--at-line);background:var(--at-surface)!important;min-height:106px;transition:transform .2s}.am-dashboard .day-tile:hover{transform:translateY(-3px)}.am-dashboard .day-tile.today{background:var(--at-green)!important;color:var(--at-surface)!important;border-color:var(--at-green)!important}.am-dashboard .day-tile.today *{color:var(--at-surface)!important}.am-dashboard .day-type{font-family:Manrope,sans-serif;font-weight:750;font-size:15px}.am-dashboard .day-date,.am-dashboard .day-item{font-size:11px;color:var(--at-muted)}
.am-dashboard .queue-card{padding:22px 26px!important;border-radius:22px!important;border:1px solid var(--at-line);background:var(--at-surface);box-shadow:var(--at-shadow);margin-bottom:16px}.am-dashboard .queue-card-header{gap:14px;align-items:center}.am-dashboard .queue-card-header h3{font-size:16px;letter-spacing:-.3px}.am-dashboard .queue-toolbar h2,.am-dashboard .section-header h2{font-size:26px!important;font-weight:800}.am-dashboard .badge,.am-dashboard .status-badge{border-radius:7px;font-size:10px;padding:5px 9px}.am-dashboard details>summary{padding:10px 0;font-size:12px;font-weight:600;color:var(--at-green)}
.am-dashboard .settings-card,.am-dashboard .connection-card,.am-dashboard .content-card,.am-dashboard .media-player-box,.am-dashboard .copy-editor-box{border-radius:22px!important;border-color:var(--at-line)!important;background:var(--at-surface)!important;box-shadow:var(--at-shadow)!important}.am-dashboard .content-card{overflow:hidden;transition:transform .25s}.am-dashboard .content-card:hover{transform:translateY(-3px)}.am-dashboard .content-card img{border-radius:14px}.am-dashboard .month-grid{background:var(--at-line);border-color:var(--at-line)}.am-dashboard .calendar-day{background:var(--at-surface);color:var(--at-ink)}.am-dashboard .calendar-event{border-radius:8px}.am-dashboard .connection-card{padding:24px!important}.am-dashboard .connection-grid{gap:18px}
.am-dashboard input:not([type=checkbox]):not([type=radio]),.am-dashboard textarea,.am-dashboard select,.am-design input:not([type=checkbox]):not([type=radio]),.am-design textarea,.am-design select,.am-creative input:not([type=checkbox]):not([type=radio]),.am-creative textarea,.am-creative select{background:var(--at-paper)!important;color:var(--at-ink)!important;border:1px solid var(--at-line)!important;border-radius:12px!important;padding:12px 14px;font-family:inherit!important;line-height:1.5}.am-dashboard input:focus,.am-dashboard textarea:focus,.am-design input:focus,.am-design textarea:focus,.am-creative input:focus,.am-creative textarea:focus{border-color:var(--at-green)!important;box-shadow:0 0 0 4px #17664f0c!important}.am-dashboard label,.am-design label,.am-creative label{font-size:12px;color:var(--at-ink)}
.am-dashboard footer{margin:0!important;padding:24px 48px!important;border-top:1px solid var(--at-line);color:var(--at-muted);font-size:11px}.am-dashboard .toast-stack .toast{border-radius:15px;background:var(--at-surface);color:var(--at-ink);border:1px solid var(--at-line)}
.am-creative main,.am-design main{margin:0 auto!important;padding:36px 48px 70px!important;max-width:1696px!important;min-width:0}.am-creative main{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:24px}.am-creative main>header{grid-column:1/-1;margin:4px 0 8px}.am-creative main>header h1{max-width:800px;margin:12px 0 16px}.am-creative main>header p{font-size:14px;color:var(--at-muted)}
.am-creative section{margin:0!important;border:1px solid var(--at-line)!important;border-radius:24px!important;background:var(--at-surface)!important;padding:26px!important;scroll-margin-top:175px;box-shadow:var(--at-shadow)}.am-creative main>.cg-settings{grid-column:1/-1;padding:22px 26px!important}.am-creative .cg-settings h2{font-size:17px;margin-bottom:14px}.am-creative .cg-settings>label{max-width:920px}.am-creative .cg-settings .actions{gap:8px;margin-bottom:0}.am-creative .cg-settings details{font-size:12px;margin-bottom:0;color:var(--at-muted)}.am-creative #connectorStatus{font-size:11px;border-radius:20px;background:var(--at-soft);padding:7px 12px;color:var(--at-green)}
.am-creative #inspirations{grid-column:1/6;align-self:start}.am-creative #compose{grid-column:6/-1;align-self:start;position:sticky;top:155px}.am-creative #tasks,.am-creative #drafts{grid-column:1/-1}.am-creative #referenceGrid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;max-height:700px;overflow:auto;padding:3px 5px 3px 0;scrollbar-width:thin;scrollbar-color:var(--at-line) transparent}.am-creative .card{margin:0!important;border:1px solid var(--at-line);border-radius:16px;background:var(--at-paper);padding:12px;min-width:0}.am-creative .card img{height:220px;background:var(--at-soft);border-radius:10px;width:100%;object-fit:contain}.am-creative .card h3{font-size:12px;overflow-wrap:anywhere}.am-creative .card p{font-size:11px;color:var(--at-muted)}.am-creative .card button{min-height:32px!important;padding:7px 9px!important;font-size:10px!important;margin:3px 1px}.am-creative .card button[data-use]{background:var(--at-green);color:var(--at-surface);border-color:var(--at-green)!important}.am-creative .work{grid-template-columns:1fr!important;gap:20px}.am-creative .work>div:first-child{display:flex;align-items:center;gap:16px;padding:16px;border-radius:16px;background:var(--at-soft);min-height:70px}.am-creative .work img{width:100px;max-height:135px;object-fit:contain;border-radius:8px}.am-creative #selectedName{font-family:Manrope,sans-serif;font-weight:700;color:var(--at-ink);font-size:13px;overflow-wrap:anywhere}.am-creative #prompt{min-height:220px!important;background:var(--at-surface)!important;font-size:15px;line-height:1.75}.am-creative #compose .work>div>p{font-size:11px;line-height:1.6;color:var(--at-muted)}.am-creative #send{padding:13px 24px!important}.am-creative #addContext{font-size:10px!important;background:transparent!important;color:var(--at-green)!important}
.am-creative .paste{border:1px dashed #a0b3a4;border-radius:16px;background:var(--at-paper);padding:18px;margin-bottom:16px}.am-creative .paste p{font-size:11px;color:var(--at-muted)}.am-creative input[type=file]{font-size:11px;padding:5px!important;border:0!important;background:transparent!important;max-width:100%}.am-creative #referenceSearch{margin-bottom:10px}.am-creative #showArchived{accent-color:var(--at-green)}.am-creative #taskList{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}.am-creative .task{margin:0;padding:22px;background:var(--at-paper);border:1px solid var(--at-line);border-radius:18px;min-width:0;overflow-wrap:anywhere}.am-creative .task h3{font-size:12px;letter-spacing:0}.am-creative .task-head{gap:12px;align-items:center}.am-creative .stage{border-radius:20px;background:var(--at-soft);padding:4px 10px;color:var(--at-green);font-size:10px;text-transform:uppercase;letter-spacing:.7px;white-space:nowrap}.am-creative .task pre{font-size:13px;color:var(--at-ink);padding:10px 0}.am-creative .error{color:#9e513e;font-size:11px}.am-creative .result{padding:14px;background:var(--at-surface);border:1px solid var(--at-line);border-radius:14px}.am-creative .result img{width:100%;max-height:400px;object-fit:contain;border-radius:10px}.am-creative .result p{font-size:11px;color:var(--at-green);font-weight:600}.am-creative .task .paste{margin-top:16px;background:var(--at-surface)}.am-creative .task .actions{gap:6px}.am-creative .task button,.am-creative .task .button{font-size:10px!important;padding:8px 10px!important;min-height:34px!important}.am-creative #draftGrid{grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:18px}.am-creative #draftGrid .card img{height:320px}.am-creative #draftGrid .card{padding:16px}.am-creative #notice{grid-column:1/-1;position:sticky;bottom:20px;z-index:40;background:var(--at-ink);color:var(--at-surface);box-shadow:0 10px 30px #0002;border-radius:14px;padding:14px 20px;font-size:12px}.am-creative #notice:empty{display:none}
.am-design .design-topbar{margin:0 0 28px!important;padding:0 0 18px!important;background:none;border-bottom:1px solid var(--at-line);min-height:40px;color:var(--at-muted)}.am-design main>p{color:var(--at-muted)}.am-design .card{background:var(--at-surface)!important;border:1px solid var(--at-line)!important;border-radius:24px!important;box-shadow:var(--at-shadow);padding:28px!important}.am-design #inspirationDropzone{background:var(--at-paper)!important;border:1px dashed #a0b3a4!important;border-radius:16px!important}.am-design #libraryGrid .idea{background:var(--at-paper)!important;border:1px solid var(--at-line);border-radius:16px;padding:12px}.am-design #libraryGrid img{background:var(--at-soft)!important;border-radius:10px}.am-design .chat-reference{background:var(--at-soft)!important;border-radius:18px!important}.am-design .chat-reference .preview-button{background:var(--at-surface)!important}.am-design .bubble{background:var(--at-paper)!important;color:var(--at-ink);border:1px solid var(--at-line);border-radius:16px;padding:16px 20px}.am-design .bubble.user{background:var(--at-green)!important;color:var(--at-surface)}.am-design .bubble.user strong{color:inherit}.am-design .chat-project-header,.am-design .composer-help,.am-design .chat-attachment-zone{background:transparent!important;color:var(--at-muted);border-color:var(--at-line)!important}.am-design .attachment{background:var(--at-paper)!important;border-color:var(--at-line)}.am-design dialog{background:var(--at-surface);color:var(--at-ink);border:1px solid var(--at-line);border-radius:22px}.am-design dialog::backdrop{background:#10291ecc;backdrop-filter:blur(8px)}
.am-signin{background:var(--at-paper)!important;color:var(--at-ink)!important;font-family:'DM Sans',sans-serif!important;position:relative;overflow-x:hidden}.am-signin::before{content:'A world of possibilities.';position:absolute;left:7vw;top:24vh;width:35vw;font-family:Manrope,sans-serif;font-size:clamp(42px,5vw,78px);font-weight:800;letter-spacing:-4px;line-height:1.04;color:var(--at-ink)}.am-signin::after{content:'';position:absolute;bottom:8vh;left:8vw;width:230px;height:230px;border:45px solid #17664f15;border-radius:50%;pointer-events:none}.am-signin form{position:relative;margin-left:42vw;max-width:460px;padding:42px!important;border-radius:26px!important;background:var(--at-surface)!important;border:1px solid var(--at-line)!important;box-shadow:var(--at-shadow)!important}.am-signin form h1{font-family:Manrope,sans-serif;font-size:32px;letter-spacing:-1.3px;color:var(--at-ink)}.am-signin p{color:var(--at-muted)!important}.am-signin input{background:var(--at-paper)!important;border:1px solid var(--at-line)!important;color:var(--at-ink)!important;border-radius:12px!important}.am-signin button{background:var(--at-green)!important;color:var(--at-surface)!important;border-radius:12px!important}.am-signin .signin-note{border-color:var(--at-line)!important}.am-signin .logo{height:60px}.am-signin .error{color:#a44034!important}
.am-legal{background:var(--at-paper)!important;color:var(--at-ink)!important;font-family:'DM Sans',sans-serif!important}.am-legal header{background:var(--at-surface)!important;border-color:var(--at-line)!important}.am-legal h1,.am-legal h2,.am-legal h3{font-family:Manrope,sans-serif!important;color:var(--at-ink)!important;letter-spacing:-.8px}.am-legal h1{font-size:42px!important}.am-legal p,.am-legal li{color:var(--at-muted)!important}.am-legal main,.am-legal .container{max-width:1000px;margin:32px auto!important}.am-legal .card,.am-legal section{background:var(--at-surface)!important;border-color:var(--at-line)!important;border-radius:22px!important}.am-legal a{color:var(--at-green)!important}.am-legal footer{background:none!important;border-color:var(--at-line)!important;color:var(--at-muted)!important}
body [hidden]{display:none!important}button:disabled{transform:none!important;opacity:.5;cursor:not-allowed!important}a:focus-visible,button:focus-visible,summary:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:3px solid #f1a06e!important;outline-offset:4px}button,input,textarea,select{max-width:100%}.am-creative a{color:var(--at-green)}.am-dashboard .nav-toggle,.am-design .nav-toggle{display:none!important}
.at-enter{animation:at-rise .55s cubic-bezier(.2,.7,.2,1) both;animation-delay:var(--at-delay,0ms)}@keyframes at-rise{from{opacity:.35;transform:translateY(14px)}to{opacity:1;transform:none}}.am-dashboard .tab-content.active,.am-dashboard .view.active{animation:at-rise .3s ease-out}.am-creative .card,.am-creative .task,.am-design .idea{animation:at-rise .3s ease-out}.am-creative .task:target,.am-creative .card:target{outline:2px solid var(--at-green);outline-offset:5px}
@media(min-width:1800px){.am-dashboard header.workspace-topbar{margin-left:auto!important;margin-right:auto!important;width:calc(100% - 96px)!important}}
@media(max-width:1100px){.am-dashboard .workspace-sidebar,.am-design header#workspaceNav,.am-creative>aside{width:calc(100% - 32px)!important;margin-top:12px!important;top:10px!important;padding:14px 18px!important}.am-dashboard .app-body,.am-design main,.am-creative main{padding:28px 24px 50px!important}.am-dashboard header.workspace-topbar{margin:18px 24px 0!important}.am-dashboard .workspace-heading{align-items:flex-start}.am-dashboard .workspace-heading h1{font-size:38px!important}.am-dashboard .sidebar-foot small{display:none}.am-dashboard .week-strip{grid-template-columns:repeat(7,minmax(105px,1fr));overflow-x:auto;padding-bottom:8px}.am-creative #inspirations{grid-column:1/6}.am-creative #compose{grid-column:6/-1;top:170px}.am-creative #referenceGrid{grid-template-columns:1fr}.am-creative .cg-settings .actions{gap:6px}.am-creative .cg-settings .actions button,.am-creative .cg-settings .actions a{font-size:10px!important}.am-creative>aside strong{flex-basis:calc(100% - 60px);margin-right:0}.am-creative>aside>a{flex:0 0 auto}.am-signin form{margin-left:40vw;max-width:390px}.am-signin::before{font-size:48px;left:5vw;letter-spacing:-2px}}
@media(max-width:760px){html{scroll-padding-top:155px}.am-dashboard .workspace-sidebar,.am-design header#workspaceNav,.am-creative>aside{width:calc(100% - 20px)!important;top:8px!important;border-radius:18px!important;padding:12px!important}.am-dashboard .sidebar-foot{font-size:9px}.am-dashboard .workspace-brand span{font-size:11px}.am-dashboard .workspace-brand small{font-size:7px}.am-dashboard .tab-btn,.am-design header nav a{padding:9px 12px!important;font-size:11px!important}.am-dashboard .app-body,.am-design main,.am-creative main{padding:24px 16px 40px!important}.am-dashboard .workspace-heading{display:block}.am-dashboard .workspace-heading h1,.am-design h1,.am-creative h1{font-size:34px!important;letter-spacing:-1.3px!important}.am-dashboard .heading-controls{margin-top:18px}.am-dashboard header.workspace-topbar{margin:16px 16px 0!important}.am-dashboard .header-badges{flex-wrap:wrap;justify-content:flex-start}.am-dashboard .workspace-overview{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.am-dashboard .overview-card{padding:18px!important;border-radius:16px}.am-dashboard .overview-card>strong{font-size:32px}.am-dashboard .overview-card>small{font-size:10px}.am-dashboard .direct-upload-card{padding:20px!important}.am-dashboard .drop-zone-content{grid-template-columns:1fr;text-align:center;gap:10px}.am-dashboard .upload-icon,.am-dashboard .drop-title,.am-dashboard .drop-sub,.am-dashboard .upload-help{grid-column:1;grid-row:auto}.am-dashboard .upload-icon{margin:auto}.am-dashboard .drop-title{font-size:20px}.am-dashboard .queue-card{padding:18px!important}.am-dashboard .cadence-banner{padding:20px!important}.am-dashboard .cadence-desc{font-size:11px}.am-dashboard .calendar-scroll{overflow:auto}.am-dashboard .connection-grid,.am-dashboard .settings-grid{grid-template-columns:1fr!important}.am-dashboard footer{padding:20px!important}.am-creative main{grid-template-columns:1fr;gap:18px}.am-creative main>header,.am-creative main>.cg-settings,.am-creative #inspirations,.am-creative #compose,.am-creative #tasks,.am-creative #drafts{grid-column:1!important}.am-creative #compose{position:static}.am-creative section{padding:20px!important;border-radius:20px!important}.am-creative #referenceGrid{grid-template-columns:repeat(2,minmax(0,1fr));max-height:460px}.am-creative .card img{height:190px}.am-creative #taskList{grid-template-columns:1fr}.am-creative #draftGrid{grid-template-columns:repeat(2,minmax(0,1fr))}.am-creative #draftGrid .card img{height:220px}.am-creative #draftGrid .card{padding:10px}.am-creative .work{gap:16px}.am-creative #prompt{min-height:180px!important}.am-design .edit-workspace{grid-template-columns:1fr!important}.am-design .chat-reference{position:static!important}.am-design .card{padding:20px!important}.am-design .library-toolbar{align-items:flex-start;flex-direction:column;gap:10px}.am-design .library-toolbar input{width:100%}.am-design #libraryGrid{grid-template-columns:repeat(2,minmax(0,1fr))!important}.am-design #libraryGrid img{height:180px}.am-signin{padding:22px!important}.am-signin::before{position:relative;left:auto;top:auto;width:auto;font-size:36px;letter-spacing:-1.5px;text-align:center;margin:40px 0 26px}.am-signin::after{display:none}.am-signin form{margin:0 auto!important;padding:28px!important;max-width:460px}.am-legal main,.am-legal .container{margin:20px 16px!important;width:auto!important}.am-legal h1{font-size:32px!important}}
@media(max-width:400px){.am-creative #draftGrid{grid-template-columns:1fr}.am-dashboard .sidebar-foot{display:none}.am-dashboard .workspace-sidebar{grid-template-columns:1fr}.am-dashboard .workspace-brand{grid-column:1/-1}.am-creative .card button{padding:6px!important}.am-creative #referenceGrid .card img{height:160px}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}.at-enter,.am-creative .card,.am-creative .task,.am-design .idea,.am-dashboard .tab-content.active,.am-dashboard .view.active{animation:none!important}*,*::before,*::after{transition:none!important}}
.am-creative>aside{flex-direction:row!important}.am-dashboard .drop-zone-content>div:not(.upload-icon):not(.drop-title):not(.drop-sub):not(.upload-help){grid-column:2;min-width:0}.am-dashboard .drop-zone-content>div[style*="display:flex"]{justify-content:flex-start!important;flex-wrap:wrap;gap:8px!important}.am-dashboard #themeToggle,.am-dashboard .heading-controls>.btn:not(.btn-gold){background:var(--at-surface)!important;color:var(--at-ink)!important}.am-dashboard .upload-icon{background:var(--at-soft)!important;color:var(--at-green)!important}.am-dashboard .month-day,.am-dashboard .published-table,.am-dashboard .platforms-bar,.am-dashboard .vision-note-box{background:var(--at-surface)!important;color:var(--at-ink)!important;border-color:var(--at-line)!important}.am-dashboard .view-section.active{animation:at-rise .3s ease-out}
@media(max-width:760px){.am-dashboard .drop-zone-content>div:not(.upload-icon):not(.drop-title):not(.drop-sub):not(.upload-help){grid-column:1}.am-dashboard .drop-zone-content>div[style*="display:flex"]{justify-content:center!important}}
.am-creative>aside{display:grid!important;grid-template-columns:auto 1fr!important;gap:16px!important}.am-creative .creative-brand{display:flex;align-items:center;gap:12px;white-space:nowrap}.am-creative .creative-brand img{display:block!important;width:30px;height:36px;object-fit:contain}.am-creative .creative-brand strong{font-size:12px;color:var(--at-ink);font-family:Manrope,sans-serif}.am-creative .creative-navigation{display:flex;align-items:center;justify-content:flex-end;gap:6px;overflow-x:auto;scrollbar-width:none;min-width:0}.am-creative .creative-navigation a{padding:10px 12px;border-radius:12px;text-decoration:none;font-size:11px;font-weight:600;white-space:nowrap;color:var(--at-muted);min-height:40px;transition:background .2s,color .2s}.am-creative .creative-navigation a:hover{background:var(--at-soft);color:var(--at-ink)}.am-creative .creative-navigation a[aria-current]{background:var(--at-green);color:var(--at-surface)}
@media(max-width:1100px){.am-creative>aside{grid-template-columns:1fr!important;gap:10px!important}.am-creative .creative-navigation{justify-content:flex-start;border-top:1px solid var(--at-line);padding-top:10px}.am-creative .creative-brand{gap:10px}.am-creative .creative-brand img{height:30px;width:25px}.am-creative .creative-navigation a{font-size:10px;padding:8px 10px;min-height:34px}}
.am-creative.media-only>aside,.am-creative.media-only main>header,.am-creative.media-only main>section:not(#drafts){display:none!important}.am-creative.media-only main{padding:12px!important;display:block}.am-creative.media-only #drafts{margin:0!important}
@media(max-width:760px){.am-creative .card button,.am-creative .task button,.am-creative .task .button{min-height:44px!important;font-size:11px!important}.am-creative .task .actions>*{flex:1 1 auto}.am-design #libraryGrid button{min-height:44px!important}}
@media(prefers-reduced-motion:reduce){.am-dashboard .view-section.active{animation:none!important}}
/* Normalize the legacy studio surfaces and keep entire grid rows in flow. */
.am-dashboard .workspace-sidebar,.am-design header#workspaceNav,.am-creative>aside{position:relative!important;top:auto!important;inset:auto!important}
.am-creative #compose{position:static!important;top:auto!important;align-self:stretch;min-width:0}
.am-creative #inspirations{min-width:0}.am-creative #tasks,.am-creative #drafts{position:relative;min-width:0}
.am-design .chat-reference{position:static!important;top:auto!important;min-width:0}.am-design .edit-workspace{align-items:start}.am-design .edit-conversation{min-width:0}
.am-creative p,.am-creative small,.am-design p,.am-design small{color:var(--at-muted)!important}
.am-design .edit-conversation .chatlog{background:var(--at-paper)!important;border:1px solid var(--at-line)!important;padding:18px!important;border-radius:18px!important;scrollbar-color:var(--at-muted) var(--at-paper);scrollbar-width:thin}
.am-design .edit-conversation .bubble{background:var(--at-surface)!important;color:var(--at-ink)!important;border-color:var(--at-line)!important;max-width:96%;overflow-wrap:anywhere}
.am-design .edit-conversation .bubble.user{background:var(--at-green)!important;color:var(--at-surface)!important;border-color:var(--at-green)!important}
.am-design .bubble strong{color:var(--at-green)!important}.am-design .bubble.user strong{color:inherit!important}.am-design .bubble p,.am-design .bubble small{color:inherit!important}
.am-design .history #history button{background:var(--at-paper)!important;color:var(--at-ink)!important;border:1px solid var(--at-line)!important;box-shadow:none!important}.am-design .history #history button:hover{background:var(--at-soft)!important;border-color:var(--at-green)!important}.am-design .history #history button strong{color:var(--at-ink)!important}.am-design .history #history button small{color:var(--at-muted)!important}
.am-design .review-details,.am-design .review-details>summary,.am-design .review-details[open]{background:var(--at-paper)!important;color:var(--at-ink)!important;border:1px solid var(--at-line)!important;border-radius:12px!important}.am-design .review-details>summary{border:0!important;padding:12px 14px!important}.am-design .review-details>div{padding:12px 14px}.am-design .review-details li{color:var(--at-ink)!important}
.am-design .result-badge,.am-design .reference-tabs button.active{background:var(--at-soft)!important;color:var(--at-green)!important;border-color:var(--at-line)!important}.am-design .reference-tabs button{color:var(--at-muted)!important;background:var(--at-surface)!important;border-color:var(--at-line)!important}.am-design .reference-tabs button.active{box-shadow:inset 0 0 0 1px var(--at-green)!important}.am-design .preview-button span{background:var(--at-ink)!important;color:var(--at-surface)!important}.am-design .chat-attachment-zone>small,.am-design .chat-project-header>small,.am-design #chatStudio>small{color:var(--at-muted)!important}
.am-design .status,.am-design .workspace-empty,.am-design .placeholder{background:var(--at-paper)!important;color:var(--at-muted)!important;border:1px solid var(--at-line)!important}.am-design .error,.am-creative .error{color:#a34735!important}
.atelier-theme-toggle{white-space:nowrap!important;flex-shrink:0;margin:0 0 0 6px!important;min-height:38px!important;padding:8px 12px!important;font-size:11px!important;border:1px solid var(--at-line)!important;background:var(--at-soft)!important;color:var(--at-ink)!important}
html:has(body.am-creative),html:has(body.am-design),html:has(body.am-dashboard),html:has(body.am-signin),html:has(body.am-legal){background:#f5f3ed;color-scheme:light;scroll-padding-top:24px}
html[data-theme=dark]:has(body.am-creative),html[data-theme=dark]:has(body.am-design),html[data-theme=dark]:has(body.am-dashboard),html[data-theme=dark]:has(body.am-signin),html[data-theme=dark]:has(body.am-legal){background:#111d19;color-scheme:dark}
html[data-theme=dark] body.am-design,html[data-theme=dark] body.am-creative,html[data-theme=dark] body.am-signin,html[data-theme=dark] body.am-legal{--at-paper:#111d19;--at-surface:#192922;--at-ink:#f0f2e8;--at-muted:#b0c0b5;--at-line:#3b5042;--at-green:#a8d5ae;--at-soft:#25382c;--at-shadow:0 14px 45px #0002;color-scheme:dark}
html[data-theme=dark] .am-design .error,html[data-theme=dark] .am-creative .error,html[data-theme=dark] .am-signin .error{color:#ffb5a8!important}
html[data-theme=dark] .am-design a,html[data-theme=dark] .am-creative a{color:var(--at-green)}
.am-creative section,.am-design .card{scroll-margin-top:24px!important}.am-creative main>section{animation-fill-mode:backwards!important}
@media(max-width:760px){.am-design .edit-conversation .chatlog{max-height:420px!important;padding:12px!important}.am-design .bubble{max-width:100%!important}.am-creative #compose{align-self:auto}.atelier-theme-toggle{min-height:40px!important}}
.atelier-theme-standalone{position:absolute;top:20px;right:20px;width:auto!important;z-index:2}.am-design .review-details>p{padding:0 14px 8px}.am-design .history #history button span{color:var(--at-ink)!important}.am-design .history #history button small{color:var(--at-muted)!important}.am-creative main>section,.am-design .card{isolation:isolate}
/* Use the available screen width, with consistent small edge gutters. */
.am-dashboard .workspace-sidebar,.am-design header#workspaceNav,.am-creative>aside{max-width:none!important;width:calc(100% - 32px)!important;margin-left:16px!important;margin-right:16px!important}
.am-dashboard .app-body,.am-design main,.am-creative main{max-width:none!important;width:100%!important;margin-left:0!important;margin-right:0!important;padding-left:24px!important;padding-right:24px!important}
.am-dashboard header.workspace-topbar{max-width:none!important;width:auto!important;margin-left:24px!important;margin-right:24px!important}
@media(max-width:760px){.am-dashboard .workspace-sidebar,.am-design header#workspaceNav,.am-creative>aside{width:calc(100% - 20px)!important;margin-left:10px!important;margin-right:10px!important}.am-dashboard .app-body,.am-design main,.am-creative main{padding-left:16px!important;padding-right:16px!important}}
/* Old dark-mode selectors were more specific than the shared palette binding. */
html[data-theme] body.am-dashboard{--bg-base:var(--at-paper);--bg-midnight:var(--at-surface);--bg-card:var(--at-surface);--bg-card-hover:var(--at-soft);--bg-surface:var(--at-soft);--text-primary:var(--at-ink);--text-secondary:var(--at-muted);--text-muted:var(--at-muted);--border:var(--at-line);--border-active:var(--at-green);--gold:var(--at-green);--gold-hover:var(--at-green)}
html[data-theme] .am-dashboard .queue-card{background:var(--at-surface)!important;border-color:var(--at-line)!important}
html[data-theme] .am-dashboard .delivery-status{background:var(--at-soft)!important;color:var(--at-muted)!important}
.am-creative .brand-options{display:grid;gap:8px;margin:14px 0}.am-creative .brand-options label{display:flex;align-items:center;gap:10px;padding:12px 14px;border:1px solid var(--at-line);border-radius:12px;background:var(--at-soft);font-size:12px;font-weight:600;cursor:pointer;min-height:44px}.am-creative .brand-options input[type=checkbox]{display:inline-block;width:16px;height:16px;flex-shrink:0;margin:0;accent-color:var(--at-green)}.am-creative .saved-brand{padding:12px 14px;border:1px solid var(--at-line);border-radius:12px;background:var(--at-paper);font-size:12px}.am-creative .saved-brand summary{color:var(--at-green);font-weight:600}.am-creative .saved-brand img{width:52px;height:64px;object-fit:contain;margin:12px 0 0}.am-creative #brandSummary{font-size:12px!important;line-height:1.8;overflow-wrap:anywhere}
/* Desktop workspace navigation: fixed rail, independently scrollable links. */
.media-toolbar{display:flex;gap:12px;align-items:center;flex-wrap:wrap;padding:18px;background:var(--at-surface);border:1px solid var(--at-line);border-radius:18px;margin:20px 0}.media-toolbar input{flex:1 1 260px!important;width:auto!important;margin:0!important}.media-toolbar select{width:180px!important}.media-count{font-size:12px;color:var(--at-muted);margin-left:auto}.media-action-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:20px}.media-action-card{border:1px solid var(--at-line);border-radius:20px;overflow:hidden;background:var(--at-surface);min-width:0}.media-action-preview{background:var(--at-soft);padding:16px;height:290px;display:flex;align-items:center;justify-content:center}.media-action-preview img,.media-action-preview video{width:100%;height:100%;object-fit:contain;border-radius:10px}.media-action-body{padding:18px;display:flex;flex-direction:column;gap:8px}.media-action-body h3{font-size:14px!important;overflow-wrap:anywhere;margin:6px 0}.media-action-body p{font-size:12px;margin:0 0 14px;color:var(--at-muted)}.media-status{align-self:flex-start;padding:3px 8px;border:1px solid var(--at-line);background:var(--at-soft);border-radius:6px;font-size:10px;color:var(--at-green)}.media-action-body .btn{width:100%;margin:0!important}.media-action-body .btn:last-child{color:var(--at-green)}@media(max-width:560px){.media-action-grid{grid-template-columns:1fr}.media-toolbar select{width:100%!important}.media-count{margin-left:0}.media-action-preview{height:340px}}
.am-design .creative-brand,.am-creative .creative-brand{display:flex;align-items:center;gap:12px;padding:0 8px 28px!important}.am-design .creative-brand img,.am-creative .creative-brand img{width:32px;height:38px;object-fit:contain}.am-design .creative-brand strong,.am-creative .creative-brand strong{font-size:12px!important;line-height:1.5;color:var(--at-ink)}.creative-brand strong small{display:block;font-size:8px!important;letter-spacing:2px;color:var(--at-muted);font-weight:400}
.atelier-page-bar{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:0 0 18px;margin-bottom:28px;border-bottom:1px solid var(--at-line);font-size:12px;color:var(--at-muted)}.atelier-page-tools{display:flex;gap:8px;flex-wrap:wrap}.atelier-page-tools a{font-size:11px;color:var(--at-green)!important;padding:7px 11px;border-radius:9px;background:var(--at-soft);text-decoration:none}.am-creative .atelier-page-bar{grid-column:1/-1;margin:0}.am-design .design-topbar{display:none!important}
@media(max-width:900px){.atelier-page-bar{align-items:flex-start;flex-direction:column}.am-design .creative-brand,.am-creative .creative-brand{padding:0!important}.am-design header#workspaceNav nav a{display:block!important}.am-design header#workspaceNav nav{display:flex!important;flex-wrap:wrap}}
html[data-theme] body.am-design button.primary,html[data-theme] body.am-creative button.primary,html[data-theme] body.am-dashboard .btn-gold{background:var(--at-green)!important;color:var(--at-surface)!important;border-color:var(--at-green)!important}
html[data-theme] body.am-design #inspirationDropzone #libraryUpload{background:var(--at-green)!important;color:var(--at-surface)!important;border-color:var(--at-green)!important}
@media(min-width:901px){
 body.am-dashboard,body.am-design,body.am-creative:not(.media-only){padding-left:248px!important;--ui-sidebar:0px}
 .am-dashboard .workspace-sidebar,.am-design header#workspaceNav,.am-creative:not(.media-only)>aside{position:fixed!important;inset:0 auto 0 0!important;top:0!important;bottom:0!important;width:248px!important;height:100dvh!important;max-width:none!important;margin:0!important;padding:30px 18px 20px!important;border:0!important;border-right:1px solid var(--at-line)!important;border-radius:0!important;box-shadow:none!important;display:flex!important;flex-direction:column!important;flex-wrap:nowrap!important;align-items:stretch!important;justify-content:flex-start!important;gap:0!important;overflow-y:auto!important;overflow-x:hidden!important;transform:none!important;backdrop-filter:none}
 .am-dashboard .workspace-brand,.am-creative .creative-brand{padding:0 8px 28px!important;flex-shrink:0;white-space:normal;gap:12px}
 .am-dashboard .workspace-brand span,.am-creative .creative-brand strong{font-size:12px!important;line-height:1.5}
 .am-dashboard .nav-caption{display:block!important;font-size:9px;letter-spacing:2px;color:var(--at-muted);margin:12px 10px!important;padding:0!important}
 .am-dashboard .nav-tabs,.am-design header#workspaceNav nav,.am-creative .creative-navigation{display:flex!important;flex-direction:column!important;align-items:stretch!important;justify-content:flex-start!important;gap:6px!important;width:100%!important;flex:0 0 auto!important;flex-wrap:nowrap!important;overflow:visible!important;border:0!important;padding:0!important;margin:0!important}
 .am-design header#workspaceNav nav::before,.am-creative .creative-navigation::before{content:'WORKSPACE';font-size:9px;font-weight:600;letter-spacing:2px;color:var(--at-muted);padding:16px 12px 10px}
 .am-dashboard .tab-btn,.am-design header#workspaceNav nav a,.am-creative .creative-navigation a{display:flex!important;align-items:center;justify-content:flex-start!important;text-align:left!important;white-space:normal!important;min-height:46px!important;padding:12px 14px!important;font-size:12px!important;line-height:1.5;border-radius:12px!important;width:100%}
 .am-dashboard .tab-btn.active,.am-design header#workspaceNav nav a.active,.am-creative .creative-navigation a[aria-current]{background:var(--at-soft)!important;color:var(--at-green)!important;box-shadow:inset 3px 0 var(--at-green)!important}
 .am-dashboard .tab-badge{margin-left:auto!important;background:var(--at-soft)!important;color:var(--at-green)!important}
 .am-dashboard .sidebar-foot{margin-top:auto!important;padding:28px 12px 0!important;text-align:left!important;border-top:1px solid var(--at-line);font-size:11px}
 .am-dashboard .sidebar-foot small{display:block!important;margin:6px 0 0!important}
 .am-design header#workspaceNav>img{margin:0 8px 12px;width:30px;height:38px;flex-shrink:0}
 .am-design header#workspaceNav>strong{padding:0 8px 14px!important;align-self:stretch!important;line-height:1.5}
 .am-design .sidebar-note{display:block!important;margin-top:auto;padding:28px 12px 0;border-top:1px solid var(--at-line);font-size:11px;color:var(--at-muted)}
 .am-creative .atelier-theme-toggle,.am-design .atelier-theme-toggle{margin:24px 0 0!important;width:100%!important;text-align:left!important;min-height:44px!important}
 .am-dashboard .app-body,.am-design main,.am-creative:not(.media-only) main{padding-top:32px!important;padding-left:32px!important;padding-right:32px!important}
 .am-dashboard header.workspace-topbar{margin:20px 32px 0!important}
 .am-dashboard footer{padding-left:32px!important;padding-right:32px!important}
 .am-dashboard .nav-toggle,.am-design .nav-toggle{display:none!important}
}

.library-editor{width:min(1180px,94vw);max-height:90vh;overflow:auto;background:var(--bg-surface);color:var(--text-primary);border:1px solid var(--border);border-radius:20px;padding:24px}.library-editor::backdrop{background:#0c1e1bcc;backdrop-filter:blur(5px)}.library-editor header{display:flex;justify-content:space-between;align-items:center;gap:20px}.library-editor-grid{display:grid;grid-template-columns:minmax(220px,0.8fr) minmax(300px,1.2fr);gap:28px}.library-editor img,.library-editor video{width:100%;max-height:580px;object-fit:contain}.library-editor label{display:block;margin:14px 0}.library-editor input:not([type=checkbox]),.library-editor textarea{width:100%;box-sizing:border-box;margin-top:8px;padding:12px;background:var(--bg-midnight);color:var(--text-primary);border:1px solid var(--border);border-radius:10px}.library-editor textarea{min-height:160px}.library-platform-tabs,.library-editor-actions{display:flex;flex-wrap:wrap;gap:8px}.library-editor .library-destination{display:inline-flex;align-items:center;gap:7px;margin:10px}.library-editor fieldset{border:1px solid var(--border);border-radius:12px}.library-editor [role=status]{padding:12px;background:var(--bg-midnight);border-radius:10px}@media(max-width:760px){.library-editor-grid{grid-template-columns:1fr}.library-editor{padding:16px}}

.am-dashboard dialog.library-editor{position:fixed;inset:0;margin:auto!important;box-sizing:border-box;width:min(1180px,94vw);height:max-content;max-height:88vh;background:var(--at-surface);color:var(--at-ink)}.library-editor textarea{min-height:105px}.library-editor textarea[data-copy-field=hashtags]{min-height:70px}.library-editor header{position:static!important;max-width:none!important;width:auto!important;margin:0!important;background:transparent!important;padding:0 0 14px!important;border-bottom:1px solid var(--at-line)}

/* Stable shared layouts: navigation stays in flow on small screens; content never fades on refresh. */
html { scroll-behavior:auto; }
.am-dashboard .at-enter,.am-design .at-enter,.am-creative .at-enter,
.am-dashboard .view-section.active,.am-creative .card,.am-creative .task,.am-design .idea {
 animation:none!important; opacity:1; transform:none;
}
.am-dashboard .app-body>*,.am-design main>*,.am-creative main>* { min-width:0; }
.am-dashboard .btn,.am-design button,.am-design .button,.am-creative button,.am-creative .button {
 transition:background-color .15s,border-color .15s,color .15s!important;
}
.am-dashboard .btn:hover,.am-design button:hover,.am-creative button:hover,
.am-dashboard .overview-card:hover,.am-dashboard .content-card:hover,.am-dashboard .day-tile:hover { transform:none!important; }
.am-dashboard .queue-card-header { flex-wrap:wrap; }
.am-dashboard .queue-card-header h3,.am-dashboard .delivery-status,.am-creative .task { overflow-wrap:anywhere; }
.am-dashboard .media-action-body { flex:1; }
.am-dashboard .media-action-card { display:flex;flex-direction:column; }
.am-dashboard .media-action-preview { flex-shrink:0; }
.am-dashboard .library-editor-grid>* { min-width:0; }
.am-dashboard dialog.library-editor { overscroll-behavior:contain;scrollbar-gutter:stable; }
.am-dashboard dialog.library-editor header { align-items:flex-start;gap:16px; }
.am-dashboard dialog.library-editor header h2 { margin:0;overflow-wrap:anywhere; }
.am-dashboard dialog.library-editor header button { flex-shrink:0; }
.am-dashboard dialog.library-editor fieldset { min-width:0; }
.am-dashboard .library-platform-tabs button[aria-selected=true] { background:var(--at-soft);border-color:var(--at-green)!important; }
.am-design .bubble.user strong { color:inherit!important; }
.am-design .chat-reference,.am-design .chatlog { min-width:0; }
.am-design #history { scrollbar-width:thin; }
@media(max-width:900px) {
 body.am-dashboard,body.am-design,body.am-creative:not(.media-only) { padding-left:0!important; }
 .am-dashboard .workspace-sidebar,.am-design header#workspaceNav,.am-creative:not(.media-only)>aside {
  position:relative!important;inset:auto!important;height:auto!important;max-height:none!important;
  display:flex!important;flex-direction:column!important;align-items:stretch!important;
  gap:12px!important;padding:16px!important;overflow:visible!important;backdrop-filter:none!important;
  transform:none!important;visibility:visible!important;opacity:1!important;
 }
 .am-dashboard .workspace-brand,.am-design .creative-brand,.am-creative .creative-brand { padding:0!important; }
 .am-dashboard .nav-tabs,.am-design header#workspaceNav nav,.am-creative .creative-navigation {
  display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:6px!important;width:100%!important;overflow:visible!important;margin:0!important;
  padding:12px 0 0!important;border-top:1px solid var(--at-line)!important;
 }
 .am-dashboard .tab-btn,.am-design header#workspaceNav nav a,.am-creative .creative-navigation a {
  display:flex!important;align-items:center!important;justify-content:flex-start!important;
  width:100%!important;min-width:0!important;min-height:44px!important;padding:10px!important;
  margin:0!important;white-space:normal!important;text-align:left!important;font-size:12px!important;
  line-height:1.4!important;border-radius:10px!important;
 }
 .am-dashboard .tab-badge { margin-left:auto!important; }
 .am-dashboard .sidebar-foot,.am-design .sidebar-note { display:none!important; }
 .am-creative .atelier-theme-toggle,.am-design .atelier-theme-toggle { margin:0!important;width:100%!important; }
 .am-dashboard .app-body,.am-design main,.am-creative:not(.media-only) main { padding-top:24px!important; }
 .am-dashboard .workspace-overview { grid-template-columns:repeat(2,minmax(0,1fr))!important; }
 .am-creative #inspirations,.am-creative #compose { grid-column:1/-1!important; }
 .am-creative #referenceGrid { grid-template-columns:repeat(3,minmax(0,1fr));max-height:560px; }
 .am-dashboard .queue-layout { grid-template-columns:1fr!important; }
}
@media(max-width:560px) {
 .am-dashboard .workspace-heading h1,.am-design h1,.am-creative h1 { font-size:32px!important;letter-spacing:-1px!important; }
 .am-dashboard .header-badges { gap:6px; }
 .am-dashboard .queue-card { padding:16px!important; }
 .am-dashboard .media-toolbar { padding:12px;gap:10px; }
 .am-dashboard .media-toolbar input { flex-basis:100%!important;min-width:0; }
 .am-dashboard .media-toolbar select { width:100%!important; }
 .am-dashboard dialog.library-editor { width:calc(100vw - 20px);max-height:calc(100dvh - 24px);padding:16px; }
 .am-dashboard .library-editor-grid { grid-template-columns:minmax(0,1fr);gap:16px; }
 .am-dashboard .library-editor img,.am-dashboard .library-editor video { max-height:45dvh; }
 .am-dashboard .library-editor-actions .btn { flex:1 1 auto; }
 .am-creative #referenceGrid { grid-template-columns:repeat(2,minmax(0,1fr));max-height:440px; }
 .am-creative .task-head { flex-wrap:wrap;gap:8px; }
 .am-design .chathead { flex-wrap:wrap; }
}

html { scrollbar-gutter:stable; }
body:has(dialog[open]) { overflow:hidden; }
@media(max-width:760px) {
 .am-dashboard .calendar-scroll { overflow-x:auto!important;overscroll-behavior-x:contain;scrollbar-width:thin; }
 .am-dashboard .month-grid { min-width:840px!important;gap:8px!important; }
 .am-dashboard .month-day { min-height:140px!important;padding:10px!important; }
 .am-dashboard .calendar-item { font-size:12px!important;min-height:44px; }
 .am-dashboard .calendar-item small { display:block!important;font-size:10px!important; }
 .am-dashboard .month-weekday,.am-dashboard .month-slot,.am-dashboard .month-empty { font-size:11px!important; }
}

.am-dashboard .library-platform-tabs .btn.active { background:var(--at-green)!important;color:var(--at-surface)!important;border-color:var(--at-green)!important; }
.am-dashboard .library-editor a { color:var(--at-green); }
.am-dashboard .library-editor .media-original-link { display:block;margin:10px 0;text-decoration:underline; }
.am-dashboard .library-editor [data-preview] img { min-height:220px; }

/* Fixed-height sidebars must scroll vertically, never wrap links into a clipped second column. */
@media(min-width:901px) {
 .am-dashboard .workspace-sidebar>*,.am-design header#workspaceNav>*,.am-creative:not(.media-only)>aside>* { flex-shrink:0!important;min-width:0; }
 .am-design header#workspaceNav,.am-creative:not(.media-only)>aside { flex-wrap:nowrap!important; }
 .am-design header#workspaceNav nav,.am-creative .creative-navigation { flex-wrap:nowrap!important; }
}

/* Calendar: aligned day cards, readable event names and an unclipped current-day indicator. */
.am-dashboard #view-calendar { min-width:0; }
.am-dashboard .calendar-toolbar { display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap; }
.am-dashboard .calendar-toolbar h2 { margin:0; }
.am-dashboard .calendar-controls { display:flex;align-items:center;gap:8px;flex-wrap:wrap; }
.am-dashboard .calendar-scroll { padding:4px 4px 12px!important;border-radius:0!important;scrollbar-color:var(--at-muted) var(--at-soft); }
.am-dashboard .month-grid { background:transparent!important;gap:10px;align-items:stretch; }
.am-dashboard .month-weekday { text-align:center;padding:10px 4px;font-weight:600;color:var(--at-muted); }
.am-dashboard .month-day { min-width:0;min-height:156px;padding:12px!important;border:1px solid var(--at-line)!important;border-top:3px solid var(--at-green)!important;border-radius:12px; }
.am-dashboard .month-day.post { border-top-color:var(--at-orange)!important; }
.am-dashboard .month-day.rest { border:1px dashed var(--at-line)!important; }
.am-dashboard .month-day.today { outline:none!important;box-shadow:inset 0 0 0 2px var(--at-green)!important; }
.am-dashboard .month-date { min-height:22px;margin:0 0 6px;gap:8px; }
.am-dashboard .month-date small { color:var(--at-green)!important;background:var(--at-soft);border-radius:6px;padding:2px 6px;font-size:10px; }
.am-dashboard .month-slot { margin-bottom:10px;color:var(--at-muted); }
.am-dashboard .calendar-item { background:var(--at-soft)!important;color:var(--at-ink)!important;border:1px solid var(--at-line)!important;border-left:3px solid var(--at-green)!important;padding:9px!important;min-height:64px;line-height:1.45; }
.am-dashboard .calendar-item strong { display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;overflow-wrap:anywhere;font-size:12px;line-height:1.45; }
.am-dashboard .calendar-item small { display:block!important;color:var(--at-muted)!important;line-height:1.4;font-size:10px!important; }
.am-dashboard .calendar-item:hover,.am-dashboard .calendar-item:focus-visible { border-color:var(--at-green)!important;outline:2px solid var(--at-green)!important;outline-offset:1px!important; }
.am-dashboard .calendar-item[data-status=publish_failed],.am-dashboard .calendar-item[data-status=partially_published] { border-left-color:var(--at-orange)!important; }
.am-dashboard .calendar-note { color:var(--at-muted);font-size:12px;line-height:1.6; }
.am-dashboard .calendar-loading { grid-column:1/-1;padding:24px;border-radius:12px;background:var(--at-surface); }
@media(max-width:760px) {
 .am-dashboard .month-grid { min-width:840px!important; }
 .am-dashboard .month-day { min-height:150px!important; }
 .am-dashboard .month-date small { display:inline-block!important; }
}
