/* Shared application foundation. Semantic success/warning/danger colors remain distinct. */
:root { --tt-accent: #3355c5; --tt-border: #dce3ec; --tt-muted: #64748b; }
body { font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: #172033; background: #f8fafc; }
.app-main { font-size: 14px; line-height: 1.6; min-width: 0; }
.app-main h1, .session-shell h1 { font-size: clamp(25px,3vw,32px); font-weight: 650; letter-spacing: -.035em; line-height: 1.25; overflow-wrap: anywhere; }
.app-main h2 { font-size: 17px; font-weight: 650; letter-spacing: -.015em; }
.app-main h3 { font-size: 14px; font-weight: 650; }
.app-main :is(.shadow,.shadow-sm,.shadow-lg).bg-white { border: 1px solid var(--tt-border); border-radius: 12px; box-shadow: 0 2px 5px #17203303; }
.app-main :is(input,select,textarea):not([type=hidden]):not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=color]):not([type=file]), .session-shell :is(input[type=text],input[type=password]) { min-width: 0; max-width: 100%; min-height: 42px; padding: 9px 12px; border: 1px solid #cbd5e1; border-radius: 7px; background: #fff; color: #1e293b; font-size: 13px; box-shadow: 0 1px 2px #0f172a03; }
.app-main textarea { resize: vertical; }
.app-main :is(input,select,textarea):focus, .session-shell input:focus { outline: none; border-color: #5572d9; box-shadow: 0 0 0 3px #5572d91a; }
.app-main label:not(:has(input)) { font-size: 12px; font-weight: 600; color: #475569; }
.app-main :is(input[type=checkbox],input[type=radio]) { accent-color: var(--tt-accent); }
.app-main :is(a,button,input)[class~="bg-blue-600"], .session-shell input[type=submit] { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 10px 16px; border: 1px solid var(--tt-accent); border-radius: 7px; background: var(--tt-accent); color: #fff; font-size: 13px; font-weight: 600; line-height: 1.5; cursor: pointer; box-shadow: none; }
.app-main :is(a,button,input)[class~="bg-blue-600"]:hover, .session-shell input[type=submit]:hover { background: #2947ab; }
.app-main a[class~="border-gray-300"], .app-main a[class~="bg-gray-100"], .app-main a[class~="bg-gray-200"] { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 10px 16px; border: 1px solid var(--tt-border); border-radius: 7px; background: #fff; color: #475569; font-size: 13px; font-weight: 600; }
.app-main :is(a,button,input[type=submit],summary):focus-visible { outline: 2px solid var(--tt-accent); outline-offset: 3px; }
.app-main :is(button,input[type=submit]):disabled { opacity: .5; cursor: not-allowed; }
.app-main table { width: 100%; border-collapse: collapse; font-size: 13px; font-variant-numeric: tabular-nums; }
.app-main th { padding: 12px 18px; font-size: 11px; font-weight: 650; letter-spacing: .035em; color: #64748b; background: #f8fafc; }
.app-main td { padding: 14px 18px; }
.app-main :is(.overflow-hidden,.wf-table-wrap):has(>table) { overflow-x: auto; }
.app-main table:not(.planning-calendar) { min-width: 540px; }
.app-main :is(td,th) form { display: inline-flex; }
.app-main td :is(a,button)[class~="rounded-md"] { min-height: 32px; padding: 6px 10px; font-size: 12px; }
.app-main > :is(.max-w-2xl,.max-w-3xl,.max-w-6xl)[class~="py-8"] { padding-top: 0; padding-bottom: 0; padding-left: 0; padding-right: 0; }
.app-main :is(.flex.justify-between,.flex.items-start.justify-between,.flex.items-center.justify-between) { flex-wrap: wrap; gap: 16px; }
.app-main .flex:is(.gap-3,.space-x-3,.space-x-2):has(>input[type=submit]) { flex-wrap: wrap; }
.app-main [role=alert] { border-radius: 8px; }
.app-main .pagination { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; }
.app-main .pagination span { padding: 5px 10px; border: 1px solid #e2e8f0; border-radius: 6px; background: #fff; }
.app-main .pagination .current { color: #3355c5; border-color: #c7d2fe; background: #eef2ff; }
.app-skip-link { position: absolute; left: 16px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 7px; background: #3355c5; color: #fff; }
.app-skip-link:focus { top: 12px; }
.session-shell form { padding: 28px; border: 1px solid var(--tt-border); border-radius: 12px; background: #fff; box-shadow: 0 4px 16px #17203305; }
.session-shell h1 { color: #172033; }
.enterprise-upload { display: grid; gap: 12px; padding: 24px; border: 1px dashed #b8c5d6; border-radius: 9px; background: #fafbfd; }
.enterprise-upload.is-dragging { border-color: #3355c5; background: #eef2ff; }
.enterprise-upload input[type=file] { max-width: 100%; width: 100%; font-size: 13px; color: #475569; }
.enterprise-upload input::file-selector-button { padding: 9px 12px; margin-right: 12px; border: 1px solid #dce3ec; border-radius: 7px; background: #fff; font-size: 13px; color: #334155; cursor: pointer; }
.enterprise-upload p { font-size: 12px; color: #64748b; }
.app-main .settings-shell { font-family: inherit; }
.app-main .settings-shell .tt-title { font-size: clamp(25px,3vw,32px); font-weight: 650; letter-spacing: -.035em; }
.app-main .settings-shell :is(.tt-card,.tt-sys-card) { border-radius: 12px; border-color: #dce3ec; box-shadow: 0 2px 5px #17203303; }
.app-main .settings-shell .tt-btn.primary { background: #3355c5; }
.app-main .settings-shell .tt-btn.primary:hover { background: #2947ab; }
.app-main .settings-shell .mono { font-family: ui-monospace, SFMono-Regular, monospace; }
.app-main .settings-shell .tt-field { min-height: 42px; }
.app-main .settings-shell .tt-switch:focus-within { outline: 2px solid #3355c5; outline-offset: 3px; border-radius: 20px; }
@media(max-width: 640px) { .app-main { padding-top: 24px; } .app-main :is(.flex.justify-between,.flex.items-start.justify-between,.flex.items-center.justify-between) { align-items: flex-start; } .app-main .flex.space-x-3 { flex-wrap: wrap; gap: 8px; } .app-main .flex.space-x-3 > * { margin-left: 0; } .enterprise-upload { padding: 18px; } .session-shell form { padding: 22px; } }
@media(prefers-reduced-motion:reduce) { html { scroll-behavior: auto !important; } *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
.enterprise-table-scroll { overflow-x: auto; max-width: 100%; min-width: 0; }
.enterprise-table-scroll:focus-visible { outline: 2px solid #3355c5; outline-offset: -2px; }
.app-main .grid > * { min-width: 0; }
.app-main :is(td,th) { overflow-wrap: anywhere; }

.app-main .workforce.wf-card > form { border: 0; padding: 0; background: transparent; }
