/* Quest AJEST Portal Stylesheet */
:root {
    --primary: #0b1f4a;
    --primary-dark: #071533;
    --primary-light: #1e3a8a;
    --accent: #10b981;
    --accent-dark: #059669;
    --gold: #d97706;
    --text-dark: #0f172a;
    --text-muted: #64748b;
    --bg-light: #f8fafc;
    --card-bg: #ffffff;
    --border-color: #e2e8f0;
    --radius: 12px;
    --shadow: 0 10px 25px -5px rgba(11, 31, 74, 0.08), 0 8px 10px -6px rgba(11, 31, 74, 0.04);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.5;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Banner / Header */
.portal-header {
    background: #ffffff;
    border-bottom: 2px solid #e2e8f0;
    padding: 16px 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.03);
}

.header-container {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
}

.brand-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
    text-decoration: none;
    color: inherit;
}

.journal-banner-img {
    max-height: 65px;
    width: auto;
    object-fit: contain;
    display: block;
}

.header-nav {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-link {
    color: var(--primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 6px;
    transition: all 0.2s;
}

.nav-link:hover {
    background-color: #eff6ff;
}

.nav-link-btn {
    background: var(--primary);
    color: #ffffff !important;
}

.nav-link-btn:hover {
    background: var(--primary-light);
}

/* Container */
.main-wrapper {
    flex: 1;
    max-width: 900px;
    width: 100%;
    margin: 30px auto;
    padding: 0 16px;
}

/* Notice Bar */
.notice-box {
    background: #eff6ff;
    border-left: 4px solid var(--primary-light);
    padding: 14px 18px;
    border-radius: 8px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.notice-box p {
    font-size: 14px;
    color: #1e3a8a;
    margin: 0;
}

/* Portal Card */
.portal-card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.card-header-bar {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #ffffff;
    padding: 24px 30px;
}

.card-header-bar h1 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 6px;
    letter-spacing: -0.3px;
}

.card-header-bar p {
    font-size: 14px;
    color: #bfdbfe;
    margin: 0;
}

.card-body {
    padding: 30px;
}

/* Forms */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 640px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}

.form-group {
    margin-bottom: 20px;
}

.form-group.col-span-2 {
    grid-column: span 2;
}

@media (max-width: 640px) {
    .form-group.col-span-2 {
        grid-column: span 1;
    }
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 8px;
}

.form-label span.req {
    color: #ef4444;
}

.form-control {
    width: 100%;
    padding: 12px 14px;
    font-size: 15px;
    color: var(--text-dark);
    background-color: #ffffff;
    border: 1.5px solid var(--border-color);
    border-radius: 8px;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
    font-family: inherit;
}

.form-control:focus {
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.15);
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23475569'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 18px;
    padding-right: 40px;
}

.input-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 6px;
    display: block;
}

/* Pricing Model Banner */
.pricing-summary-card {
    background: #f8fafc;
    border: 2px dashed #cbd5e1;
    border-radius: 10px;
    padding: 20px;
    margin: 24px 0;
    transition: all 0.3s ease;
}

.pricing-summary-card.active-local {
    background: #f0fdf4;
    border-color: #86efac;
}

.pricing-summary-card.active-intl {
    background: #f0f9ff;
    border-color: #7dd3fc;
}

.pricing-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.model-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tag-local {
    background: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.tag-intl {
    background: #e0f2fe;
    color: #0369a1;
    border: 1px solid #bae6fd;
}

.price-display-amount {
    font-size: 28px;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
}

.fee-description-text {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 10px;
    line-height: 1.5;
}

/* Submit Button */
.btn-pay {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 16px 24px;
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    background: #0b1f4a;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 0 4px 6px -1px rgba(11, 31, 74, 0.2);
    transition: all 0.2s;
}

.btn-pay:hover {
    background: #1e3a8a;
    transform: translateY(-1px);
    box-shadow: 0 6px 12px -2px rgba(11, 31, 74, 0.25);
}

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

.paystack-guarantee {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 12px;
    color: #64748b;
    margin-top: 14px;
}

/* Success / Receipt Page */
.success-container {
    max-width: 650px;
    margin: 40px auto;
    background: #ffffff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    overflow: hidden;
    text-align: center;
}

.success-top-hero {
    background: #ecfdf5;
    padding: 36px 20px 24px;
    border-bottom: 1px solid #d1fae5;
}

.check-icon-circle {
    width: 72px;
    height: 72px;
    background: #10b981;
    color: #ffffff;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    box-shadow: 0 10px 15px -3px rgba(16, 185, 129, 0.3);
    margin-bottom: 16px;
    animation: bounceIn 0.6s ease;
}

@keyframes bounceIn {
    0% { transform: scale(0.3); opacity: 0; }
    50% { transform: scale(1.05); }
    70% { transform: scale(0.9); }
    100% { transform: scale(1); opacity: 1; }
}

.success-title {
    font-size: 24px;
    font-weight: 800;
    color: #065f46;
    margin-bottom: 6px;
}

.success-subtitle {
    font-size: 14px;
    color: #047857;
}

/* Redirect Countdown Box */
.countdown-box {
    background: #fffbeb;
    border: 1.5px solid #fde68a;
    border-radius: 8px;
    padding: 14px;
    margin: 20px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    gap: 10px;
}

.countdown-box p {
    font-size: 14px;
    color: #92400e;
    margin: 0;
}

.countdown-num {
    display: inline-block;
    background: #f59e0b;
    color: #ffffff;
    font-weight: bold;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    text-align: center;
    line-height: 26px;
    font-size: 14px;
}

.btn-cancel-redirect {
    background: none;
    border: 1px solid #d97706;
    color: #b45309;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    font-weight: 600;
}

.btn-cancel-redirect:hover {
    background: #fef3c7;
}

/* Receipt Details */
.receipt-table-wrapper {
    padding: 24px 30px;
    text-align: left;
}

.receipt-table {
    width: 100%;
    border-collapse: collapse;
}

.receipt-table th, .receipt-table td {
    padding: 12px 14px;
    font-size: 14px;
    border-bottom: 1px solid #f1f5f9;
}

.receipt-table th {
    color: #64748b;
    font-weight: 500;
    width: 40%;
}

.receipt-table td {
    color: #0f172a;
    font-weight: 600;
}

.receipt-actions {
    padding: 20px 30px 30px;
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f1f5f9;
    color: #334155;
    padding: 12px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    border: 1px solid #cbd5e1;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-secondary:hover {
    background: #e2e8f0;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--primary);
    color: #ffffff !important;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-primary:hover {
    background: var(--primary-light);
}

/* Footer */
.portal-footer {
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    padding: 20px;
    text-align: center;
    font-size: 13px;
    color: var(--text-muted);
    margin-top: auto;
}

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

.portal-footer a:hover {
    text-decoration: underline;
}

/* Print CSS */
@media print {
    body {
        background: #ffffff;
        color: #000000;
    }
    .portal-header, .portal-footer, .countdown-box, .receipt-actions, .no-print {
        display: none !important;
    }
    .success-container {
        box-shadow: none;
        border: none;
        margin: 0;
        max-width: 100%;
    }
}
