.primary-nav { gap: 22px; }
.primary-nav > .admin-login-link:not(.nav-cta) { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; width: 44px; min-height: 51px; padding: 0; border: 0; border-radius: 50%; color: #2446ac; background: transparent; box-shadow: none; transition: color .2s, transform .2s; flex-shrink: 0; }
.primary-nav > .admin-login-link:hover { color: #173584; transform: translateY(-2px); }
.admin-login-link img, .profile-avatar img { display: block; width: 36px; height: 36px; filter: drop-shadow(0 3px 2px #0c1c4833); }
.profile-menu { position: relative; font-size: 12px; }
.profile-menu summary { display: flex; flex-direction: column; align-items: center; gap: 2px; width: 90px; cursor: pointer; list-style: none; font-weight: 700; }
.profile-menu summary::-webkit-details-marker { display: none; }
.profile-avatar { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; color: #2446ac; background: transparent; }
.profile-menu summary:hover .profile-avatar img { filter: drop-shadow(0 4px 3px #2446ac50); }
.profile-name { display: block; width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: center; color: #2446ac; font-size: 10px; line-height: 1.3; }
.profile-dropdown { position: absolute; top: calc(100% + 12px); right: 0; width: 240px; padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: 0 20px 55px #0c1c4833; }
.profile-dropdown strong, .profile-dropdown small, .profile-dropdown a { display: block; overflow-wrap: anywhere; }
.profile-dropdown small { margin: 3px 0 16px; color: var(--muted); }
.profile-dropdown a { padding: 10px 0; color: var(--purple); font-weight: 700; }
.profile-dropdown button { padding: 10px 0; border: 0; background: transparent; color: #a52c3e; cursor: pointer; }
.admin-shell { position: relative; padding: 65px 0 90px; background: radial-gradient(ellipse at 0 0, #2847a620, transparent 65%), #edf2fc; }
.login-layout { display: grid; grid-template-columns: 1.1fr 1fr; gap: 65px; align-items: center; }
.login-story h1 { margin: 15px 0 25px; font-size: clamp(36px, 4vw, 56px); line-height: 1.15; letter-spacing: -2px; }
.login-story h1 span { color: var(--purple); }
.login-story > p { max-width: 470px; color: var(--muted); }
.login-orbit { display: flex; align-items: center; gap: 22px; margin-top: 32px; perspective: 600px; }
.login-orbit strong { display: grid; place-items: center; width: 100px; height: 85px; border-radius: 24px; background: white; box-shadow: 0 20px 35px #2446ac30; transform: rotateY(-18deg) rotateZ(-8deg); }
.login-orbit img { width: 80px; height: auto; }
.login-orbit > span { padding: 9px 14px; border-radius: 20px; border: 1px solid var(--line); background: #fff; color: var(--purple); font-weight: 700; font-size: 12px; }
.login-card { padding: 40px; box-shadow: 0 25px 60px #0c1c4815; }
.login-card h2 { margin: 10px 0 8px; font-size: 32px; }
.login-card > p { color: var(--muted); }
.login-card label { font-size: 13px; }
.login-card input { height: 48px; font-size: 14px; }
.login-card .button { width: 100%; }
.login-card .admin-help { margin: 20px 0 0; font-size: 12px; }
.login-shell { padding: 130px 0 150px; overflow: hidden; background: #0c1c48; color: #e9edf2; }
.login-shell .login-layout { position: relative; z-index: 1; }
.login-wave { position: absolute; left: 0; width: 100%; height: 110px; pointer-events: none; }
.login-wave-top { top: -1px; }
.login-wave-bottom { bottom: -1px; height: 130px; }
.login-shell .login-story .eyebrow { color: #e9edf2; }
.login-shell .login-story h1 span { color: #e9edf2; }
.login-shell .login-story > p { color: #e9edf2; }
.login-shell .login-orbit > span, .login-shell .login-orbit strong { color: #0c1c48; border-color: #e9edf2; background: #e9edf2; box-shadow: 0 18px 35px #00000030; }
.login-shell .login-card { position: relative; overflow: hidden; padding-top: 54px; border: 1px solid #e9edf2; border-radius: 26px; color: #0c1c48; background: #e9edf2; box-shadow: 0 24px 60px #00000040; }
.login-shell .login-card::before { content: ""; position: absolute; top: -1px; left: 0; width: 100%; height: 25px; background: #173584; clip-path: polygon(0 0,100% 0,100% 45%,90% 70%,80% 88%,70% 95%,60% 86%,50% 65%,40% 45%,30% 38%,20% 50%,10% 75%,0 95%); }
.login-shell .login-card :is(h2, label, .eyebrow), .login-shell .login-card > p { color: #0c1c48; }
.login-shell .login-card input { background: #e9edf2; color: #0c1c48; border-color: #173584; }
.login-shell .login-card input:focus { border-color: #0c1c48; box-shadow: 0 0 0 3px #17358430; }
.login-shell .login-card .button-primary { color: #e9edf2; background: #173584; box-shadow: 0 8px 20px #0c1c4826; }
.login-shell .login-card .button-primary:hover { background: #0c1c48; }
.login-shell .alert-error { background: #0c1c48; color: #e9edf2; border-left: 4px solid #173584; font-size: 12px; }
@media (max-width: 640px) {
    .admin-shell.login-shell { padding: 95px 0 110px; }
    .login-wave { height: 70px; }
    .login-wave-bottom { height: 85px; }
    .login-shell .login-card { padding-top: 45px; }
}
.dashboard-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.dashboard-heading h1 { margin: 8px 0; font-size: clamp(28px, 4vw, 42px); overflow-wrap: anywhere; letter-spacing: -1.2px; }
.dashboard-heading p { margin: 0; color: var(--muted); }
.dashboard-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.metric-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.metric-card { position: relative; display: flex; flex-direction: column; padding: 25px; border: 1px solid #4968bc; border-radius: 20px; color: #fff; background: linear-gradient(145deg, #2446ac, #102858); box-shadow: 0 15px 30px #0c1c4818; }
.metric-card > span:not(.metric-icon) { margin-top: 20px; font-size: 13px; }
.metric-card strong { margin: 8px 0; font: 800 36px/1.2 var(--heading); overflow-wrap: anywhere; }
.metric-card small { color: #d1dcff; font-size: 11px; }
.metric-icon { width: 38px; padding: 6px; border: 1px solid #ffffff44; border-radius: 10px; background: #ffffff15; text-align: center; font-size: 12px; }
.metrics-note { margin: 18px 0 26px; color: var(--muted); font-size: 12px; }
.insights-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; margin-bottom: 26px; }
.dashboard-panel { min-width: 0; padding: 28px; border: 1px solid var(--line); border-radius: 22px; background: #fff; box-shadow: 0 10px 32px #0c1c4808; }
.dashboard-panel h2 { margin: 6px 0 20px; font-size: 23px; letter-spacing: -.6px; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.status-pill, .count-badge { padding: 6px 10px; border-radius: 18px; background: #eaf0ff; color: var(--purple); font-size: 11px; white-space: nowrap; }
.count-badge { vertical-align: middle; }
.activity-chart { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 12px; margin-top: 18px; }
.chart-column { display: flex; flex-direction: column; align-items: center; font-size: 12px; }
.chart-track { display: flex; align-items: end; width: 100%; height: 130px; margin: 8px 0; border-radius: 8px; background: #eff3fc; overflow: hidden; }
.chart-track span { display: block; width: 100%; border-radius: 8px; background: linear-gradient(#668aee, #2446ac); }
.chart-column small { color: var(--muted); font-size: 10px; }
.top-page { display: grid; grid-template-columns: 1fr auto; gap: 4px; margin-bottom: 14px; font-size: 13px; }
.top-page meter { grid-column: 1 / -1; width: 100%; height: 10px; }
.dashboard-search { display: flex; gap: 12px; align-items: center; margin-bottom: 25px; }
.dashboard-search input { flex: 1; min-width: 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); background: #f7f9ff; }
.enquiry-list { display: grid; gap: 16px; }
.enquiry-item { padding: 22px; border: 1px solid var(--line); border-radius: 16px; background: #f9fbff; }
.enquiry-summary { display: flex; justify-content: space-between; align-items: start; gap: 16px; }
.enquiry-summary h3 { margin: 0 0 3px; font-size: 17px; overflow-wrap: anywhere; }
.enquiry-email { color: var(--purple); font-size: 13px; overflow-wrap: anywhere; }
.enquiry-summary time { color: var(--muted); font-size: 11px; white-space: nowrap; }
.enquiry-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 14px 0; }
.enquiry-tags span { padding: 4px 10px; border-radius: 16px; background: #e6ecfa; color: #244078; font-size: 11px; overflow-wrap: anywhere; }
.enquiry-tags small { color: var(--muted); }
.enquiry-message summary, .delete-confirmation summary { width: fit-content; cursor: pointer; font-weight: 700; font-size: 12px; padding: 5px 0; }
.enquiry-message p { margin: 12px 0; padding: 16px; border-radius: 10px; background: #fff; border: 1px solid var(--line); white-space: pre-wrap; overflow-wrap: anywhere; font-size: 13px; }
.delete-confirmation { margin-top: 12px; color: #a52c3e; }
.delete-confirmation > div { margin-top: 8px; padding: 16px; border: 1px solid #edc3ca; border-radius: 12px; background: #fff1f3; }
.delete-confirmation p { margin-bottom: 12px; font-size: 12px; }
.delete-button { padding: 10px 14px; border: 0; border-radius: 8px; color: white; background: #a52c3e; cursor: pointer; font-weight: 700; font-size: 12px; }
.delete-confirmation small { display: block; margin-top: 10px; }
.dashboard-pagination { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: center; margin-top: 25px; font-size: 12px; }
.empty-inbox { padding: 40px 20px; border: 1px dashed var(--line); border-radius: 16px; text-align: center; color: var(--muted); }
.empty-inbox p { margin: 10px 0 0; font-size: 13px; }
.analytics-notice { color: #f7d5a1; padding-bottom: 16px; font-size: 12px; }
:is(.admin-login-link, .profile-menu summary, .profile-dropdown button, .delete-button, .enquiry-message summary, .delete-confirmation summary):focus-visible { outline: 3px solid #739bfa; outline-offset: 4px; }
@media (max-width: 1000px) and (min-width: 641px) {
    .primary-nav { gap: 12px; }
    .primary-nav .nav-cta { padding: 10px; }
    .profile-menu summary { width: 70px; }
}
@media (max-width: 900px) {
    .metric-grid { grid-template-columns: repeat(2, 1fr); }
    .login-layout { gap: 30px; }
    .login-card { padding: 26px; }
}
@media (max-width: 640px) {
    .admin-shell { padding: 36px 0 55px; }
    .primary-nav .admin-login-link { margin-top: 10px; align-self: center; }
    .profile-menu { margin: 16px 0 0; }
    .profile-dropdown { position: static; width: 100%; margin-top: 16px; box-shadow: none; }
    .login-layout, .insights-grid { grid-template-columns: 1fr; }
    .login-orbit { display: none; }
    .login-story h1 { font-size: 36px; }
    .dashboard-heading { flex-direction: column; align-items: start; }
    .metric-grid { gap: 12px; }
    .metric-card { padding: 16px; }
    .metric-card strong { font-size: 30px; }
    .dashboard-panel { padding: 18px; }
    .dashboard-search { flex-wrap: wrap; }
    .dashboard-search input { flex-basis: 100%; }
    .enquiry-summary { flex-direction: column; gap: 8px; }
    .enquiry-item { padding: 16px; }
    .activity-chart { gap: 6px; }
    .panel-heading { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
    .primary-nav .admin-login-link { transition: none; }
    .primary-nav .admin-login-link:hover { transform: none; }
}
