/* Frontend Candidate Result Search Page Styling */

/* General Container and Layout */
.result-search-section {
    background-color: #f8fafc;
    padding: 3rem 0 5rem 0;
}

/* Search Box Container */
.search-card-container {
    max-width: 600px;
    margin: 0 auto 3rem auto;
}

.search-box-card {
    background: #ffffff;
    border-radius: 16px;
    border: none;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
    padding: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.search-box-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.search-box-card h4 {
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.search-box-card p {
    color: #64748b;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.search-input-group .form-control {
    height: 52px;
    border-radius: 8px 0 0 8px;
    border: 2px solid #e2e8f0;
    font-size: 1rem;
    font-weight: 500;
    padding-left: 1.25rem;
    transition: all 0.3s ease;
}

.search-input-group .form-control:focus {
    border-color: #4f46e5;
    box-shadow: none;
}

.search-input-group .btn-search-submit {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    border: none;
    color: #ffffff;
    padding: 0 1.5rem;
    border-radius: 0 8px 8px 0;
    font-weight: 600;
    transition: all 0.3s ease;
}

.search-input-group .btn-search-submit:hover {
    background: linear-gradient(135deg, #4338ca 0%, #6d28d9 100%);
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.2);
}

/* Premium Certificate/Mark Sheet Card */
.result-card-container {
    max-width: 800px;
    margin: 0 auto;
}

.result-certificate-card {
    background: #ffffff;
    border: 15px double #1e293b;
    padding: 3rem;
    border-radius: 4px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
}

/* Background Watermark/Seal */
.result-certificate-card::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    height: 300px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.03;
    pointer-events: none;
}

.certificate-header {
    text-align: center;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 1.5rem;
    margin-bottom: 2rem;
}

.certificate-logo {
    max-height: 75px;
    margin-bottom: 1rem;
}

.certificate-header h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: #1e3a8a;
    margin-bottom: 0.25rem;
    letter-spacing: 0.5px;
}

.certificate-header p {
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 0.5rem;
}

.certificate-header .title-badge {
    display: inline-block;
    background-color: #f1f5f9;
    border: 1px solid #cbd5e1;
    color: #1e293b;
    padding: 0.35rem 1.25rem;
    font-size: 0.95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0.5rem;
    border-radius: 4px;
}

/* Candidate details table */
.candidate-details-table {
    width: 100%;
    margin-bottom: 2rem;
}

.candidate-details-table td {
    padding: 0.6rem 0.5rem;
    vertical-align: middle;
    font-size: 0.95rem;
    border-bottom: 1px dashed #e2e8f0;
}

.candidate-details-table td.detail-label {
    font-weight: 600;
    color: #475569;
    width: 25%;
    text-transform: uppercase;
    font-size: 0.85rem;
}

.candidate-details-table td.detail-value {
    color: #1e293b;
    font-weight: 700;
}

/* Score Card Section */
.marks-summary-box {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.marks-info h5 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.25rem;
}

.marks-info p {
    font-size: 0.85rem;
    color: #64748b;
    margin-bottom: 0;
}

.score-badge {
    background-color: #1e3a8a;
    color: #ffffff;
    padding: 0.75rem 1.5rem;
    font-size: 1.6rem;
    font-weight: 800;
    border-radius: 6px;
    box-shadow: 0 4px 6px -1px rgba(30, 58, 138, 0.2);
}

.certificate-footer-signatures {
    display: flex;
    justify-content: space-between;
    margin-top: 4rem;
    padding-top: 1.5rem;
}

.signature-line {
    text-align: center;
    width: 180px;
}

.signature-line hr {
    margin: 0.5rem 0;
    border-top: 1.5px solid #94a3b8;
}

.signature-line p {
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
}

/* Print/Actions Container */
.print-actions-container {
    text-align: center;
    margin-top: 2rem;
}

.btn-print-result {
    background: #0f172a;
    color: #ffffff;
    font-weight: 600;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px -1px rgba(15, 23, 42, 0.15);
    transition: all 0.3s ease;
}

.btn-print-result:hover {
    background: #1e293b;
    color: #ffffff;
    box-shadow: 0 6px 12px rgba(15, 23, 42, 0.2);
}

/* Warning/Error Card */
.not-found-card {
    background: #ffffff;
    border-radius: 16px;
    border: none;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
    padding: 3rem 2rem;
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.not-found-card .icon-container {
    width: 70px;
    height: 70px;
    background-color: #fef3c7;
    color: #d97706;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    margin: 0 auto 1.5rem auto;
}

.not-found-card h4 {
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.not-found-card p {
    color: #64748b;
    font-size: 0.95rem;
    margin-bottom: 0;
}

/* Printing styles */
@media print {
    /* Hide everything on the page */
    body * {
        visibility: hidden;
    }
    
    /* Make print container visible */
    #print-area, #print-area * {
        visibility: visible;
    }
    
    #print-area {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        border: none !important;
        box-shadow: none !important;
        padding: 0 !important;
        margin: 0 !important;
        background: #ffffff !important;
    }
    
    /* Hide buttons/actions in printing */
    .print-actions-container {
        display: none !important;
    }
    
    /* Remove double borders if they cause clipping, but standard is fine. Let's keep certificate border */
    .result-certificate-card {
        border: 10px double #1e293b !important;
        box-shadow: none !important;
        padding: 2rem !important;
    }
}
