@import url('https://fonts.googleapis.com/css2?family=Sarabun:ital,wght@0,300;0,400;0,700;1,400&display=swap');

:root {
    --primary-color: #1e3a8a;
    --secondary-color: #3b82f6;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --bg-color: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}

* { box-sizing: border-box; }

body {
    font-family: 'Sarabun', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    margin: 0;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Layout - Full screen for desktop, responsive for mobile */
.container {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 2rem 3rem;
    flex: 1;
}

.main-footer {
    background: white;
    padding: 2rem 1rem;
    border-top: 1px solid var(--border-color);
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: auto;
}

.footer-content b {
    color: var(--primary-color);
    display: block;
    margin-bottom: 0.25rem;
}

.header-nav {
    background: var(--primary-color);
    color: white;
    padding: 0.75rem 2rem;
    display: flex;
    align-items: center;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-brand {
    font-size: 1.25rem;
    font-weight: bold;
    white-space: nowrap;
    margin-right: 2rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-logo {
    height: 32px;
    width: auto;
    object-fit: contain;
}

.nav-links {
    display: flex;
    align-items: center;
    flex-grow: 1;
}

.header-nav a {
    color: white;
    text-decoration: none;
    margin-right: 1.5rem;
    font-weight: 500;
    transition: opacity 0.2s;
    white-space: nowrap;
}

.header-nav a:hover { opacity: 0.8; }

.logout-link {
    margin-left: auto !important;
    margin-right: 0 !important;
    background: rgba(255,255,255,0.1);
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
}

/* Dropdown Menu */
.dropdown {
    position: relative;
    display: inline-block;
    margin-right: 1.5rem;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: white;
    min-width: 200px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 10;
    border-radius: 0.5rem;
    overflow: hidden;
    top: 100%;
}

.dropdown-content a {
    color: var(--text-main) !important;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    margin-right: 0 !important;
    font-size: 0.9rem;
    border-bottom: 1px solid #f1f5f9;
}

.dropdown-content a:hover { background-color: #f8fafc; }
.dropdown:hover .dropdown-content { display: block; }
.dropdown-trigger { color: white; cursor: pointer; font-weight: 500; white-space: nowrap; }

/* Mobile Menu Toggle */
.menu-toggle { display: none; cursor: pointer; font-size: 1.5rem; margin-left: auto; }

/* Components */
.card {
    background: var(--card-bg);
    border-radius: 0.75rem;
    box-shadow: var(--shadow);
    padding: 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
}

h1, h2, h3 {
    color: var(--primary-color);
    margin-top: 0;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.5rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.btn-primary { background: var(--secondary-color); color: white; }
.btn-primary:hover { background: #2563eb; }

.btn-success { background: var(--success-color); color: white; }
.btn-success:hover { background: #059669; }

.btn-danger { background: var(--danger-color); color: white; }
.btn-danger:hover { background: #dc2626; }

.btn-outline {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-main);
}
.btn-outline:hover { background: #f1f5f9; }

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

th {
    background: #f1f5f9;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 2px solid var(--border-color);
}

td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

tr:hover { background-color: #f8fafc; }

/* Form Elements */
input[type="text"], 
input[type="number"], 
input[type="date"], 
input[type="password"], 
input[type="file"],
select, 
textarea {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    font-family: inherit;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

input:focus, select:focus {
    outline: 2px solid var(--secondary-color);
    outline-offset: -1px;
}

/* Utils */
.badge {
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    display: inline-block;
}

.progress-container {
    width: 100%;
    background-color: #e2e8f0;
    border-radius: 0.5rem;
    margin: 1rem 0;
    display: none;
    height: 1.5rem;
    position: relative;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background-color: var(--secondary-color);
    width: 0%;
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.75rem;
    font-weight: bold;
}

.success { color: var(--success-color); font-weight: bold; }
.error { color: var(--danger-color); font-weight: bold; }

.toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    background: #f1f5f9;
    padding: 1rem;
    border-radius: 0.5rem;
}

.group-header {
    background: #eff6ff;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    margin-top: 2rem;
    font-weight: bold;
    color: var(--primary-color);
    border-left: 4px solid var(--secondary-color);
}

/* Responsive Grid Utilities */
.grid-2-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.form-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.dashboard-menu-activity-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

.users-layout-grid {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 2rem;
    align-items: flex-start;
}

.import-add-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.criteria-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

.signature-block, .eval-info, .grid-3-col {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 1rem;
}

.noti-row-header {
    background: #f8fafc;
    padding: 0.5rem 1.5rem;
    display: grid;
    grid-template-columns: 1.5fr 1.5fr 1.5fr 1fr;
    gap: 1rem;
    font-size: 0.75rem;
    font-weight: bold;
    color: #64748b;
    border-bottom: 1px solid #e2e8f0;
}

.noti-row-item {
    display: grid;
    grid-template-columns: 1.5fr 1.5fr 1.5fr 1fr;
    gap: 1rem;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #f1f5f9;
    align-items: center;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .container { padding: 2rem 5%; }
}

@media (max-width: 1024px) {
    .container { padding: 1.5rem 3%; }
    .action-buttons { grid-template-columns: 1fr 1fr !important; }
    
    /* Navigation Bar Collapsing */
    .header-nav { padding: 0.75rem 1rem; flex-wrap: wrap; }
    .nav-brand { margin-right: 0; }
    .nav-links { 
        display: none; 
        flex-direction: column; 
        width: 100%; 
        margin-top: 1rem;
        background: rgba(255,255,255,0.1);
        padding: 1rem;
        border-radius: 0.5rem;
        flex-grow: 0;
    }
    .nav-links.active { display: flex; }
    .header-nav a, .dropdown { margin-right: 0; margin-bottom: 0.75rem; width: 100%; }
    .logout-link { margin-left: 0 !important; width: 100%; text-align: center; }
    .dropdown-content { position: static; box-shadow: none; background: #f1f5f9; width: 100%; margin-top: 0.5rem; }
    .menu-toggle { display: block; }

    /* Responsive Grid Adjustments */
    .grid-2-col { grid-template-columns: 1fr; gap: 1.5rem; }
    .dashboard-menu-activity-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .users-layout-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .import-add-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    
    /* Responsive Notification Adjustments */
    .noti-row-header { display: none !important; }
    .noti-row-item { grid-template-columns: 1fr !important; gap: 0.5rem; padding: 1rem; }
    .noti-row-item > div { text-align: left !important; }
    
    table { display: block; overflow-x: auto; }
}

@media (max-width: 768px) {
    .container { padding: 1rem 15px; }
    .form-grid-2 { grid-template-columns: 1fr; }
    .signature-block, .eval-info, .grid-3-col { grid-template-columns: 1fr !important; }
    .card { padding: 1rem; border-radius: 0.5rem; }
    .toolbar { flex-direction: column; gap: 1rem; align-items: stretch; }
    .action-buttons { grid-template-columns: 1fr !important; }
    .security-footer-card { flex-direction: column !important; text-align: center; gap: 1rem !important; }
}

@media print {
    .no-print { display: none !important; }
    .container { padding: 0; }
    .card { box-shadow: none; border: 1px solid #eee; }
}

/* --------------------------------------------------------------------------
   Application shell: visual-only sidebar navigation.
   It reuses the original navigation markup and links, so routes and page
   behaviour stay exactly the same. The existing menu button toggles .active.
   -------------------------------------------------------------------------- */
@media (min-width: 769px) {
    :root { --sidebar-width: 272px; --sidebar-collapsed-width: 78px; }

    body:has(.header-nav) {
        padding-left: var(--sidebar-width);
        background: #f5f7fb;
        transition: padding-left .22s ease;
    }

    .header-nav {
        position: fixed;
        inset: 0 auto 0 0;
        width: var(--sidebar-width);
        min-height: 100vh;
        overflow: visible;
        padding: 1.15rem .8rem;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        background: linear-gradient(165deg, #102a66 0%, #1e3a8a 48%, #1d4ed8 130%);
        box-shadow: 8px 0 28px rgba(15, 23, 42, .14);
        transition: width .22s ease, padding .22s ease;
        z-index: 1000;
    }

    .nav-brand {
        margin: 0 0 1.4rem;
        min-height: 48px;
        padding: .55rem .6rem;
        border-radius: .75rem;
        background: rgba(255,255,255,.1);
        overflow: hidden;
    }
    .nav-logo { width: 34px; height: 34px; flex: 0 0 34px; }
    .nav-links { display: flex; flex-direction: column; align-items: stretch; gap: .25rem; width: 100%; }
    .header-nav a, .dropdown { width: 100%; margin: 0 !important; }
    .header-nav a, .dropdown-trigger {
        display: flex;
        align-items: center;
        padding: .66rem .75rem;
        border-radius: .55rem;
        line-height: 1.35;
        color: white;
        text-decoration: none;
        transition: all .18s ease;
    }
    .header-nav a:hover, .dropdown-trigger:hover, .header-nav a.active {
        opacity: 1;
        background: rgba(255,255,255,.16);
    }
    .header-nav a.active {
        background: rgba(255,255,255,.18);
        box-shadow: inset 3px 0 0 #60a5fa;
    }

    /* Flyout Dropdown Menu (Desktop) */
    .dropdown {
        display: block;
        position: relative;
    }
    .dropdown-trigger {
        justify-content: space-between;
        cursor: pointer;
        user-select: none;
    }
    .dropdown-trigger.active,
    .dropdown:has(.dropdown-content a.active) > .dropdown-trigger {
        background: rgba(255, 255, 255, 0.18);
        box-shadow: inset 3px 0 0 #60a5fa;
    }
    .dropdown:hover > .dropdown-trigger {
        background: rgba(255, 255, 255, 0.2);
    }
    .dropdown-label {
        display: flex;
        align-items: center;
        gap: .5rem;
        min-width: 0;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    .dropdown-arrow {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 1.25rem;
        line-height: 1;
        opacity: .75;
        transition: transform .22s cubic-bezier(0.16, 1, 0.3, 1), opacity .2s ease, color .2s ease;
        margin-left: .5rem;
        color: rgba(255, 255, 255, .85);
    }
    .dropdown:hover > .dropdown-trigger .dropdown-arrow,
    .dropdown.is-hovered > .dropdown-trigger .dropdown-arrow {
        transform: translateX(4px);
        opacity: 1;
        color: #93c5fd;
    }
    .dropdown.is-open > .dropdown-trigger .dropdown-arrow,
    .dropdown.is-flyout-active > .dropdown-trigger .dropdown-arrow {
        transform: translateX(4px) rotate(90deg);
        opacity: 1;
        color: #60a5fa;
    }

    .dropdown.is-open > .dropdown-trigger,
    .dropdown.is-flyout-active > .dropdown-trigger {
        background: rgba(59, 130, 246, 0.32);
        box-shadow: inset 3px 0 0 #60a5fa;
        opacity: 1;
    }

    /* Invisible hover bridge extending from trigger towards flyout panel */
    .header-nav .dropdown::after {
        content: '';
        position: absolute;
        top: -8px;
        bottom: -8px;
        right: -24px;
        width: 32px;
        background: transparent;
        pointer-events: auto;
        z-index: 1150;
    }

    /* Modern Flyout Submenu Panel */
    .header-nav .dropdown-content {
        display: flex;
        flex-direction: column;
        gap: .25rem;
        position: absolute;
        left: calc(100% + 8px);
        top: 0;
        min-width: 270px;
        max-width: 350px;
        max-height: calc(100vh - 24px);
        overflow-y: auto;
        scrollbar-width: thin;
        scrollbar-color: rgba(255, 255, 255, 0.25) transparent;
        padding: .65rem;
        background: linear-gradient(155deg, rgba(10, 24, 62, 0.98) 0%, rgba(18, 45, 110, 0.98) 100%);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255, 255, 255, 0.18);
        border-radius: .9rem;
        box-shadow: 0 20px 45px -4px rgba(4, 12, 38, 0.65), 0 8px 20px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transform: translateX(10px) scale(0.97);
        /* Closing grace delay: allows smooth diagonal cursor transit */
        transition: opacity .22s cubic-bezier(0.16, 1, 0.3, 1) .25s,
                    transform .22s cubic-bezier(0.16, 1, 0.3, 1) .25s,
                    visibility .22s ease .25s;
        z-index: 1200;
        margin: 0;
    }
    .header-nav .dropdown-content::-webkit-scrollbar {
        width: 4px;
    }
    .header-nav .dropdown-content::-webkit-scrollbar-thumb {
        background: rgba(255, 255, 255, 0.25);
        border-radius: 4px;
    }

    /* Invisible hover bridge extending from flyout panel towards trigger */
    .header-nav .dropdown-content::before {
        content: '';
        position: absolute;
        top: -35px;
        bottom: -35px;
        left: -32px;
        width: 42px;
        background: transparent;
        pointer-events: auto;
        z-index: 1150;
    }

    /* Hover, Hovered, Open & Active Display Rules - Instant show */
    .dropdown:hover > .dropdown-content,
    .dropdown.is-hovered > .dropdown-content,
    .dropdown.is-open > .dropdown-content,
    .dropdown.is-flyout-active > .dropdown-content {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateX(0) scale(1);
        transition: opacity .16s cubic-bezier(0.16, 1, 0.3, 1) 0s,
                    transform .16s cubic-bezier(0.16, 1, 0.3, 1) 0s,
                    visibility .16s ease 0s;
    }

    /* Flyout Links */
    .header-nav .dropdown-content a {
        display: flex;
        align-items: center;
        gap: .65rem;
        padding: .65rem .85rem;
        color: rgba(255, 255, 255, 0.92) !important;
        font-size: .88rem;
        font-weight: 500;
        line-height: 1.4;
        border-radius: .6rem;
        text-decoration: none;
        white-space: normal;
        border: 1px solid transparent;
        background: transparent;
        transition: all .16s ease;
        cursor: pointer;
    }
    .header-nav .dropdown-content a:hover {
        background: rgba(255, 255, 255, 0.16);
        border-color: rgba(255, 255, 255, 0.12);
        color: #ffffff !important;
        transform: translateX(4px);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }
    .header-nav .dropdown-content a.active {
        background: linear-gradient(90deg, rgba(59, 130, 246, 0.45) 0%, rgba(37, 99, 235, 0.25) 100%);
        border-color: rgba(96, 165, 250, 0.4);
        color: #ffffff !important;
        font-weight: 600;
        box-shadow: inset 3px 0 0 #60a5fa, 0 4px 12px rgba(37, 99, 235, 0.2);
    }
    .logout-link { margin-top: .8rem !important; padding: .65rem .75rem !important; text-align: left; }
    .menu-toggle {
        display: grid;
        place-items: center;
        position: fixed;
        left: calc(var(--sidebar-width) - 18px);
        top: 1.25rem;
        width: 36px;
        height: 36px;
        margin: 0;
        border: 1px solid rgba(30,58,138,.12);
        border-radius: 50%;
        color: var(--primary-color);
        background: #fff;
        box-shadow: 0 4px 12px rgba(15,23,42,.16);
        font-size: 0;
        z-index: 1100;
        transition: left .22s ease;
    }
    .menu-toggle::after {
        content: '‹';
        font-size: 1.8rem;
        font-family: Arial, sans-serif;
        font-weight: 400;
        line-height: 1;
    }

    /* Collapsed state is activated by the original toggleMenu() function. */
    body.sidebar-is-collapsed { padding-left: var(--sidebar-collapsed-width); }
    .header-nav.is-collapsed { width: var(--sidebar-collapsed-width); padding-inline: .55rem; overflow: visible; }
    .header-nav.is-collapsed .nav-brand { padding-inline: .25rem; justify-content: center; background: transparent; }
    .header-nav.is-collapsed .nav-brand span,
    .header-nav.is-collapsed .nav-links { display: none; }
    .header-nav.is-collapsed .menu-toggle { left: calc(var(--sidebar-collapsed-width) - 18px); }
    .header-nav.is-collapsed .menu-toggle::after { content: '›'; }

    .container { padding: 2rem clamp(1.5rem, 3vw, 3.5rem); }
    .main-footer { margin-left: 0; }

    .app-topbar {
        min-height: 78px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 1.5rem;
        padding: .85rem clamp(1.5rem, 3vw, 3.5rem);
        background: rgba(255,255,255,.94);
        border-bottom: 1px solid #e2e8f0;
        box-shadow: 0 2px 10px rgba(15,23,42,.04);
        position: sticky;
        top: 0;
        z-index: 900;
        backdrop-filter: blur(12px);
    }
    .app-title { display: flex; align-items: center; gap: .85rem; min-width: 0; }
    .app-title-mark { display: grid; place-items: center; flex: 0 0 40px; width: 40px; height: 40px; border-radius: .7rem; color: #fff; background: linear-gradient(145deg, #1e3a8a, #3b82f6); font-size: .67rem; font-weight: 800; letter-spacing: .04em; }
    .app-title strong, .app-title span { display: block; }
    .app-title strong { color: #172554; font-size: clamp(.9rem, 1.45vw, 1.1rem); line-height: 1.3; }
    .app-title div > span { color: #64748b; font-size: .8rem; margin-top: .08rem; }
    .app-user { display: flex; align-items: center; gap: .65rem; padding: .35rem .6rem .35rem .4rem; border: 1px solid #e2e8f0; border-radius: .75rem; background: #f8fafc; white-space: nowrap; }
    .app-user-area { display:flex; align-items:center; gap:.55rem; }
    .app-logout-button { display:inline-flex; align-items:center; justify-content:center; min-height:38px; padding:.45rem .7rem; border-radius:.65rem; background:#fff1f2; border:1px solid #fecdd3; color:#be123c; font-size:.78rem; font-weight:700; text-decoration:none; white-space:nowrap; }
    .app-logout-button:hover { background:#ffe4e6; color:#9f1239; }
    .app-user-avatar { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: #dbeafe; color: #1d4ed8; font-weight: 800; }
    .app-user-label, .app-user strong { display: block; line-height: 1.2; }
    .app-user-label { color: #475569; font-size: .74rem; font-weight: 700; }
    .app-user strong { color: #1e293b; font-size: .85rem; max-width: 180px; overflow: hidden; text-overflow: ellipsis; }
}

/* iPad portrait keeps a compact sidebar, leaving the content readable. */
@media (min-width: 769px) and (max-width: 1100px) {
    :root { --sidebar-width: 224px; --sidebar-collapsed-width: 68px; }
    .header-nav { padding-inline: .55rem; }
    .nav-brand { font-size: 1rem; }
    .header-nav a, .dropdown-trigger { padding: .58rem .62rem; font-size: .9rem; }
}

/* Phone: restore a compact top bar with a touch-friendly slide-out menu. */
@media (max-width: 768px) {
    body:has(.header-nav) { padding-left: 0; }
    .header-nav {
        position: sticky;
        inset: auto;
        width: 100%;
        min-height: auto;
        padding: .65rem 1rem;
        flex-direction: row;
        align-items: center;
        background: linear-gradient(115deg, #102a66, #1d4ed8);
    }
    .nav-brand { margin: 0; font-size: 1rem; }
    .nav-logo { height: 30px; }
    .menu-toggle { display: block; margin-left: auto; font-size: 0; }
    .menu-toggle::after { content: '☰'; font-size: 1.35rem; }
    .nav-links { margin-top: .8rem; }
    .header-nav a, .dropdown-trigger { min-height: 44px; display: flex; align-items: center; }
    .header-nav .dropdown-content {
        display: none;
        position: static;
        width: 100%;
        margin-top: .35rem;
        padding: .35rem;
        box-shadow: none;
        background: rgba(7, 21, 55, 0.35);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: .55rem;
        transform: none;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }
    .header-nav .dropdown.is-expanded > .dropdown-content {
        display: flex;
        flex-direction: column;
        gap: .2rem;
    }
    .header-nav .dropdown-trigger .dropdown-arrow {
        transform: rotate(90deg);
        transition: transform .2s ease;
    }
    .header-nav .dropdown.is-expanded > .dropdown-trigger .dropdown-arrow {
        transform: rotate(-90deg);
    }
    .dropdown-content a { min-height: 42px; }
    .container { padding: 1rem 14px; }
    .app-topbar { position: relative; min-height: 0; padding: .75rem 1rem; gap: .65rem; }
    .app-title-mark { display: none; }
    .app-title strong { font-size: .82rem; }
    .app-title div > span { font-size: .7rem; }
    .app-user { padding: .25rem; border: 0; background: transparent; }
    .app-user > div { display: none; }
    .app-user-avatar { width: 32px; height: 32px; }
    .app-user-area { gap:.35rem; }
    .app-logout-button { min-height:32px; padding:.3rem .5rem; font-size:.7rem; }
}

