/* ═══════════════════════════════════════════════════════════════════
   SRMC Online Admission Portal — public stylesheet (self-contained)
   ═══════════════════════════════════════════════════════════════════ */

:root {
    --brand: #1a3a6b;
    --brand-dark: #142d54;
    --accent: #0e7490;          /* overridden per-program inline */
    --accent-dark: #0b5a70;
    --ink: #1e293b;
    --muted: #64748b;
    --line: #e2e8f0;
    --bg: #f1f5f9;
    --card: #ffffff;
    --gold: #f5a623;
    --radius: 14px;
    --shadow: 0 4px 20px rgba(15, 23, 42, 0.06);
    --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.12);
    --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: var(--font);
    color: var(--ink);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }

.container { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.text-center { text-align: center; }

/* ── Top bar ── */
.topbar {
    background: var(--brand-dark);
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.82rem;
}
.topbar .container { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 8px; padding-bottom: 8px; flex-wrap: wrap; }
.topbar a { color: var(--gold); }
.topbar .tb-links { display: flex; gap: 18px; flex-wrap: wrap; }
.topbar .tb-links span, .topbar .tb-links a { display: inline-flex; align-items: center; gap: 6px; }

/* ── Navbar ── */
.navbar {
    background: #fff;
    box-shadow: 0 1px 0 var(--line);
    position: sticky; top: 0; z-index: 50;
}
.navbar .container { display: flex; align-items: center; justify-content: space-between; padding-top: 12px; padding-bottom: 12px; gap: 16px; }
.brand-row { display: flex; align-items: center; gap: 14px; }
.brand-row img { width: 52px; height: 52px; object-fit: contain; }
.brand-text b { display: block; color: var(--brand); font-size: 1.05rem; line-height: 1.15; }
.brand-text small { color: var(--muted); font-size: 0.76rem; letter-spacing: 0.3px; }
.nav-links { display: flex; align-items: center; gap: 8px; }
.nav-links a { color: var(--ink); font-weight: 500; font-size: 0.92rem; padding: 8px 12px; border-radius: 8px; }
.nav-links a:hover { background: var(--bg); text-decoration: none; }
.nav-links a.nav-cta { background: var(--brand); color: #fff; }
.nav-links a.nav-cta:hover { background: var(--brand-dark); }

/* ── Buttons ── */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 26px; border-radius: 10px; border: none; cursor: pointer;
    font-family: inherit; font-size: 0.95rem; font-weight: 600; text-decoration: none;
    transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease, background 0.2s ease;
    white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.btn:active { transform: translateY(0); box-shadow: none; }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { filter: brightness(1.08); color: #fff; }
.btn-brand { background: var(--brand); color: #fff; }
.btn-brand:hover { background: var(--brand-dark); color: #fff; }
.btn-light { background: #fff; color: var(--accent); border: 1.5px solid var(--line); }
.btn-block { width: 100%; }
.btn-lg { padding: 15px 32px; font-size: 1.02rem; }

/* ── Hero ── */
.hero {
    background: linear-gradient(135deg, var(--brand-dark) 0%, var(--brand) 60%, #1e4a8a 100%);
    color: #fff; padding: 64px 0 72px; position: relative; overflow: hidden;
}
.hero::before, .hero::after { content: ''; position: absolute; border-radius: 50%; background: rgba(255, 255, 255, 0.05); }
.hero::before { width: 320px; height: 320px; top: -100px; right: -80px; }
.hero::after { width: 220px; height: 220px; bottom: -90px; left: -60px; }
.hero-inner { position: relative; z-index: 1; max-width: 720px; }
.hero .badge {
    display: inline-block; background: rgba(255, 255, 255, 0.12); border: 1px solid rgba(255, 255, 255, 0.22);
    color: #fff; font-size: 0.74rem; font-weight: 700; letter-spacing: 1.4px; text-transform: uppercase;
    padding: 6px 16px; border-radius: 20px; margin-bottom: 18px;
}
.hero h1 { font-size: 2.5rem; font-weight: 800; line-height: 1.15; margin-bottom: 14px; }
.hero h1 span { color: var(--gold); }
.hero p { font-size: 1.08rem; color: rgba(255, 255, 255, 0.82); margin-bottom: 26px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ── Section ── */
.section { padding: 60px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 44px; }
.section-head h2 { font-size: 1.9rem; color: var(--ink); font-weight: 800; margin-bottom: 10px; }
.section-head p { color: var(--muted); font-size: 1.02rem; }
.section-head .rule { width: 64px; height: 4px; background: var(--gold); border-radius: 4px; margin: 14px auto 0; }

/* ── Program cards ── */
.program-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 24px; }
.program-card {
    background: var(--card); border-radius: var(--radius); border: 1px solid var(--line);
    box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.program-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.pc-top { padding: 26px 24px 20px; color: #fff; position: relative; }
.pc-icon { width: 56px; height: 56px; border-radius: 14px; background: rgba(255, 255, 255, 0.18); display: flex; align-items: center; justify-content: center; font-size: 1.5rem; margin-bottom: 14px; }
.pc-top h3 { font-size: 1.35rem; font-weight: 800; }
.pc-top small { opacity: 0.85; font-size: 0.85rem; }
.pc-body { padding: 20px 24px 24px; flex: 1; display: flex; flex-direction: column; }
.pc-meta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 14px; }
.pc-meta span { font-size: 0.8rem; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.pc-body p.desc { color: var(--muted); font-size: 0.92rem; margin-bottom: 18px; flex: 1; }
.pc-status { font-size: 0.78rem; font-weight: 700; padding: 4px 12px; border-radius: 20px; display: inline-block; margin-bottom: 16px; }
.pc-open { background: #dcfce7; color: #15803d; }
.pc-closed { background: #fee2e2; color: #b91c1c; }
.pc-soon { background: #fef3c7; color: #b45309; }

/* ── Steps / how it works ── */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 22px; }
.step { background: var(--card); border-radius: var(--radius); padding: 28px 24px; box-shadow: var(--shadow); border: 1px solid var(--line); text-align: center; }
.step .num { width: 46px; height: 46px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center; margin: 0 auto 14px; }
.step h4 { font-size: 1.05rem; margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 0.9rem; }

/* ── Page header (inner pages) ── */
.page-head { background: linear-gradient(135deg, var(--accent-dark), var(--accent)); color: #fff; padding: 40px 0; }
.page-head .badge { display: inline-block; background: rgba(255,255,255,0.15); border: 1px solid rgba(255,255,255,0.25); padding: 5px 14px; border-radius: 20px; font-size: 0.75rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 12px; }
.page-head h1 { font-size: 2rem; font-weight: 800; }
.page-head p { color: rgba(255,255,255,0.85); margin-top: 6px; }
.crumbs { margin-top: 12px; font-size: 0.85rem; color: rgba(255,255,255,0.8); }
.crumbs a { color: #fff; }

/* ── Cards / panels ── */
.panel { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid var(--line); }
.panel-pad { padding: 28px; }

/* ── Eligibility list ── */
.elig-list { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.elig-list li { display: flex; gap: 12px; align-items: flex-start; color: #475569; font-size: 0.95rem; }
.elig-list li i { color: var(--accent); margin-top: 4px; flex-shrink: 0; }

/* ── Forms ── */
.form-section { margin-bottom: 28px; }
.form-section-title { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; padding-bottom: 12px; border-bottom: 2px solid var(--line); }
.form-section-title .fs-num { width: 30px; height: 30px; border-radius: 8px; background: var(--accent); color: #fff; font-weight: 800; font-size: 0.85rem; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.form-section-title h3 { font-size: 1.1rem; color: var(--ink); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 4px; }
.field.col-span-2 { grid-column: 1 / -1; }
.field label { font-size: 0.82rem; font-weight: 600; color: #475569; }
.field label .req { color: #dc2626; }
.field input, .field select, .field textarea {
    width: 100%; padding: 11px 14px; border: 1.5px solid var(--line); border-radius: 9px;
    font-size: 0.94rem; font-family: inherit; color: var(--ink); background: #f8fafc;
    outline: none; transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.field textarea { resize: vertical; min-height: 76px; }
.field input:focus, .field select:focus, .field textarea:focus {
    border-color: var(--accent); background: #fff; box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 15%, transparent);
}
.field .hint { font-size: 0.76rem; color: var(--muted); }
.field input[type="file"] { padding: 8px; background: #fff; cursor: pointer; }

/* ── Alerts ── */
.alert { border-radius: 10px; padding: 14px 18px; font-size: 0.92rem; margin-bottom: 20px; display: flex; gap: 10px; align-items: flex-start; }
.alert i { margin-top: 3px; flex-shrink: 0; }
.alert-success { background: #dcfce7; border: 1px solid #86efac; color: #15803d; }
.alert-error { background: #fee2e2; border: 1px solid #fca5a5; color: #b91c1c; }
.alert-info { background: #dbeafe; border: 1px solid #93c5fd; color: #1e40af; }
.alert-warn { background: #fef3c7; border: 1px solid #fcd34d; color: #b45309; }
.alert ul { margin: 4px 0 0 18px; }

/* ── Status badge ── */
.status-badge { display: inline-flex; align-items: center; gap: 7px; padding: 6px 16px; border-radius: 22px; font-weight: 700; font-size: 0.85rem; color: #fff; }

/* ── Reference box (success page) ── */
.ref-box { background: linear-gradient(135deg, var(--accent-dark), var(--accent)); color: #fff; border-radius: var(--radius); padding: 32px; text-align: center; }
.ref-box small { text-transform: uppercase; letter-spacing: 2px; font-size: 0.76rem; opacity: 0.85; }
.ref-box .ref-no { font-size: 2rem; font-weight: 800; letter-spacing: 2px; margin: 8px 0; font-family: 'Courier New', monospace; }

/* ── Footer ── */
.footer { background: var(--brand-dark); color: rgba(255, 255, 255, 0.72); padding: 40px 0 24px; margin-top: 60px; }
.footer .cols { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; margin-bottom: 28px; }
.footer h5 { color: #fff; font-size: 1rem; margin-bottom: 12px; }
.footer a { color: rgba(255, 255, 255, 0.72); }
.footer a:hover { color: var(--gold); }
.footer ul { list-style: none; display: flex; flex-direction: column; gap: 8px; font-size: 0.9rem; }
.footer .fbar { border-top: 1px solid rgba(255, 255, 255, 0.12); padding-top: 18px; text-align: center; font-size: 0.84rem; }

/* ── Utility ── */
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 12px; } .mt-2 { margin-top: 24px; }
.mb-1 { margin-bottom: 12px; } .mb-2 { margin-bottom: 24px; }
.muted { color: var(--muted); }
.divider { border: none; border-top: 1px solid var(--line); margin: 24px 0; }

/* ── Responsive ── */
@media (max-width: 780px) {
    .hero h1 { font-size: 1.9rem; }
    .grid-2, .grid-3 { grid-template-columns: 1fr; }
    .footer .cols { grid-template-columns: 1fr; }
    .nav-links .nav-hide { display: none; }
    .topbar { display: none; }
    /* 16px inputs stop iOS Safari from zooming in when a field is focused */
    .field input, .field select, .field textarea { font-size: 16px; }
    .brand-text b { font-size: 0.95rem; }
    .brand-row img { width: 44px; height: 44px; }
    .page-head h1 { font-size: 1.5rem; }
    .section { padding: 40px 0; }
}
