﻿/* Subscriber Form Bootstrap 5 Styles */

/* Alert Container Styles */
.alert-container {
    margin-bottom: 1.5rem;
}

.alert {
    border-radius: 0.375rem;
}

.alert-link {
    color: inherit;
    text-decoration: underline;
}

/* Form Control Styles */
.form-control,
.form-select {
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    padding: 0.5rem 0.75rem;
    font-size: 1rem;
}

.form-control:focus,
.form-select:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* Form Label Styles */
.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
    display: block;
}

/* Card Styles */
.card {
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    margin-bottom: 1rem;
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    padding: 0.75rem 1.25rem;
    border-radius: 0.375rem 0.375rem 0 0;
}

.card-header h2,
.card-header h4 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
}

.card-header .btn {
    padding: 0;
    text-align: left;
    width: 100%;
    position: relative;
}

.card-header .btn:hover {
    text-decoration: none;
    background-color: transparent;
}

/* Section Subtitles for Form Groups */
.section-subtitle {
    font-size: 1rem;
    font-weight: 600;
    color: #212529;
    margin-bottom: 1rem;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 0.5rem;
    display: block;
}

.checkboxes-container,
.radios-container,
.checkboxes-group,
.radios-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.card-body {
    padding: 1.25rem;
}

/* Checkbox and Radio Button Styles */
.form-check {
    padding-left: 0;
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: auto;
    gap: 0.75rem;
    align-items: center;
}

.form-check-input {
    margin: 0;
    cursor: pointer;
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
    grid-column: 1;
    grid-row: 1;
}

.form-check-label {
    margin-bottom: 0;
    cursor: pointer;
    user-select: none;
    padding: 0;
    grid-column: 2;
    grid-row: 1;
}

.checkboxes-group,
.radios-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

/* Button Styles */
.btn-primary {
    background-color: #007bff;
    border-color: #007bff;
    color: white;
}

.btn-primary:hover {
    background-color: #0056b3;
    border-color: #0056b3;
}

.btn-primary:active,
.btn-primary.active {
    background-color: #004085;
    border-color: #004085;
}

.btn-primary:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5);
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.25rem;
    border-radius: 0.375rem;
}

/* Collapse Styles */
.collapse:not(.show) {
    display: none;
}

.collapse.show {
    display: block;
}

.collapse-toggle {
    cursor: pointer;
}

.collapse-toggle .fa-chevron-down {
    transition: transform 0.3s ease;
}

.collapse-toggle[aria-expanded="true"] .fa-chevron-down {
    transform: rotate(-180deg);
}

/* Spacing Utilities */
.mt-3 {
    margin-top: 1rem !important;
}

.mt-5 {
    margin-top: 3rem !important;
}

.mb-3 {
    margin-bottom: 1rem !important;
}

.ms-2 {
    margin-left: 0.5rem !important;
}

.float-end {
    float: right !important;
}

/* Row and Column Helpers */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -0.5rem;
    margin-left: -0.5rem;
}

.col-12 {
    flex: 0 0 100%;
    padding-right: 0.5rem;
    padding-left: 0.5rem;
}

.col-auto {
    flex: 0 0 auto;
    width: auto;
    padding-right: 0.5rem;
    padding-left: 0.5rem;
}

/* Responsive Design */
@media (max-width: 991.98px) {
    .col-lg-5,
    .col-lg-6,
    .col-lg-7 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .offset-lg-1 {
        margin-left: 0;
    }

    .card-header .btn {
        font-size: 1rem;
    }

    .btn-lg {
        width: 100%;
    }

    .section-subtitle {
        font-size: 0.95rem;
        margin-top: 1rem;
    }

    .section-subtitle:first-child {
        margin-top: 0;
    }

    .checkboxes-container,
    .radios-container {
        margin-top: 0.5rem;
    }
}

@media (min-width: 992px) {
    .col-lg-5 {
        flex: 0 0 41.666667%;
        max-width: 41.666667%;
    }

    .col-lg-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }

    .col-lg-7 {
        flex: 0 0 58.333333%;
        max-width: 58.333333%;
    }

    .offset-lg-1 {
        margin-left: 8.333333%;
    }

    .section-subtitle {
        font-size: 1rem;
    }
}

/* Additional Spacing and Alignment */
.align-items-start {
    align-items: flex-start !important;
}

.mb-4 {
    margin-bottom: 1.5rem !important;
}

/* Validation Feedback Styles */
.invalid-feedback {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.is-invalid .form-control,
.is-invalid .form-select {
    border-color: #dc3545;
}

/* Text Utilities */
.text-muted {
    color: #6c757d !important;
}

.text-center {
    text-align: center !important;
}

/* Stretched Link */
.stretched-link {
    position: relative;
}

.stretched-link::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
    pointer-events: auto;
}

/* reCAPTCHA Container */
.g-recaptcha {
    margin-top: 1rem;
}

/* Header Styles for Collapsible Cards */
.card-header .btn.collapsed::after {
    display: none;
}

.card-header .fa-chevron-down {
    transition: transform 0.3s ease;
    display: inline-block;
}

.card-header .btn.collapsed .fa-chevron-down {
    transform: rotate(-180deg);
}

/* Print Styles */
@media print {
    .card {
        page-break-inside: avoid;
    }
}


.header-custom {
    font-size: 0.875rem !important;
    font-weight: 600;
}