@import url('/assets/fonts/fonts.css?v=1');

:root {
    --rs-green-deep: #06402a;
    --rs-green-deep-rgb: 6, 64, 42;
    --rs-green-rgb: 13, 122, 74;
    --rs-green-mid-rgb: 34, 184, 106;
    --rs-green: #0d7a4a;
    --rs-green-mid: #22b86a;
    --rs-gold: #fbc217;
    --rs-ink: #1a2332;
    --rs-muted: #6b7280;
}

html { scroll-behavior: smooth; }

body.auth-body,
body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Poppins', system-ui, -apple-system, sans-serif;
    color: #fff;
    background: linear-gradient(170deg, var(--rs-green-mid) 0%, var(--rs-green) 45%, var(--rs-green-deep) 100%);
    -webkit-font-smoothing: antialiased;
}

.rs-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 2rem 1.5rem;
}

.rs-shell::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(255, 255, 255, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, rgba(var(--rs-green-mid-rgb), 0.35) 0%, transparent 45%),
        radial-gradient(ellipse at 50% 50%, rgba(251, 194, 23, 0.10) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
}

.rs-shell::after {
    content: '';
    position: fixed;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 194, 23, 0.10) 0%, transparent 70%);
    top: -200px;
    right: -200px;
    pointer-events: none;
    z-index: 0;
    animation: rs-float 12s ease-in-out infinite alternate;
}

@keyframes rs-float {
    0% { transform: translate(0, 0) scale(1); opacity: 0.5; }
    100% { transform: translate(-40px, 60px) scale(1.15); opacity: 0.8; }
}

.rs-content {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 820px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.rs-logo-wrap { margin-bottom: 1rem; animation: rs-fadeDown 0.6s ease-out; }

.rs-logo {
    width: 90px;
    height: 90px;
    object-fit: contain;
    /* White stroke that follows the logo shape instead of a white square behind it. */
    filter: drop-shadow(1.5px 0 0 #fff) drop-shadow(-1.5px 0 0 #fff) drop-shadow(0 1.5px 0 #fff) drop-shadow(0 -1.5px 0 #fff);
}

.rs-title {
    font-size: 2.8rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    margin: 0 0 0.4rem;
    text-shadow: 0 4px 20px rgba(0,0,0,0.2);
    animation: rs-fadeDown 0.6s ease-out 0.1s both;
}

.rs-subtitle {
    font-size: 0.82rem;
    font-weight: 600;
    color: rgba(255,255,255,0.7);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin: 0 0 2.5rem;
    animation: rs-fadeDown 0.6s ease-out 0.2s both;
}

.rs-label {
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--rs-gold);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 1.35rem;
    animation: rs-fadeUp 0.5s ease-out 0.3s both;
}

.rs-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 1rem;
    width: 100%;
    animation: rs-fadeUp 0.5s ease-out 0.4s both;
}

.rs-card {
    grid-column: span 2;
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 1.25rem 1.15rem;
    border-radius: 14px;
    background: #fff;
    border: 1px solid rgba(0,0,0,0.04);
    text-decoration: none;
    color: var(--rs-ink);
    box-shadow: 0 4px 16px rgba(0,0,0,0.08), 0 1px 3px rgba(0,0,0,0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    cursor: pointer;
    text-align: left;
}

.rs-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 14px 36px rgba(var(--rs-green-deep-rgb), 0.22), 0 4px 12px rgba(0,0,0,0.08);
    border-color: rgba(251, 194, 23, 0.45);
    color: var(--rs-ink);
    text-decoration: none;
}

/* Role icon tile. Each role sets --ic (accent) and --ic-rgb; on card hover
   the tile fills with the accent and the icon turns white. */
.rs-icon {
    --ic: var(--rs-green);
    --ic-rgb: var(--rs-green-rgb);
    flex-shrink: 0;
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--ic);
    background: linear-gradient(145deg, rgba(var(--ic-rgb), 0.08), rgba(var(--ic-rgb), 0.16));
    box-shadow: inset 0 0 0 1px rgba(var(--ic-rgb), 0.2);
    transition: color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.rs-icon svg { width: 24px; height: 24px; stroke-width: 1.75; }

.rs-card:hover .rs-icon,
.rs-card:focus-visible .rs-icon {
    color: #fff;
    background: var(--ic);
    box-shadow: 0 8px 18px rgba(var(--ic-rgb), 0.32);
    transform: scale(1.05);
}

.rs-icon--president       { --ic: #b77f00; --ic-rgb: 214, 149, 0; }
.rs-icon--vp              { --ic: var(--rs-green); --ic-rgb: var(--rs-green-rgb); }
.rs-icon--board-secretary { --ic: #0f8a6b; --ic-rgb: 15, 138, 107; }
.rs-icon--proponent       { --ic: #15803d; --ic-rgb: 21, 128, 61; }
.rs-icon--legal           { --ic: #6d28d9; --ic-rgb: 109, 40, 217; }
.rs-icon--accounting      { --ic: #1d4ed8; --ic-rgb: 29, 78, 216; }
.rs-icon--admin           { --ic: var(--rs-green-deep); --ic-rgb: var(--rs-green-deep-rgb); }

.rs-info { min-width: 0; }

.rs-name {
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 0.2rem;
    color: var(--rs-ink);
}

.rs-desc {
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--rs-muted);
    line-height: 1.45;
    margin: 0;
}

.rs-footer {
    position: relative;
    z-index: 1;
    text-align: center;
    margin-top: 2.5rem;
    padding-bottom: 1.25rem;
    font-size: 0.8rem;
    font-weight: 500;
    color: rgba(255,255,255,0.5);
    animation: rs-fadeUp 0.5s ease-out 0.5s both;
}

.rs-admin-secret {
    display: block;
    position: absolute;
    left: 50%;
    top: calc(100% + 0.2rem);
    transform: translateX(-50%);
    width: 8.5rem;
    height: 1.25rem;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
    text-decoration: none;
}

.rs-admin-secret:hover,
.rs-admin-secret:focus,
.rs-admin-secret:focus-visible {
    opacity: 0;
    outline: none;
}

.rs-back {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: rgba(255,255,255,0.75);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.88rem;
    margin-bottom: 1.5rem;
    transition: color 0.2s ease;
    animation: rs-fadeDown 0.5s ease-out;
}

.rs-back:hover { color: #fff; }
.rs-back svg { width: 16px; height: 16px; }

@keyframes rs-fadeDown {
    from { opacity: 0; transform: translateY(-18px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes rs-fadeUp {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: translateY(0); }
}

@media screen and (max-width: 767.98px) {
    .rs-grid { gap: 0.85rem; }
    .rs-title { font-size: 2.2rem; }
    .rs-subtitle { font-size: 0.72rem; }
    .rs-logo { width: 72px; height: 72px; }
    .rs-card { padding: 1rem 0.95rem; }
    .rs-icon { width: 40px; height: 40px; border-radius: 10px; }
    .rs-icon svg { width: 21px; height: 21px; }
    .rs-name { font-size: 0.85rem; }
    .rs-desc { font-size: 0.72rem; }
}

@media screen and (max-width: 479.98px) {
    .rs-grid { grid-template-columns: 1fr; }
    .rs-card { grid-column: auto; }
    .rs-shell { padding: 2rem 1rem; }
    .rs-title { font-size: 1.8rem; }
    .rs-logo { width: 64px; height: 64px; }
}

@media screen and (min-width: 480px) and (max-width: 767.98px) {
    .rs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .rs-card { grid-column: auto; }
}

/* Council / Board of Regents selector */
.rs-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.35rem;
    width: min(100%, 34rem);
    padding: 0.35rem;
    margin-bottom: 1.5rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
    animation: rs-fadeUp 0.5s ease-out 0.35s both;
}

.rs-tab {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    min-width: 0;
    padding: 0.65rem 0.9rem;
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.9);
    text-align: left;
    text-decoration: none;
    transition: color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.rs-tab:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.rs-tab-icon {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.14);
    color: var(--rs-gold);
    transition: color 0.2s ease, background-color 0.2s ease;
}

.rs-tab-icon svg { width: 20px; height: 20px; stroke-width: 1.75; }

.rs-tab-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.rs-tab-text strong {
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.25;
    white-space: nowrap;
}

.rs-tab-text small {
    font-size: 0.7rem;
    font-weight: 500;
    line-height: 1.35;
    opacity: 0.78;
}

.rs-tab.is-active {
    background: #fff;
    color: var(--rs-green-deep);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.16);
}

.rs-tab.is-active .rs-tab-icon {
    background: var(--rs-green);
    color: #fff;
}

.rs-tab.is-active .rs-tab-text small {
    color: var(--rs-muted);
    opacity: 1;
}

/* The Board of Regents set: two cards, centred. */
.rs-grid.rs-grid--bor {
    grid-template-columns: repeat(2, minmax(0, 22rem));
    justify-content: center;
}

.rs-grid--bor .rs-card { grid-column: auto; }

@media screen and (max-width: 575.98px) {
    .rs-grid.rs-grid--bor { grid-template-columns: minmax(0, 22rem); }
}

.rs-icon--regent { --ic: #b77f00; --ic-rgb: 214, 149, 0; }

.rs-icon--regent-finance { --ic: #0f766e; --ic-rgb: 15, 118, 110; }

@media (prefers-reduced-motion: reduce) {
    .rs-card:hover .rs-icon,
    .rs-card:focus-visible .rs-icon { transform: none; }
}

@media screen and (max-width: 479.98px) {
    .rs-tab { gap: 0.5rem; padding: 0.55rem 0.6rem; }
    .rs-tab-icon { width: 32px; height: 32px; border-radius: 8px; }
    .rs-tab-icon svg { width: 17px; height: 17px; }
    .rs-tab-text strong { font-size: 0.8rem; white-space: normal; }
    .rs-tab-text small { display: none; }
}

@media screen and (max-width: 359.98px) {
    .rs-tab-icon { display: none; }
}
