/* Payment Portal Styles */

/* Main Container */
.payment-container {
    min-height: 100vh;
    background: linear-gradient(135deg, #0d0d0d 0%, #1a1a1a 50%, #0d0d0d 100%);
}

.payment-hero {
    text-align: center;
    margin-bottom: 3rem;
}

.payment-hero h1 {
    font-size: 3rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1rem;
}

.payment-hero p {
    font-size: 1.25rem;
    color: #cccccc;
    max-width: 42rem;
    margin: 0 auto;
}

/* Alert Messages */
.payment-alert {
    padding: 1.5rem;
    border-radius: 0.75rem;
    margin-bottom: 2rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.3);
}

.payment-alert.success {
    background-color: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
}

.payment-alert.error {
    background-color: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
}

.payment-alert-icon {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.payment-alert.success .payment-alert-icon {
    background-color: #10b981;
}

.payment-alert.error .payment-alert-icon {
    background-color: #ef4444;
}

.payment-alert-icon span {
    color: white;
    font-size: 0.875rem;
    font-weight: 700;
}

.payment-alert-text {
    margin-left: 0.75rem;
}

.payment-alert-text p {
    font-size: 0.875rem;
    font-weight: 500;
}

/* Main Content Grid */
.payment-main-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 1024px) {
    .payment-main-grid {
        grid-template-columns: 2fr 1fr;
        gap: 2rem;
    }
}

/* Invoice Lookup Form */
.payment-form-card {
    background: rgba(26, 26, 26, 0.8);
    border-radius: 1rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3),
        0 10px 10px -5px rgba(0, 0, 0, 0.2);
    padding: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.payment-form-header {
    margin-bottom: 1.5rem;
}

.payment-form-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.payment-form-header p {
    color: #cccccc;
}

.payment-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.payment-form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.75rem;
}

.payment-input-wrapper {
    position: relative;
}

.payment-input {
    width: 100%;
    padding: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 0.75rem;
    font-size: 1.125rem;
    background: rgba(0, 0, 0, 0.3);
    color: #ffffff;
    transition: all 0.2s;
}

.payment-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.payment-input:focus {
    outline: none;
    border-color: #a78bfa;
    box-shadow: 0 0 0 4px rgba(167, 139, 250, 0.1);
    background: rgba(0, 0, 0, 0.5);
}

.payment-input-icon {
    position: absolute;
    inset: 0;
    right: 0.75rem;
    display: flex;
    align-items: center;
    pointer-events: none;
}

.payment-input-icon svg {
    height: 1.25rem;
    width: 1.25rem;
    color: rgba(255, 255, 255, 0.5);
}

.payment-submit-btn {
    width: 100%;
    background: linear-gradient(135deg, #5b21b6 0%, #7c3aed 100%);
    color: white;
    font-weight: 700;
    padding: 1rem 1.5rem;
    border-radius: 0.75rem;
    transition: all 0.2s;
    transform: scale(1);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
    border: none;
    cursor: pointer;
}

.payment-submit-btn:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
    transform: scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4);
}

.payment-submit-btn span {
    display: flex;
    align-items: center;
    justify-content: center;
}

.payment-submit-btn svg {
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 0.5rem;
}

/* How It Works */
.payment-how-it-works {
    background: rgba(26, 26, 26, 0.8);
    border-radius: 1rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.3),
        0 10px 10px -5px rgba(0, 0, 0, 0.2);
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.payment-how-it-works h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1.5rem;
}

.payment-steps {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.payment-step {
    display: flex;
    align-items: flex-start;
}

.payment-step-number {
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    background-color: rgba(167, 139, 250, 0.2);
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.75rem;
}

.payment-step-number span {
    color: #a78bfa;
    font-weight: 700;
    font-size: 0.875rem;
}

.payment-step-content h4 {
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.25rem;
}

.payment-step-content p {
    font-size: 0.875rem;
    color: #cccccc;
}

/* Features Section */
.payment-features {
    margin-top: 3rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .payment-features {
        grid-template-columns: repeat(3, 1fr);
    }
}

.payment-feature-card {
    background: rgba(26, 26, 26, 0.8);
    border-radius: 1rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    backdrop-filter: blur(10px);
}

.payment-feature-icon {
    width: 2rem;
    height: 2rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.payment-feature-icon.green {
    background-color: rgba(16, 185, 129, 0.2);
}

.payment-feature-icon.blue {
    background-color: rgba(59, 130, 246, 0.2);
}

.payment-feature-icon.purple {
    background-color: rgba(167, 139, 250, 0.2);
}

.payment-feature-icon svg {
    width: 1rem;
    height: 1rem;
}

.payment-feature-icon.green svg {
    color: #10b981;
}

.payment-feature-icon.blue svg {
    color: #3b82f6;
}

.payment-feature-icon.purple svg {
    color: #a78bfa;
}

.payment-feature-card h3 {
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.payment-feature-card p {
    color: #cccccc;
    font-size: 0.875rem;
}

/* Security Notice */
.payment-security {
    margin-top: 3rem;
    background: linear-gradient(
        135deg,
        rgba(16, 185, 129, 0.1) 0%,
        rgba(20, 184, 166, 0.1) 100%
    );
    border-radius: 1rem;
    padding: 2rem;
    border: 1px solid rgba(16, 185, 129, 0.3);
    backdrop-filter: blur(10px);
}

.payment-security-content {
    display: flex;
    align-items: center;
    justify-content: center;
}

.payment-security-icon {
    width: 3rem;
    height: 3rem;
    background-color: rgba(16, 185, 129, 0.2);
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1.5rem;
}

.payment-security-icon svg {
    width: 1.5rem;
    height: 1.5rem;
    color: #10b981;
}

.payment-security-text {
    text-align: center;
}

@media (min-width: 1024px) {
    .payment-security-text {
        text-align: left;
    }
}

.payment-security-text h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #10b981;
    margin-bottom: 0.5rem;
}

.payment-security-text p {
    color: #34d399;
}

/* Contact Information */
.payment-contact {
    margin-top: 3rem;
    text-align: center;
}

.payment-contact p {
    color: #cccccc;
    margin-bottom: 0.5rem;
}

.payment-contact a {
    display: inline-flex;
    align-items: center;
    color: #a78bfa;
    font-weight: 500;
    transition: color 0.2s;
    text-decoration: none;
}

.payment-contact a:hover {
    color: #c4b5fd;
}

.payment-contact svg {
    width: 1rem;
    height: 1rem;
    margin-right: 0.5rem;
}

/* Responsive Adjustments */
@media (max-width: 640px) {
    .payment-hero h1 {
        font-size: 2.5rem;
    }

    .payment-hero p {
        font-size: 1.125rem;
    }

    .payment-form-card,
    .payment-how-it-works {
        padding: 1.5rem;
    }

    .payment-security {
        padding: 1.5rem;
    }

    .payment-security-content {
        flex-direction: column;
        text-align: center;
    }

    .payment-security-icon {
        margin-right: 0;
        margin-bottom: 1rem;
    }
}

/* ================= Invoice Page ================= */
.invoice-wrapper {
    padding: 4rem 1rem;
}

.invoice-card {
    background: rgba(26, 26, 26, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
    padding: 2rem;
}

.invoice-header h1 {
    color: #ffffff;
}

.invoice-header a {
    background: linear-gradient(135deg, #5b21b6 0%, #7c3aed 100%);
    border: none;
    border-radius: 0.5rem;
    color: #ffffff;
    padding: 0.5rem 1.25rem;
    font-weight: 600;
    transition: background 0.2s ease;
    text-decoration: none;
}

.invoice-header a:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
}

.invoice-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.invoice-badge.open {
    background-color: rgba(250, 204, 21, 0.2);
    color: #fde047;
}

.invoice-badge.paid {
    background-color: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.invoice-badge.overdue {
    background-color: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.invoice-badge.draft {
    background-color: rgba(234, 179, 8, 0.2); /* amber-500 */
    color: #fde047; /* amber-300 */
}

.invoice-section {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    padding: 1.5rem;
}

.invoice-section h2 {
    color: #ffffff;
    margin-bottom: 1rem;
}

.invoice-section p,
.invoice-section table,
.invoice-section th,
.invoice-section td {
    color: #cccccc;
}

.invoice-table th,
.invoice-table td {
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.invoice-table th {
    background: rgba(255, 255, 255, 0.05);
}

.invoice-actions {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.75rem;
    padding: 1.5rem;
}

.invoice-actions h2 {
    color: #3b82f6;
}

.invoice-actions p {
    color: #93c5fd;
}

.invoice-pay-btn {
    background: linear-gradient(135deg, #5b21b6 0%, #7c3aed 100%);
    border: none;
    border-radius: 0.75rem;
    color: #ffffff;
    font-weight: 700;
    padding: 0.75rem 1.5rem;
    transition: transform 0.2s ease, background 0.2s ease;
}

.invoice-pay-btn:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
    transform: scale(1.05);
}

/* Back to portal link */
.invoice-back {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(135deg, #5b21b6 0%, #7c3aed 100%);
    color: #ffffff;
    padding: 0.5rem 1.25rem;
    border-radius: 0.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    text-decoration: none;
    transition: background 0.2s ease;
}
.invoice-back:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #a78bfa 100%);
}
