:root {
    --blue: #00a6fb;
    --blue-dark: #0077b6;
    --ink: #102a3b;
    --muted: #637b89;
    --line: #d9e6ed;
    --bg: #f4f8fb;
    --card: #fff;
    --danger: #a6342b;
    --success: #168c52;
}

* { box-sizing: border-box; }
html { background: var(--bg); }
body {
    background: var(--bg);
    color: var(--ink);
    font-family: "Manrope", Arial, sans-serif;
    margin: 0;
    min-height: 100vh;
}
a { color: var(--blue-dark); }
button, input, select, textarea { font: inherit; }
h1, h2, h3, .brand { font-family: "Plus Jakarta Sans", "Manrope", Arial, sans-serif; }

.topbar {
    align-items: center;
    background: #fff;
    border-bottom: 1px solid var(--line);
    display: flex;
    gap: 24px;
    min-height: 72px;
    padding: 10px clamp(16px, 4vw, 36px);
    position: sticky;
    top: 0;
    z-index: 20;
}
.brand {
    align-items: center;
    color: var(--ink);
    display: flex;
    font-weight: 800;
    gap: 10px;
    text-decoration: none;
}
.brand span, .auth-logo {
    align-items: center;
    background: var(--blue);
    border-radius: 12px;
    color: #fff;
    display: flex;
    font-size: 19px;
    font-weight: 800;
    height: 43px;
    justify-content: center;
    width: 43px;
}
.main-nav { display: flex; gap: 4px; }
.main-nav a {
    border-radius: 8px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
    padding: 10px 12px;
    text-decoration: none;
}
.main-nav a.active, .main-nav a:hover { background: #eaf7fe; color: var(--ink); }
.user-menu { align-items: center; display: flex; gap: 13px; margin-left: auto; }
.user-menu > span { font-size: 13px; font-weight: 800; }
.admin-topbar { border-bottom-color: #b9e8ff; }
.admin-topbar .brand span { background: #102a3b; }
.locale-form select {
    background: #f1f8fc;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--ink);
    font-size: 11px;
    font-weight: 800;
    min-height: 34px;
    padding: 5px 7px;
    width: auto;
}
.guest-locale { position: fixed; right: 18px; top: 18px; z-index: 10; }
.sr-only {
    clip: rect(0, 0, 0, 0);
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
}
.link-button {
    background: transparent;
    border: 0;
    color: var(--blue-dark);
    cursor: pointer;
    font-size: 13px;
    font-weight: 800;
    padding: 0;
}
.nav-toggle { display: none; }

.app-shell { margin: 0 auto; max-width: 1240px; padding: 30px clamp(15px, 4vw, 36px) 50px; }
.guest-shell { align-items: center; display: flex; justify-content: center; min-height: 100vh; padding: 28px 16px; }
.page-heading {
    align-items: flex-end;
    display: flex;
    gap: 20px;
    justify-content: space-between;
    margin-bottom: 22px;
}
.page-heading h1 { font-size: clamp(27px, 4vw, 39px); letter-spacing: -.04em; margin: 4px 0 6px; }
.page-heading p { color: var(--muted); margin: 0; }
.eyebrow { color: var(--blue-dark) !important; font-size: 11px; font-weight: 800; letter-spacing: .12em; margin: 0; text-transform: uppercase; }
.back-link { display: inline-block; font-size: 13px; font-weight: 800; margin-bottom: 8px; text-decoration: none; }

.primary-button {
    align-items: center;
    background: var(--blue);
    border: 0;
    border-radius: 9px;
    color: #fff;
    cursor: pointer;
    display: inline-flex;
    font-size: 13px;
    font-weight: 800;
    justify-content: center;
    min-height: 43px;
    padding: 11px 17px;
    text-decoration: none;
}
.primary-button:hover { background: var(--blue-dark); }
.secondary-button {
    align-items: center;
    background: #eef5f8;
    border: 1px solid var(--line);
    border-radius: 9px;
    color: var(--ink);
    display: inline-flex;
    font-size: 12px;
    font-weight: 800;
    justify-content: center;
    min-height: 43px;
    padding: 10px 15px;
    text-decoration: none;
}
.danger-button {
    align-items: center;
    background: var(--danger);
    border: 0;
    border-radius: 9px;
    color: #fff;
    cursor: pointer;
    display: inline-flex;
    font-size: 12px;
    font-weight: 800;
    justify-content: center;
    min-height: 43px;
    padding: 10px 15px;
}
.notice { border-radius: 10px; margin-bottom: 18px; padding: 13px 15px; }
.notice.success { background: #e8f8ef; border: 1px solid #a9ddbf; color: #0d7040; }
.notice.error { background: #fff0ee; border: 1px solid #f1b8b1; color: var(--danger); }
.notice-info { background: #eef8fd; border: 1px solid #b9e5f8; border-radius: 10px; color: var(--blue-dark); margin: 0; padding: 12px 14px; }

.stats-grid { display: grid; gap: 14px; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 24px; }
.stat-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 14px;
    color: var(--ink);
    display: flex;
    flex-direction: column;
    min-height: 115px;
    padding: 20px;
    text-decoration: none;
}
.stat-card strong { font: 800 32px "Plus Jakarta Sans", Arial, sans-serif; }
.stat-card span { color: var(--muted); font-size: 12px; margin-top: 5px; }
.panel {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 15px;
    box-shadow: 0 10px 35px rgba(20, 69, 95, .05);
    padding: 21px;
}
.panel-heading { align-items: center; display: flex; justify-content: space-between; margin-bottom: 13px; }
.panel-heading h2 { font-size: 20px; margin: 4px 0 0; }
.panel-heading > a { font-size: 12px; font-weight: 800; text-decoration: none; }
.package-panel { margin-bottom: 24px; }
.plan-badge, .limit-label {
    background: #eaf7fe;
    border-radius: 999px;
    color: var(--blue-dark);
    font-size: 11px;
    font-weight: 800;
    padding: 7px 10px;
}
.limit-label { background: #fff0ee; color: var(--danger); }
.usage-grid {
    display: grid;
    gap: 13px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.usage-card {
    background: #f6fafc;
    border: 1px solid var(--line);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 15px;
}
.usage-card > span { color: var(--muted); font-size: 11px; font-weight: 800; text-transform: uppercase; }
.usage-card strong { font: 800 20px "Plus Jakarta Sans", Arial, sans-serif; }
.usage-track { background: #dcecf3; border-radius: 999px; height: 7px; overflow: hidden; }
.usage-track span { background: var(--blue); border-radius: inherit; display: block; height: 100%; }
.package-note { color: var(--muted); font-size: 12px; margin: 14px 0 0; }
.data-list { display: flex; flex-direction: column; }
.data-row {
    align-items: center;
    border-bottom: 1px solid #e7eff3;
    color: var(--ink);
    display: flex;
    gap: 20px;
    justify-content: space-between;
    padding: 15px 4px;
    text-decoration: none;
}
.data-row:last-child { border-bottom: 0; }
.data-row > div { display: flex; flex-direction: column; min-width: 0; }
.data-row > div:last-child { align-items: flex-end; flex: 0 0 auto; }
.data-row strong { font-size: 14px; }
.data-row span, .data-row small { color: var(--muted); font-size: 11px; margin-top: 4px; }
.status { border-radius: 999px; font-weight: 800; padding: 4px 8px; }
.status.active { background: #e5f8ee; color: var(--success); }
.status.inactive { background: #f1f3f4; color: var(--muted); }
.status-trial { background: #fff5d9; color: #8b6400; }
.status-active { background: #e5f8ee; color: var(--success); }
.status-suspended { background: #ffe7e4; color: var(--danger); }
.status-cancelled { background: #edf0f2; color: #536774; }
.company-meta { max-width: 48%; }
.empty-inline { color: var(--muted); padding: 22px 4px; }

.form-grid { display: grid; gap: 17px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid label, .form-stack label { display: flex; flex-direction: column; gap: 7px; }
.form-grid label > span, .form-stack label > span { font-size: 12px; font-weight: 800; }
.form-grid .wide { grid-column: 1 / -1; }
input, select, textarea {
    background: #fff;
    border: 1px solid #b4c8d2;
    border-radius: 9px;
    color: var(--ink);
    min-height: 45px;
    padding: 10px 12px;
    width: 100%;
}
textarea { min-height: auto; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--blue); outline: 3px solid rgba(0, 166, 251, .13); }
.password-control { display: block; position: relative; width: 100%; }
.password-control input { padding-right: 50px; }
.password-toggle {
    align-items: center;
    background: transparent;
    border: 0;
    color: var(--blue-dark);
    cursor: pointer;
    display: flex;
    height: 36px;
    justify-content: center;
    min-height: 34px;
    padding: 7px;
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
}
.password-toggle:hover { color: var(--ink); }
.password-toggle:focus-visible { border-radius: 7px; outline: 3px solid rgba(0, 166, 251, .2); }
.password-toggle svg {
    fill: none;
    height: 21px;
    pointer-events: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
    width: 21px;
}
label small { color: var(--muted); line-height: 1.45; }
.field-error { color: var(--danger) !important; }
.check-row { align-items: center; flex-direction: row !important; font-size: 13px; }
.check-row input { min-height: auto; width: auto; }
.permission-box {
    border: 1px solid var(--line);
    border-radius: 12px;
    margin: 0;
    padding: 15px;
}
.permission-box legend { font-size: 12px; font-weight: 800; padding: 0 6px; }
.permission-box > p { color: var(--muted); font-size: 12px; margin: 0 0 13px; }
.permission-grid { display: grid; gap: 11px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.weekday-grid { display: grid; gap: 10px; grid-template-columns: repeat(4, minmax(0, 1fr)); }

.dashboard-work-orders { margin-bottom: 24px; }
.worker-dashboard { margin: 0 auto; max-width: 760px; }
.work-order-list { display: flex; flex-direction: column; }
.work-order-card {
    align-items: center;
    border-bottom: 1px solid #e7eff3;
    color: var(--ink);
    display: flex;
    gap: 14px;
    padding: 14px 3px;
    text-decoration: none;
}
.work-order-card:last-child { border-bottom: 0; }
.work-order-card:hover .work-order-main > strong,
.work-order-card:hover .work-order-heading > strong { color: var(--blue-dark); }
.work-order-date {
    align-items: center;
    background: #eaf7fe;
    border-radius: 12px;
    color: var(--blue-dark);
    display: flex;
    flex: 0 0 58px;
    flex-direction: column;
    justify-content: center;
    min-height: 58px;
}
.work-order-date strong { font: 800 22px "Plus Jakarta Sans", Arial, sans-serif; line-height: 1; }
.work-order-date span { font-size: 10px; font-weight: 800; margin-top: 4px; text-transform: uppercase; }
.work-order-main { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.work-order-main > span { color: var(--muted); font-size: 12px; margin-top: 5px; }
.work-order-main > small { color: var(--muted); font-size: 11px; margin-top: 3px; }
.work-order-heading { align-items: center; display: flex; gap: 12px; justify-content: space-between; }
.work-order-heading > strong { font-size: 14px; }
.status-planned { background: #eaf7fe; color: var(--blue-dark); }
.status-in_progress { background: #fff2d8; color: #8b6100; }
.status-completed { background: #e5f8ee; color: var(--success); }
.status-cancelled { background: #f1f3f4; color: var(--muted); }
.status-large { display: inline-flex; font-size: 12px; padding: 8px 12px; }
.work-order-filters {
    align-items: end;
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(5, minmax(130px, 1fr)) auto auto;
    margin-bottom: 18px;
    padding: 14px;
}
.work-order-filters label { display: flex; flex-direction: column; gap: 6px; }
.work-order-filters label > span { font-size: 11px; font-weight: 800; }
.work-order-detail-grid { display: grid; gap: 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.wide-detail { grid-column: 1 / -1; }
.work-order-detail-grid h2 { margin: 7px 0 8px; }
.detail-line { color: var(--muted); line-height: 1.6; }
.detail-note { background: #f4f8fb; border-radius: 10px; margin-top: 16px; padding: 13px; }
.detail-note strong { font-size: 12px; }
.detail-note p { color: var(--muted); line-height: 1.6; margin: 6px 0 0; }
.pre-line { line-height: 1.7; white-space: pre-line; }
.assignee-list { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 12px; }
.assignee-list span { background: #eef5f8; border-radius: 999px; font-size: 11px; font-weight: 800; padding: 7px 10px; }
.work-order-actions { align-items: center; display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; }
.worker-action-form { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr) auto; width: 100%; }
.worker-action-form label { display: flex; flex-direction: column; gap: 7px; }
.worker-action-form label > span { font-size: 12px; font-weight: 800; }
.worker-action-form button { align-self: end; min-width: 170px; }
.complete-button { background: var(--success); }
.complete-button:hover { background: #0f7040; }
.execution-panel, .checklist-panel, .operational-grid, .time-summary-panel { margin-top: 18px; }
.execution-panel { border-color: #a9dff8; }
.execution-main-button { min-height: 54px; min-width: 190px; }
.execution-button-grid { display: flex; gap: 10px; }
.finish-work-form {
    border-top: 1px solid var(--line);
    display: grid;
    gap: 13px;
    grid-template-columns: minmax(0, 1fr) auto;
    margin-top: 18px;
    padding-top: 18px;
}
.finish-work-form label, .photo-upload-form label, .material-request-form label {
    display: flex;
    flex-direction: column;
    gap: 7px;
}
.finish-work-form label > span, .photo-upload-form label > span, .material-request-form label > span {
    font-size: 12px;
    font-weight: 800;
}
.finish-work-form button { align-self: end; }
.live-time, .checklist-progress {
    background: #eaf7fe;
    border-radius: 999px;
    color: var(--blue-dark);
    font-size: 12px;
    font-weight: 800;
    padding: 8px 11px;
}
.completed-session {
    align-items: flex-start;
    background: #e8f8ef;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 15px;
}
.completed-session span { color: var(--muted); font-size: 12px; }
.checklist-row {
    align-items: center;
    border-bottom: 1px solid #e7eff3;
    display: flex;
    gap: 12px;
    justify-content: space-between;
    padding: 10px 0;
}
.checklist-row:last-child { border-bottom: 0; }
.checklist-toggle {
    align-items: center;
    background: transparent;
    border: 0;
    color: var(--ink);
    cursor: pointer;
    display: flex;
    flex: 1;
    font-weight: 700;
    gap: 11px;
    padding: 2px;
    text-align: left;
}
div.checklist-toggle { cursor: default; }
.checklist-row.completed .checklist-toggle > span:last-child {
    color: var(--muted);
    text-decoration: line-through;
}
.checkmark {
    align-items: center;
    border: 2px solid #9cb5c1;
    border-radius: 6px;
    color: #fff;
    display: flex;
    flex: 0 0 26px;
    height: 26px;
    justify-content: center;
    width: 26px;
}
.checklist-row.completed .checkmark { background: var(--success); border-color: var(--success); }
.checklist-row small { color: var(--muted); font-size: 10px; }
.operational-grid { align-items: start; }
.photo-upload-form, .material-request-form {
    background: #f5f9fb;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 11px;
    margin-bottom: 16px;
    padding: 14px;
}
.photo-grid {
    display: grid;
    gap: 11px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.work-photo {
    background: #f4f8fb;
    border: 1px solid var(--line);
    border-radius: 11px;
    margin: 0;
    overflow: hidden;
    position: relative;
}
.work-photo img {
    aspect-ratio: 4 / 3;
    object-fit: cover;
    width: 100%;
}
.work-photo figcaption { display: flex; flex-direction: column; gap: 3px; padding: 9px; }
.work-photo figcaption span { font-size: 11px; font-weight: 800; }
.work-photo figcaption small { color: var(--muted); font-size: 9px; }
.work-photo form { position: absolute; right: 5px; top: 5px; }
.photo-delete {
    background: rgba(16, 42, 59, .82);
    border: 0;
    border-radius: 7px;
    color: #fff;
    cursor: pointer;
    font-size: 9px;
    font-weight: 800;
    padding: 6px 8px;
}
.material-list { display: flex; flex-direction: column; margin-bottom: 14px; }
.material-item {
    border-bottom: 1px solid #e7eff3;
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 9px 0;
}
.material-item span, .material-item small { color: var(--muted); font-size: 11px; }
.time-entry-list, .material-management-list { display: flex; flex-direction: column; }
.time-entry-row, .material-management-row {
    align-items: center;
    border-bottom: 1px solid #e7eff3;
    display: flex;
    gap: 20px;
    justify-content: space-between;
    padding: 14px 3px;
}
.time-entry-row:last-child, .material-management-row:last-child { border-bottom: 0; }
.time-entry-row > div, .material-management-row > div {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.time-entry-row > div:last-child { align-items: flex-end; flex: 0 0 auto; }
.time-entry-row span, .time-entry-row small,
.material-management-row span, .material-management-row small {
    color: var(--muted);
    font-size: 11px;
}
.time-entry-row a, .material-management-row a { font-size: 11px; font-weight: 800; }
.material-management-row { align-items: flex-start; }
.material-management-row.urgent { border-left: 4px solid var(--danger); padding-left: 12px; }
.material-management-row p { color: var(--muted); font-size: 12px; margin: 5px 0; }
.material-management-row form { align-items: center; display: flex; flex: 0 0 260px; gap: 8px; }
.material-management-row select { min-width: 130px; }
.time-entry-filters { grid-template-columns: repeat(4, minmax(130px, 1fr)) auto auto; }
.material-filters { grid-template-columns: repeat(2, minmax(180px, 1fr)) auto auto; }
.admin-form { display: flex; flex-direction: column; gap: 18px; }
.form-section-title { border-bottom: 1px solid var(--line); padding-bottom: 12px; }
.form-submit { align-self: flex-end; min-width: 170px; }
.filter-bar {
    align-items: center;
    display: grid;
    gap: 10px;
    grid-template-columns: minmax(220px, 1fr) 170px 170px auto auto;
    margin-bottom: 18px;
    padding: 14px;
}
.filter-bar input, .filter-bar select { min-height: 43px; }
.admin-stats { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.security-grid {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.security-grid h2, .setup-panel h2, .recovery-panel h2, .empty-security h2 { margin: 6px 0 8px; }
.danger-panel { border-color: #f2c7c2; }
.recovery-panel {
    background: #fffbea;
    border-color: #eedb91;
    margin-bottom: 18px;
}
.recovery-grid {
    display: grid;
    gap: 9px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 18px;
}
.recovery-grid code, .secret-box code {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--ink);
    font: 700 13px Consolas, monospace;
    letter-spacing: .08em;
    padding: 11px;
    text-align: center;
}
.setup-steps {
    color: var(--muted);
    line-height: 1.7;
    margin: 16px 0 20px;
    padding-left: 22px;
}
.app-link { margin-bottom: 18px; }
.secret-box {
    background: #f2f8fb;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 9px;
    margin: 4px 0 20px;
    padding: 15px;
}
.secret-box span { font-size: 12px; font-weight: 800; }
.secret-box code { overflow-wrap: anywhere; }
.confirm-form { max-width: 430px; }
.empty-security { padding: 44px; text-align: center; }
.empty-security .primary-button { margin-top: 8px; }
.security-icon {
    align-items: center;
    background: #eaf7fe;
    border-radius: 50%;
    color: var(--blue-dark);
    display: flex;
    font: 800 27px "Plus Jakarta Sans", Arial, sans-serif;
    height: 66px;
    justify-content: center;
    margin: 0 auto 18px;
    width: 66px;
}

.auth-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 20px;
    box-shadow: 0 22px 65px rgba(10, 70, 105, .13);
    max-width: 440px;
    padding: 32px;
    width: 100%;
}
.auth-card-wide { max-width: 680px; }
.auth-logo { height: 58px; margin-bottom: 22px; width: 58px; }
.auth-card h1 { font-size: 30px; letter-spacing: -.035em; margin: 7px 0 9px; }
.muted { color: var(--muted); line-height: 1.6; }
.form-stack { display: flex; flex-direction: column; gap: 16px; margin-top: 23px; }
.auth-footer { color: var(--muted); font-size: 13px; margin: 20px 0 0; text-align: center; }
.auth-footer a { font-weight: 800; }
.empty-state {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 18px;
    margin: 8vh auto;
    max-width: 590px;
    padding: 46px 28px;
    text-align: center;
}
.empty-icon {
    align-items: center;
    background: #e8f8ef;
    border-radius: 50%;
    color: var(--success);
    display: flex;
    font-size: 26px;
    height: 64px;
    justify-content: center;
    margin: 0 auto 20px;
    width: 64px;
}
.empty-state h2 { margin: 0 0 9px; }
.empty-state p { color: var(--muted); line-height: 1.6; margin: 0; }

nav[role="navigation"] { margin-top: 18px; }

@media (max-width: 800px) {
    .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .admin-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .nav-toggle {
        background: #eaf7fe;
        border: 0;
        border-radius: 8px;
        color: var(--blue-dark);
        display: block;
        font-size: 12px;
        font-weight: 800;
        margin-left: auto;
        padding: 9px 11px;
    }
    .main-nav {
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: 0 16px 30px rgba(10, 50, 75, .1);
        display: none;
        flex-direction: column;
        left: 0;
        padding: 12px 15px;
        position: absolute;
        right: 0;
        top: 71px;
    }
    .main-nav.open { display: flex; }
    .user-menu > span { display: none; }
    .filter-bar { grid-template-columns: 1fr 1fr; }
    .filter-bar input { grid-column: 1 / -1; }
    .security-grid { grid-template-columns: 1fr; }
    .work-order-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .work-order-detail-grid { grid-template-columns: 1fr; }
    .wide-detail { grid-column: auto; }
}

@media (max-width: 620px) {
    .topbar { min-height: 64px; padding: 9px 13px; }
    .brand strong { display: none; }
    .main-nav { top: 63px; }
    .app-shell { padding: 19px 13px 40px; }
    .page-heading { align-items: stretch; flex-direction: column; gap: 14px; }
    .page-heading > .primary-button { width: 100%; }
    .stats-grid { gap: 9px; }
    .stat-card { min-height: 100px; padding: 15px; }
    .stat-card strong { font-size: 26px; }
    .panel { border-radius: 13px; padding: 15px; }
    .form-grid { grid-template-columns: 1fr; }
    .form-grid .wide { grid-column: auto; }
    .data-row { align-items: flex-start; }
    .company-meta { max-width: 54%; }
    .filter-bar { grid-template-columns: 1fr; }
    .filter-bar input { grid-column: auto; }
    .filter-bar .primary-button, .filter-bar .secondary-button { width: 100%; }
    .form-submit { align-self: stretch; width: 100%; }
    .recovery-grid { grid-template-columns: 1fr; }
    .usage-grid, .permission-grid { grid-template-columns: 1fr; }
    .weekday-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .work-order-filters { grid-template-columns: 1fr; }
    .work-order-filters .primary-button, .work-order-filters .secondary-button { width: 100%; }
    .work-order-card { align-items: flex-start; }
    .work-order-heading { align-items: flex-start; flex-direction: column; gap: 4px; }
    .worker-action-form { grid-template-columns: 1fr; }
    .worker-action-form button { min-height: 52px; width: 100%; }
    .work-order-actions { align-items: stretch; flex-direction: column; }
    .work-order-actions > *, .work-order-actions form button { width: 100%; }
    .finish-work-form { grid-template-columns: 1fr; }
    .execution-main-button, .execution-button-grid, .execution-button-grid form { width: 100%; }
    .photo-grid { grid-template-columns: 1fr 1fr; }
    .checklist-row { align-items: flex-start; flex-direction: column; gap: 5px; }
    .time-entry-row, .material-management-row { align-items: stretch; flex-direction: column; }
    .time-entry-row > div:last-child { align-items: flex-start; }
    .material-management-row form { flex: auto; width: 100%; }
    .material-management-row form select { flex: 1; }
    .empty-security { padding: 32px 20px; }
    .guest-locale { right: 10px; top: 10px; }
    .auth-card { border: 0; border-radius: 0; box-shadow: none; min-height: 100vh; padding: 36px 22px; }
    .guest-shell { align-items: flex-start; background: #fff; padding: 0; }
    .password-control input { padding-right: 50px; }
}
