/* =================================================================
   BMCC Admission Form - Black & White Theme
   ================================================================= */

/* ===========================
   CSS Variables
   =========================== */
:root {
    /* Colors */
    --primary-color: #000000;
    --primary-light: #333333;
    --secondary-color: #1a1a1a;
    --accent-color: #404040;

    --success-color: #2d2d2d;
    --error-color: #1a1a1a;

    --bg-primary: #ffffff;
    --bg-secondary: #f5f5f5;
    --bg-tertiary: #e0e0e0;
    --bg-card: rgba(255, 255, 255, 0.95);

    --text-primary: #000000;
    --text-secondary: #333333;
    --text-muted: #666666;

    --border-color: rgba(0, 0, 0, 0.15);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 20px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.2);

    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-secondary: 'Poppins', sans-serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;

    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;

    /* Transitions */
    --transition-fast: 150ms ease-in-out;
    --transition-base: 250ms ease-in-out;
}

/* ===========================
   Base Styles
   =========================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-primary);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

/* ===========================
   Background Animation
   =========================== */
.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(135deg, #ffffff 0%, #f5f5f5 25%, #e0e0e0 50%, #f5f5f5 75%, #ffffff 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

/* ===========================
   Header
   =========================== */
.header {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-bottom: 2px solid var(--border-color);
    padding: var(--spacing-md) 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-md);
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.logo-section {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.college-logo {
    width: 80px;
    height: 80px;
    object-fit: contain;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.15));
    transition: all var(--transition-base);
    animation: logoFloat 3s ease-in-out infinite;
}

.college-logo:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 6px 15px rgba(0, 0, 0, 0.25));
}

@keyframes logoFloat {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-5px);
    }
}

.header-text h1 {
    font-family: var(--font-secondary);
    font-size: 1.75rem;
    font-weight: 700;
    background: linear-gradient(135deg, #000000, #404040);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.25rem;
}

.header-text p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ===========================
   Main Container
   =========================== */
.main-container {
    max-width: 1200px;
    margin: var(--spacing-xl) auto;
    padding: 0 var(--spacing-md);
    min-height: calc(100vh - 200px);
}

.form-wrapper {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-xl);
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===========================
   Progress Bar
   =========================== */
.progress-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-xl);
    padding: var(--spacing-md);
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow-x: auto;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-xs);
    flex-shrink: 0;
    transition: all var(--transition-base);
}

.step-number {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.125rem;
    color: var(--text-muted);
    transition: all var(--transition-base);
}

.step-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
    white-space: nowrap;
    transition: all var(--transition-base);
}

.progress-step.active .step-number {
    background: linear-gradient(135deg, #000000, #333333);
    border-color: #000000;
    color: white;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
    transform: scale(1.1);
}

.progress-step.active .step-label {
    color: var(--text-primary);
    font-weight: 600;
}

.progress-step.completed .step-number {
    background: var(--success-color);
    border-color: var(--success-color);
    color: white;
}

.progress-step.completed .step-label {
    color: var(--text-secondary);
}

.progress-line {
    flex: 1;
    height: 2px;
    background: var(--border-color);
    margin: 0 var(--spacing-sm);
    position: relative;
    overflow: hidden;
}

.progress-line::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #000000, #333333);
    transition: width 0.6s ease;
}

.progress-step.completed+.progress-line::before {
    width: 100%;
}

/* ===========================
   Form Header
   =========================== */
.form-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.form-header h2 {
    font-family: var(--font-secondary);
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, #000000, #404040);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--spacing-xs);
}

.form-header p {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* ===========================
   Form Sections
   =========================== */
.form-step {
    display: none;
    animation: fadeIn 0.4s ease-in;
}

.form-step.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.section-title {
    font-family: var(--font-secondary);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--spacing-lg);
    padding-bottom: var(--spacing-sm);
    border-bottom: 3px solid var(--primary-color);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 100px;
    height: 3px;
    background: linear-gradient(90deg, #404040, transparent);
}

.form-section {
    background: rgba(0, 0, 0, 0.02);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
    transition: all var(--transition-base);
}

.form-section:hover {
    border-color: rgba(0, 0, 0, 0.3);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.subsection-title {
    font-family: var(--font-secondary);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: var(--spacing-md);
}

/* ===========================
   Form Controls
   =========================== */
.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-weight: 500;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
}

.required {
    color: var(--error-color);
    font-weight: 700;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.9375rem;
    font-family: var(--font-primary);
    transition: all var(--transition-base);
    outline: none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.help-text {
    font-size: 0.8125rem;
    color: var(--text-muted);
    font-style: italic;
}

/* ===========================
   File Upload
   =========================== */
.file-upload-group {
    position: relative;
}

.file-upload-group input[type="file"] {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden;
    z-index: -1;
}

.file-upload-label {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: 1.5rem;
    background: var(--bg-secondary);
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-base);
    text-align: center;
    justify-content: center;
}

.file-upload-label:hover {
    border-color: var(--primary-color);
    background: rgba(0, 0, 0, 0.05);
    transform: translateY(-2px);
}

.file-upload-group input[type="file"]:focus+.file-upload-label {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
}

.file-icon {
    font-size: 1.5rem;
}

.file-text {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.file-upload-group input[type="file"]:valid+.file-upload-label {
    border-color: var(--success-color);
    background: rgba(0, 0, 0, 0.05);
}

.file-upload-group input[type="file"]:valid+.file-upload-label .file-text::after {
    content: ' ✓';
    color: var(--success-color);
    font-weight: 700;
}

/* ===========================
   Declaration Box
   =========================== */
.declaration-box {
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
}

.declaration-box p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: var(--spacing-md);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.checkbox-group label {
    cursor: pointer;
    user-select: none;
}

/* ===========================
   Form Navigation
   =========================== */
.form-navigation {
    display: flex;
    justify-content: space-between;
    gap: var(--spacing-md);
    margin-top: var(--spacing-xl);
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--border-color);
}

.btn-primary,
.btn-secondary {
    padding: 1rem 2.5rem;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    font-family: var(--font-primary);
    cursor: pointer;
    transition: all var(--transition-base);
    outline: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, #000000, #333333);
    color: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--bg-tertiary);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.btn-secondary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-submit {
    background: linear-gradient(135deg, #2d2d2d, #1a1a1a);
}

.btn-submit:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* ===========================
   Footer
   =========================== */
.footer {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-top: 2px solid var(--border-color);
    padding: var(--spacing-lg) 0;
    margin-top: var(--spacing-xl);
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    text-align: center;
    color: var(--text-secondary);
}

.footer-content p {
    margin-bottom: var(--spacing-xs);
    font-size: 0.9375rem;
}

.footer-content a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.footer-content a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

/* ===========================
   Modal
   =========================== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xl);
    max-width: 500px;
    width: 90%;
    text-align: center;
    animation: scaleIn 0.4s ease;
    box-shadow: var(--shadow-xl);
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.success-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #2d2d2d, #1a1a1a);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    margin: 0 auto var(--spacing-lg);
    animation: checkmarkPop 0.6s ease;
}

@keyframes checkmarkPop {
    0% {
        transform: scale(0);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}

.modal-content h2 {
    font-family: var(--font-secondary);
    font-size: 1.75rem;
    color: var(--text-primary);
    margin-bottom: var(--spacing-md);
}

.modal-content p {
    color: var(--text-secondary);
    margin-bottom: var(--spacing-sm);
}

.application-id {
    background: rgba(0, 0, 0, 0.05);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    margin: var(--spacing-md) 0;
    border: 1px solid var(--border-color);
}

.application-id strong {
    color: var(--primary-color);
    font-size: 1.125rem;
    font-family: monospace;
}

/* ===========================
   Responsive Design
   =========================== */
@media (max-width: 768px) {
    .header-text h1 {
        font-size: 1.25rem;
    }

    .college-logo {
        width: 60px;
        height: 60px;
    }

    .progress-container {
        padding: var(--spacing-sm);
    }

    .step-number {
        width: 40px;
        height: 40px;
        font-size: 0.9375rem;
    }

    .step-label {
        font-size: 0.75rem;
    }

    .form-wrapper {
        padding: var(--spacing-md);
    }

    .form-header h2 {
        font-size: 1.5rem;
    }

    .section-title {
        font-size: 1.375rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .form-navigation {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    .main-container {
        margin: var(--spacing-md) auto;
    }

    .progress-line {
        display: none;
    }

    .progress-container {
        gap: var(--spacing-xs);
    }
}

/* ===========================
   Utility Classes
   =========================== */
.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 4px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}