@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    --icf-primary: #0b5345;
    --icf-primary-dark: #07382e;
    --icf-primary-light: #e6f4f1;
    --icf-accent: #f59e0b;
    --icf-accent-dark: #d97706;
    --icf-light: #f8fafc;
    --icf-white: #ffffff;
    --icf-text: #0f172a;
    --icf-text-muted: #475569;
    --icf-border: #e2e8f0;
    --icf-shadow: 0 10px 25px -5px rgba(11, 83, 69, 0.05), 0 8px 10px -6px rgba(11, 83, 69, 0.05);
    --icf-shadow-hover: 0 20px 25px -5px rgba(11, 83, 69, 0.1), 0 10px 10px -6px rgba(11, 83, 69, 0.1);
    --icf-radius: 16px;
    --icf-radius-sm: 12px;
    --icf-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base */
body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--icf-text);
    background: var(--icf-light);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--icf-primary); transition: var(--icf-transition); text-decoration: none; }
a:hover { color: var(--icf-primary-dark); }

::selection {
    background: var(--icf-primary);
    color: #fff;
}

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--icf-light); }
::-webkit-scrollbar-thumb { background: var(--icf-border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--icf-primary); }

/* Buttons */
.btn {
    border-radius: var(--icf-radius-sm);
    font-weight: 600;
    padding: 0.6rem 1.5rem;
    transition: var(--icf-transition);
}
.btn-lg { padding: 0.8rem 2rem; font-size: 1.05rem; }
.btn-sm { padding: 0.4rem 1rem; font-size: 0.88rem; }

.btn-icf {
    background: var(--icf-primary);
    border-color: var(--icf-primary);
    color: #fff;
    box-shadow: 0 4px 14px rgba(11, 83, 69, 0.2);
}
.btn-icf:hover {
    background: var(--icf-primary-dark);
    border-color: var(--icf-primary-dark);
    color: #fff;
    box-shadow: 0 6px 20px rgba(11, 83, 69, 0.3);
    transform: translateY(-2px);
}

.btn-accent {
    background: var(--icf-accent);
    border-color: var(--icf-accent);
    color: #1e293b;
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.2);
}
.btn-accent:hover {
    background: var(--icf-accent-dark);
    border-color: var(--icf-accent-dark);
    color: #1e293b;
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.3);
    transform: translateY(-2px);
}

.btn-outline-secondary {
    border-color: var(--icf-border);
    color: var(--icf-text-muted);
}
.btn-outline-secondary:hover {
    border-color: var(--icf-primary);
    color: var(--icf-primary);
    background: var(--icf-primary-light);
    transform: translateY(-1px);
}

.text-icf { color: var(--icf-primary) !important; }
.bg-icf { background: var(--icf-primary) !important; }
.bg-icf-dark { background: var(--icf-primary-dark) !important; }

/* Navbar */
.navbar-icf {
    background: rgba(11, 83, 69, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px rgba(11, 83, 69, 0.1);
    padding: 0.85rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.navbar-icf .navbar-brand,
.navbar-icf .nav-link { color: #fff !important; }
.navbar-icf .navbar-brand { font-size: 1.4rem; letter-spacing: -0.5px; }
.navbar-icf .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    border-radius: var(--icf-radius-sm);
    margin: 0 3px;
    transition: var(--icf-transition);
}
.navbar-icf .nav-link:hover {
    color: var(--icf-accent) !important;
    background: rgba(255,255,255,0.08);
}
.navbar-icf .nav-link.active {
    color: var(--icf-accent) !important;
    font-weight: 600;
    background: rgba(255,255,255,0.12);
}
.navbar-toggler { border-color: rgba(255,255,255,0.25); }
.navbar-toggler-icon { filter: invert(1); }

/* Hero */
.hero {
    background: linear-gradient(135deg, var(--icf-primary), var(--icf-primary-dark));
    color: #fff;
    padding: 7rem 0 6rem;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.hero h1 {
    font-weight: 800;
    letter-spacing: -1.2px;
    line-height: 1.15;
}
.hero .lead {
    opacity: 0.9;
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
}

/* Cards */
.card {
    border: 1px solid rgba(11, 83, 69, 0.06);
    box-shadow: var(--icf-shadow);
    border-radius: var(--icf-radius);
    background: var(--icf-white);
    transition: var(--icf-transition);
}
.card:hover {
    box-shadow: var(--icf-shadow-hover);
    transform: translateY(-4px);
}

.glass-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.4) !important;
}

.scholarship-card {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
}
.scholarship-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--icf-shadow-hover);
}

.stat-card {
    border-radius: var(--icf-radius);
    color: #fff;
    padding: 1.75rem;
    box-shadow: var(--icf-shadow);
    transition: var(--icf-transition);
    border: none;
}
.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--icf-shadow-hover);
}


/* Sections */
.section { padding: 5rem 0; }
.section-light { background: var(--icf-white); }
.section-alt { background: var(--icf-light); }

/* Footer */
footer.icf-footer {
    background: var(--icf-primary-dark);
    color: #cfe3dd;
    margin-top: 0;
}
footer.icf-footer a { color: #fff; text-decoration: none; transition: var(--icf-transition); }
footer.icf-footer a:hover { color: var(--icf-accent); }
footer.icf-footer h5,
footer.icf-footer h6 { color: #fff; font-weight: 600; }

/* Timeline (application status) */
.timeline { list-style: none; padding-left: 0; }
.timeline li { position: relative; padding: 0 0 1.75rem 2.5rem; border-left: 2px solid #dee2e6; }
.timeline li:last-child { border-left-color: transparent; }
.timeline li .dot {
    position: absolute; left: -10px; top: 2px; width: 18px; height: 18px;
    border-radius: 50%; background: #dee2e6;
    border: 3px solid var(--icf-white);
    box-shadow: 0 0 0 2px #dee2e6;
}
.timeline li.done .dot { background: var(--icf-primary); box-shadow: 0 0 0 2px var(--icf-primary); }
.timeline li.current .dot { background: var(--icf-accent); box-shadow: 0 0 0 4px rgba(245,166,35,.25); }
.timeline li.rejected .dot { background: #dc3545; box-shadow: 0 0 0 2px #dc3545; }

/* Countdown */
.countdown-badge { font-size: .82rem; font-weight: 500; padding: 0.4em 0.7em; border-radius: 6px; }

/* Sidebar */
.app-sidebar {
    background: var(--icf-primary-dark);
    min-height: calc(100vh - 62px);
    color: #cfe3dd;
    padding: 1rem 0.75rem;
}
.app-sidebar a {
    color: #cfe3dd;
    text-decoration: none;
    display: block;
    padding: 0.65rem 1rem;
    border-radius: var(--icf-radius-sm);
    margin-bottom: 4px;
    font-weight: 500;
    transition: var(--icf-transition);
    font-size: 0.92rem;
}
.app-sidebar a:hover, .app-sidebar a.active {
    background: rgba(255,255,255,.12);
    color: #fff;
}
.app-sidebar .sidebar-heading {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    opacity: .55;
    padding: 1.25rem 1rem 0.5rem;
    font-weight: 700;
}

/* Forms */
.form-label {
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--icf-text);
    margin-bottom: 0.4rem;
}
.form-control, .form-select {
    border: 1.5px solid var(--icf-border);
    border-radius: var(--icf-radius-sm);
    padding: 0.6rem 0.9rem;
    font-size: 0.95rem;
    transition: var(--icf-transition);
    background: var(--icf-white);
}
.form-control:focus, .form-select:focus {
    border-color: var(--icf-primary);
    box-shadow: 0 0 0 4px rgba(13, 92, 74, 0.1);
    background: var(--icf-white);
}
.form-control::placeholder { color: #a0b5ad; }

/* Form sections for apply page */
.form-section-card {
    border: none;
    border-radius: var(--icf-radius);
    background: var(--icf-white);
    box-shadow: var(--icf-shadow);
    padding: 1.75rem;
    margin-bottom: 1.5rem;
    transition: var(--icf-transition);
    position: relative;
    overflow: hidden;
}
.form-section-card:hover { box-shadow: var(--icf-shadow-hover); }
.form-section-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background: var(--icf-primary);
    border-radius: var(--icf-radius) 0 0 var(--icf-radius);
}
.form-section-card.section-warning::before { background: var(--icf-accent); }
.form-section-card.section-danger::before { background: #dc3545; }
.form-section-card.section-info::before { background: #0dcaf0; }

.section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--icf-light);
}
.section-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: var(--icf-primary-light);
    color: var(--icf-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}
.section-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--icf-primary-dark);
    margin: 0;
}
.section-badge {
    margin-left: auto;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.35em 0.7em;
    border-radius: 6px;
}

/* Stepper */
.stepper {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2.5rem;
    position: relative;
}
.stepper::before {
    content: '';
    position: absolute;
    top: 18px;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--icf-border);
    z-index: 0;
    border-radius: 2px;
}
.stepper-step {
    position: relative;
    z-index: 1;
    text-align: center;
    flex: 1;
}
.stepper-step .step-circle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--icf-white);
    border: 3px solid var(--icf-border);
    color: var(--icf-text-muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
    transition: var(--icf-transition);
}
.stepper-step.active .step-circle {
    background: var(--icf-primary);
    border-color: var(--icf-primary);
    color: #fff;
    box-shadow: 0 0 0 5px rgba(13,92,74,0.15);
}
.stepper-step.completed .step-circle {
    background: var(--icf-primary);
    border-color: var(--icf-primary);
    color: #fff;
}
.stepper-step .step-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--icf-text-muted);
    display: block;
}
.stepper-step.active .step-label { color: var(--icf-primary); }
.stepper-step.completed .step-label { color: var(--icf-primary); }

/* Document list in apply form */
.doc-preview-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 0.8rem;
    background: var(--icf-light);
    border-radius: var(--icf-radius-sm);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}
.doc-preview-item .doc-icon {
    color: var(--icf-primary);
    font-size: 1.1rem;
}

/* Declaration box */
.declaration-box {
    background: linear-gradient(135deg, #fff9e6, #fff3cd);
    border: 1.5px solid var(--icf-accent);
    border-radius: var(--icf-radius);
    padding: 1.5rem;
}
.declaration-box .form-check-label {
    font-size: 0.92rem;
    line-height: 1.5;
    color: var(--icf-text);
}
.declaration-box .form-check-input:checked {
    background-color: var(--icf-primary);
    border-color: var(--icf-primary);
}

/* Alerts */
.alert {
    border: none;
    border-radius: var(--icf-radius-sm);
    font-size: 0.92rem;
}
.alert-info { background: #e6f4f1; color: var(--icf-primary-dark); }
.alert-warning { background: #fff8e6; color: #856404; }
.alert-danger { background: #fce8e8; color: #842029; }
.alert-success { background: #e8f5e9; color: #1b5e20; }

/* Tables */
.table thead th {
    background: var(--icf-light);
    color: var(--icf-text);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border-bottom: 2px solid var(--icf-border);
    padding: 0.85rem 0.75rem;
}
.table tbody td {
    padding: 0.85rem 0.75rem;
    vertical-align: middle;
    border-bottom: 1px solid #eef2f1;
}
.table tbody tr:hover {
    background: var(--icf-primary-light);
}

/* Badges */
.badge {
    font-weight: 600;
    padding: 0.45em 0.75em;
    border-radius: 6px;
}

/* Progress */
.progress {
    background: #e8edeb;
    border-radius: 10px;
    overflow: hidden;
}
.progress-bar {
    background: var(--icf-primary);
    font-weight: 600;
    font-size: 0.8rem;
}

/* Doc thumb */
.doc-thumb {
    max-height: 140px;
    object-fit: cover;
    border-radius: var(--icf-radius-sm);
    border: 1px solid var(--icf-border);
    transition: var(--icf-transition);
}
.doc-thumb:hover { transform: scale(1.02); }

/* Input group */
.input-group .form-control {
    border-right: none;
}
.input-group .btn {
    border-radius: 0 var(--icf-radius-sm) var(--icf-radius-sm) 0 !important;
}

/* Tooltip style helper */
.field-hint {
    font-size: 0.8rem;
    color: var(--icf-text-muted);
    margin-top: 0.25rem;
}

/* Scholarship selection card */
.scholarship-select-card {
    background: linear-gradient(135deg, var(--icf-primary-light), var(--icf-white));
    border: 2px solid var(--icf-primary);
    border-radius: var(--icf-radius);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

/* Responsive improvements */
@media (max-width: 768px) {
    .hero { padding: 4rem 0 3rem; }
    .hero h1 { font-size: 2rem; }
    .section { padding: 3rem 0; }
    .stepper-step .step-label { display: none; }
    .form-section-card { padding: 1.25rem; }
    .app-sidebar { min-height: auto; }
}

/* Animations */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fade-in {
    animation: fadeInUp 0.5s ease forwards;
}

/* Floating action helpers */
.sticky-submit {
    position: sticky;
    bottom: 0;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(8px);
    padding: 1rem 0;
    border-top: 1px solid var(--icf-border);
    z-index: 10;
}

/* Apply page */
.apply-page-hero {
    background: linear-gradient(135deg, var(--icf-primary), var(--icf-primary-dark));
    color: #fff;
    border-radius: var(--icf-radius);
    padding: 1.75rem 2rem;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
}
.apply-page-hero::after {
    content: '';
    position: absolute;
    right: -40px;
    top: -40px;
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(255,255,255,0.12) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.apply-page-hero h3 { color: #fff; }
.apply-page-hero .text-muted { color: rgba(255,255,255,0.8) !important; }

.form-progress-wrap {
    background: var(--icf-white);
    border-radius: var(--icf-radius);
    padding: 1rem 1.25rem;
    box-shadow: var(--icf-shadow);
    margin-bottom: 1.5rem;
}
.form-progress-wrap .progress {
    height: 10px;
    border-radius: 10px;
}
.form-progress-wrap .progress-bar {
    background: linear-gradient(90deg, var(--icf-primary), #1a8a6e);
    border-radius: 10px;
    transition: width 0.4s ease;
}

/* Input with icon */
.input-icon-wrap {
    position: relative;
}
.input-icon-wrap .input-icon {
    position: absolute;
    left: 0.85rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--icf-text-muted);
    font-size: 1rem;
    pointer-events: none;
    z-index: 2;
}
.input-icon-wrap .form-control,
.input-icon-wrap .form-select {
    padding-left: 2.5rem;
}

/* Photo upload zone */
.photo-upload-zone {
    border: 2px dashed var(--icf-border);
    border-radius: var(--icf-radius);
    padding: 1.25rem;
    text-align: center;
    background: var(--icf-light);
    cursor: pointer;
    transition: var(--icf-transition);
    min-height: 160px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}
.photo-upload-zone:hover,
.photo-upload-zone.drag-over {
    border-color: var(--icf-primary);
    background: var(--icf-primary-light);
}
.photo-upload-zone.has-file {
    border-style: solid;
    border-color: var(--icf-primary);
}
.photo-upload-zone input[type="file"] {
    position: absolute;
    width: 0;
    height: 0;
    opacity: 0;
    overflow: hidden;
}
.photo-preview {
    width: 100px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    border: 3px solid var(--icf-white);
    box-shadow: var(--icf-shadow);
}

/* Scholarship category cards */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.75rem;
}
.category-card {
    position: relative;
    border: 2px solid var(--icf-border);
    border-radius: var(--icf-radius-sm);
    padding: 1rem;
    cursor: pointer;
    transition: var(--icf-transition);
    background: var(--icf-white);
    text-align: center;
}
.category-card:hover {
    border-color: var(--icf-primary);
    background: var(--icf-primary-light);
    transform: translateY(-2px);
}
.category-card.selected {
    border-color: var(--icf-primary);
    background: var(--icf-primary-light);
    box-shadow: 0 0 0 3px rgba(13, 92, 74, 0.15);
}
.category-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.category-card .cat-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--icf-primary-light);
    color: var(--icf-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}
.category-card.selected .cat-icon {
    background: var(--icf-primary);
    color: #fff;
}
.category-card .cat-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--icf-text);
    line-height: 1.3;
}

/* Guardian fieldset */
.guardian-fieldset {
    border: 1.5px solid var(--icf-border);
    border-radius: var(--icf-radius-sm);
    padding: 1rem 1.25rem 0.25rem;
    background: var(--icf-light);
}
.guardian-fieldset legend {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--icf-primary-dark);
    float: none;
    width: auto;
    padding: 0 0.5rem;
    margin-bottom: 0;
}

/* Pill toggle (gender / disability) */
.pill-toggle {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.pill-toggle .btn-check + .btn {
    border-radius: 50px !important;
    padding: 0.45rem 1.1rem;
    font-size: 0.88rem;
    font-weight: 500;
    border: 1.5px solid var(--icf-border);
    color: var(--icf-text-muted);
    background: var(--icf-white);
}
.pill-toggle .btn-check:checked + .btn {
    background: var(--icf-primary);
    border-color: var(--icf-primary);
    color: #fff;
}

/* Section anchor offset for sticky nav */
.form-section-card[data-section],
.declaration-box[data-section] {
    scroll-margin-top: 1rem;
}

/* Stepper clickable */
.stepper-step {
    cursor: pointer;
    transition: var(--icf-transition);
}
.stepper-step:hover .step-circle {
    border-color: var(--icf-primary);
    transform: scale(1.08);
}

/* Document checklist grid */
.doc-checklist {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.65rem;
}
.doc-checklist-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.75rem 1rem;
    background: var(--icf-white);
    border: 1px solid var(--icf-border);
    border-radius: var(--icf-radius-sm);
    font-size: 0.88rem;
    transition: var(--icf-transition);
}
.doc-checklist-item:hover {
    border-color: var(--icf-primary);
    box-shadow: 0 2px 8px rgba(13, 92, 74, 0.08);
}
.doc-checklist-item .doc-num {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--icf-primary-light);
    color: var(--icf-primary);
    font-size: 0.75rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Upload note callout */
.upload-note {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-radius: var(--icf-radius-sm);
    font-size: 0.88rem;
    border-left: 4px solid;
}
.upload-note.info {
    background: #e6f4f1;
    border-color: var(--icf-primary);
    color: var(--icf-primary-dark);
}
.upload-note.warning {
    background: #fff8e6;
    border-color: var(--icf-accent);
    color: #856404;
}

/* Animations */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
    100% { transform: translateY(0px); }
}
.animate-float {
    animation: float 5s ease-in-out infinite;
}

