* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background-color: #f5f5f5;
}

.registration-container {
    max-width: 900px;
    margin: 20px auto;
    padding: 0;
}

.card-border {
    border: 4px solid;
    border-image: repeating-linear-gradient(
        45deg,
        #dc143c 0,
        #dc143c 10px,
        #ffffff 10px,
        #ffffff 20px
    ) 12;
    background-image: url('../images/background.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    position: relative;
}

.card-border::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(125deg, rgba(212, 175, 122, 0.85) 0%, rgba(201, 164, 106, 0.85) 50%, rgba(184, 147, 90, 0.85) 100%);
    z-index: 0;
}

.card-border > * {
    position: relative;
    z-index: 1;
}

/* Header Section */
.header-section {
    margin-bottom: 8px;
}

.header-section .row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-container {
    padding: 10px;
}

.logo-img {
    width: 150px;
    height: 150px;
    border-radius: 5%;
    /*margin-bottom: 10px;*/
}

.logo-text {
    font-size: 10px;
    font-weight: bold;
    line-height: 1.3;
    color: #2c3e50;
    /*margin: 0;*/
}

.pm-photo {
    width: 120px;
    height: 140px;
    object-fit: cover;
    border-radius: 5px;
    /*margin-bottom: 0px;*/
    /*border: 3px solid #fff;*/
}

.pm-name {
    font-size: 16px;
    font-weight: bold;
    color: #2c3e50;
    margin: 8px 0;
}

.govt-logo {
    width: 90px;
    height: 90px;
    margin-bottom: 10px;
}

.support-text {
    font-size: 9px;
    font-weight: bold;
    line-height: 1.3;
    color: #2c3e50;
    margin: 0;
}

/* Title Section */
.title-section {
    margin: 10px 0;
}

.hindi-title {
    font-size: 32px;
    font-weight: bold;
    /*color: #8b0000;*/
    margin-bottom: 5px;
    font-family: 'Noto Sans Devanagari', Arial, sans-serif;
}

.english-title {
    font-size: 20px;
    font-weight: 600;
    color: #2c3e50;
}

/* Ministers Section */
.ministers-section {
    margin: 10px 0;
}

.ministers-section .row {
    display: flex;
    align-items: center;
    justify-content: center;
}

.minister-photo {
    width: 100px;
    height: 120px;
    object-fit: cover;
    border-radius: 5px;
    margin-bottom: 10px;
    /*border: 2px solid #fff;*/
}

.minister-photo-raj {
    width: 100px;
    height: 150px;
    object-fit: cover;
    border-radius: 5px;
    margin-bottom: 5px;
    /*border: 2px solid #fff;*/
}

.minister-name {
    font-size: 12px;
    font-weight: 600;
    color: #2c3e50;
    line-height: 1.4;
}

/* Event Details */
.event-details {
    /*background: rgba(255, 255, 255, 0.9);*/
    border: 3px solid #2c3e50;
    border-radius: 15px;
    padding: 10px;
    margin: 10px auto;
    max-width: 600px;
}

.event-title {
    font-size: 36px;
    font-weight: bold;
    color: #2c3e50;
    margin-bottom: 5px;
}

.event-date {
    font-size: 28px;
    font-weight: bold;
    color: #2c3e50;
}

/* Form Section */
.form-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.form-control {
    border: 2px solid #2c3e50;
    border-radius: 5px;
    padding: 12px;
    font-size: 14px;
    font-weight: 600;
    background: #ffffff;
    color: #2c3e50;
}

.form-control::placeholder {
    color: #7f8c8d;
    font-weight: 500;
}

.form-control:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 0.2rem rgba(52, 152, 219, 0.25);
}

.error-text {
    color: #dc143c;
    font-size: 12px;
    display: block;
    margin-top: 5px;
}

.btn-submit {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    border: none;
    padding: 12px 50px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 5px;
    text-transform: uppercase;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.3);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Footer Section */
.footer-section {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 3px solid rgba(0,0,0,0.1);
}

.footer-section .row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.ncpsl-logo {
    width: 70px;
    height: 70px;
    border-radius: 50%;
}

.ncpsl-text {
    font-size: 14px;
    font-weight: bold;
    color: #2c3e50;
    margin-top: 5px;
}

.vshfa-title {
    font-size: 48px;
    font-weight: bold;
    color: #2c3e50;
    letter-spacing: 2px;
}

.welcome-text {
    font-size: 20px;
    font-weight: bold;
    color: #dc143c;
    font-family: 'Noto Sans Devanagari', Arial, sans-serif;
}

/* User Info Section for Print */
.user-info-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.user-name-display {
    font-size: 24px;
    font-weight: bold;
    color: #2c3e50;
    text-align: center;
    padding: 20px;
    margin: 0;
    text-transform: uppercase;
}

/* Alert Messages */
.alert {
    border-radius: 5px;
    padding: 15px;
    margin-bottom: 20px;
    font-weight: 600;
}

/* Mobile Responsive - Keep Same Layout */
@media (max-width: 768px) {
    .registration-container {
        margin: 10px;
    }
    
    .card-border {
        padding: 20px;
        border-width: 8px;
    }

    /* Keep header layout same */
    .header-section .row {
        flex-direction: row !important;
        flex-wrap: nowrap !important;
    }

    .header-section .col-md-2,
    .header-section .col-md-8 {
        flex: 1;
        min-width: 0;
    }

    .logo-img,
    .govt-logo {
        width: 80px;
        height: 80px;
    }

    .logo-text,
    .support-text {
        font-size: 7px;
        line-height: 1.2;
    }

    .pm-photo {
        width: 90px;
        height: 110px;
    }

    .pm-name {
        font-size: 7px;
    }

    /* Keep title section */
    .hindi-title {
        font-size: 20px;
    }

    .english-title {
        font-size: 14px;
    }

    /* Keep ministers in one row */
    .ministers-section .row {
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        justify-content: space-around;
    }

    .ministers-section .col-md-3 {
        flex: 1;
        min-width: 0;
        padding: 0 5px;
    }

    .minister-photo {
        width: 70px;
        height: 90px;
    }
    
    .minister-photo-raj {
        width: 80px;
        height: 110px;
    }

    .minister-name {
        font-size: 8px;
    }

    /* Event details */
    .event-title {
        font-size: 24px;
    }

    .event-date {
        font-size: 18px;
    }

    /* Form section */
    .form-section {
        padding: 20px;
    }

    /* Keep footer in one row */
    .footer-section .row {
        flex-direction: row !important;
        flex-wrap: nowrap !important;
    }

    .footer-section .col-md-3,
    .footer-section .col-md-6 {
        flex: 1;
        min-width: 0;
    }

    .ncpsl-logo {
        width: 45px;
        height: 45px;
    }

    .ncpsl-text {
        font-size: 11px;
    }

    .vshfa-title {
        font-size: 32px;
    }

    .welcome-text {
        font-size: 14px;
    }

    .btn-submit {
        padding: 10px 40px;
        font-size: 14px;
    }
}

@media (max-width: 576px) {
    .card-border {
        padding: 15px;
        border-width: 6px;
    }

    .logo-img,
    .govt-logo {
        width: 90px;
        height: 90px;
    }

    .logo-text,
    .support-text {
        font-size: 6px;
    }

    .pm-photo {
        width: 80px;
        height: 90px;
    }

    .pm-name {
        font-size: 6px;
    }

    .hindi-title {
        font-size: 16px;
    }

    .english-title {
        font-size: 12px;
    }

    .minister-photo {
        width: 60px;
        height: 80px;
    }
    
    .minister-photo-raj {
        width: 80px;
        height: 110px;
    }

    .minister-name {
        font-size: 7px;
    }

    .event-title {
        font-size: 20px;
    }

    .event-date {
        font-size: 16px;
    }

    .form-section {
        padding: 15px;
    }

    .ncpsl-logo {
        width: 40px;
        height: 40px;
    }

    .ncpsl-text {
        font-size: 9px;
    }

    .vshfa-title {
        font-size: 26px;
    }

    .welcome-text {
        font-size: 12px;
    }
}

/* Print Styles - Single Page Layout */
@media print {
    @page {
        size: A4 portrait;
        margin: 0;
    }

    body {
        margin: 0;
        padding: 0;
        background: white;
    }

    .no-print {
        display: none !important;
    }

    .registration-container {
        margin: 0;
        padding: 0;
        max-width: 100%;
        width: 210mm;
        height: 297mm;
        page-break-after: avoid;
    }

    .card-border {
        box-shadow: none;
        padding: 20px;
        border-width: 10px;
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }

    /* Header */
    .header-section .row {
        display: flex !important;
        flex-direction: row !important;
    }

    .logo-img,
    .govt-logo {
        width: 90px;
        height: 90px;
    }

    .logo-text,
    .support-text {
        font-size: 8px;
    }

    .pm-photo {
        width: 110px;
        height: 130px;
    }

    .pm-name {
        font-size: 9px;
    }

    /* Title */
    .hindi-title {
        font-size: 28px;
    }

    .english-title {
        font-size: 18px;
    }

    /* Ministers */
    .ministers-section .row {
        display: flex !important;
        flex-direction: row !important;
    }

    .minister-photo {
        width: 90px;
        height: 110px;
    }
    
    .minister-photo-raj {
        width: 100px;
        height: 110px;
    }

    .minister-name {
        font-size: 11px;
    }

    /* Event */
    .event-title {
        font-size: 32px;
    }

    .event-date {
        font-size: 24px;
    }

    /* User Info - Replace Form */
    .form-section {
        display: none !important;
    }

    .user-info-section {
        padding: 25px !important;
        margin: 25px 0 !important;
        page-break-inside: avoid;
    }

    .user-name-display {
        font-size: 22px !important;
        padding: 15px !important;
    }

    /* Footer */
    .footer-section {
        margin-top: 20px;
        page-break-inside: avoid;
    }

    .footer-section .row {
        display: flex !important;
        flex-direction: row !important;
    }

    .ncpsl-logo {
        width: 55px;
        height: 55px;
    }

    .ncpsl-text {
        font-size: 12px;
    }

    .vshfa-title {
        font-size: 42px;
    }

    .welcome-text {
        font-size: 18px;
    }

    /* Force single page */
    * {
        page-break-inside: avoid;
    }
}