:root {
    --vcs-navy: #0b1f3b;
    --vcs-navy-light: #173a68;
    --vcs-gold: #d4af37;
    --vcs-burgundy: #7a0019;
    --vcs-white: #ffffff;
    --vcs-text: #172033;
    --vcs-muted: #596579;
    --vcs-shadow: 0 18px 45px rgba(0, 0, 0, 0.24);
}

* { box-sizing: border-box; }

html { min-height: 100%; }

body {
    min-height: 100vh;
    margin: 0;
    color: var(--vcs-text);
    font-family: Arial, Helvetica, sans-serif;
    background: linear-gradient(145deg, rgba(11,31,59,.96), rgba(23,58,104,.90)),
                url('/images/BlueBackground.jpg') center/cover fixed;
}

a { color: inherit; }

.page-shell {
    width: min(1100px, calc(100% - 32px));
    margin: 0 auto;
    padding: 32px 0;
}

.auth-shell {
    width: min(520px, calc(100% - 32px));
    margin: 0 auto;
    padding: 42px 0;
}

.brand {
    margin-bottom: 20px;
    color: var(--vcs-white);
    text-align: center;
}

.brand-logo {
    display: block;
    width: 142px;
    height: 142px;
    margin: 0 auto 14px;
    object-fit: contain;
}

.brand h1 {
    margin: 0;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: clamp(30px, 6vw, 44px);
    line-height: 1.1;
}

.brand p {
    margin: 8px 0 0;
    color: var(--vcs-gold);
    font-size: 18px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.card {
    padding: clamp(24px, 5vw, 40px);
    border: 1px solid rgba(212,175,55,.55);
    border-radius: 18px;
    background: var(--vcs-white);
    box-shadow: var(--vcs-shadow);
}

.card h2 { margin: 0 0 8px; color: var(--vcs-navy); font-size: 28px; }
.card-intro { margin: 0 0 24px; color: var(--vcs-muted); line-height: 1.55; }

.field { margin-bottom: 20px; }
.field label { display: block; margin-bottom: 7px; color: var(--vcs-navy); font-weight: 700; }
.field input {
    width: 100%;
    min-height: 52px;
    padding: 11px 14px;
    border: 2px solid #c7ced8;
    border-radius: 9px;
    background: #fff;
    color: var(--vcs-text);
    font-size: 18px;
}
.field input:focus { border-color: var(--vcs-gold); outline: 3px solid rgba(212,175,55,.25); }

.password-row { position: relative; }
.password-row input { padding-right: 78px; }
.show-password {
    position: absolute;
    top: 7px;
    right: 7px;
    min-height: 38px;
    border: 0;
    border-radius: 6px;
    background: #e9edf3;
    color: var(--vcs-navy);
    cursor: pointer;
    font-weight: 700;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 54px;
    padding: 12px 22px;
    border: 2px solid var(--vcs-gold);
    border-radius: 999px;
    background: var(--vcs-gold);
    color: var(--vcs-burgundy);
    cursor: pointer;
    font-size: 18px;
    font-weight: 800;
    text-decoration: none;
}
.button:hover { filter: brightness(1.06); transform: translateY(-1px); }
.button:focus-visible, .portal-link:focus-visible, .text-button:focus-visible {
    outline: 4px solid rgba(212,175,55,.5);
    outline-offset: 3px;
}

.alert {
    margin: 0 0 20px;
    padding: 13px 15px;
    border-left: 5px solid var(--vcs-burgundy);
    border-radius: 6px;
    background: #fff1f3;
    color: #620014;
    line-height: 1.45;
}

.privacy-note { margin: 20px 0 0; color: var(--vcs-muted); font-size: 14px; line-height: 1.45; text-align: center; }

.portal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 26px;
    color: var(--vcs-white);
}
.portal-identity { display: flex; align-items: center; gap: 16px; }
.portal-identity .brand-logo { width: 80px; height: 80px; margin: 0; }
.portal-identity h1 { margin: 0; font-family: Georgia, 'Times New Roman', serif; font-size: 30px; }
.portal-identity p { margin: 4px 0 0; color: var(--vcs-gold); }
.logout-form { margin: 0; }
.text-button {
    padding: 10px 18px;
    border: 1px solid rgba(255,255,255,.65);
    border-radius: 999px;
    background: rgba(255,255,255,.08);
    color: #fff;
    cursor: pointer;
    font-size: 16px;
}

.welcome-card { margin-bottom: 22px; padding: 24px 28px; }
.welcome-card h2 { margin-bottom: 5px; }
.welcome-card p { margin: 0; color: var(--vcs-muted); }

.portal-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}
.portal-link {
    display: block;
    min-height: 160px;
    padding: 25px;
    border: 2px solid transparent;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(0,0,0,.18);
    text-decoration: none;
}
.portal-link:hover { border-color: var(--vcs-gold); transform: translateY(-2px); }
.portal-icon { display: block; margin-bottom: 14px; color: var(--vcs-gold); font-size: 32px; }
.portal-link strong { display: block; margin-bottom: 7px; color: var(--vcs-navy); font-size: 22px; }
.portal-link span:last-child { color: var(--vcs-muted); line-height: 1.45; }

.site-footer { padding: 24px 0 6px; color: rgba(255,255,255,.82); font-size: 14px; text-align: center; }

@media (max-width: 700px) {
    .auth-shell { padding-top: 24px; }
    .portal-header { align-items: flex-start; }
    .portal-identity .brand-logo { width: 62px; height: 62px; }
    .portal-identity h1 { font-size: 23px; }
    .portal-grid { grid-template-columns: 1fr; }
}

@media (max-width: 460px) {
    .page-shell { width: min(100% - 22px, 1100px); padding-top: 18px; }
    .portal-header { display: block; }
    .logout-form { margin-top: 15px; }
    .text-button { width: 100%; }
}

@media (prefers-reduced-motion: no-preference) {
    .button, .portal-link { transition: transform .18s ease, border-color .18s ease, filter .18s ease; }
}
