/* ============================================================
   Letnia Akademia Trąbki – Formularz rejestracyjny
   Nowoczesny styl dopasowany do szablonu SSO Przemyśl
   ============================================================ */

/* --- Sekcje formularza --- */
.lat-section {
    margin-bottom: 30px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    border: 1px solid #e8e8e8;
    transition: box-shadow 0.3s ease;
}
.lat-section:hover {
    box-shadow: 0 4px 20px rgba(128, 0, 0, 0.08);
}

.lat-section-header {
    background: linear-gradient(135deg, #800000 0%, #a00000 100%);
    color: #fff;
    padding: 16px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}
.lat-section-header h3 {
    margin: 0;
    font-family: 'play', sans-serif;
    font-weight: bold;
    font-size: 1.2rem;
    letter-spacing: 0.02em;
}
.lat-section-header h3 small {
    font-weight: normal;
    font-size: 0.85rem;
    opacity: 0.8;
}
.lat-section-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    min-width: 36px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    font-family: 'play', sans-serif;
    font-weight: bold;
    font-size: 1.1rem;
}

.lat-section-body {
    padding: 24px;
    background: #fff;
}

/* --- Pola formularza --- */
.lat-field {
    margin-bottom: 20px;
}
.lat-field label {
    display: block;
    margin-bottom: 6px;
    font-family: 'play', sans-serif;
    font-weight: bold;
    color: #333;
    font-size: 0.95rem;
}
.lat-field .req {
    color: #800000;
    font-weight: bold;
}
.lat-field .form-control {
    border: 2px solid #ddd;
    border-radius: 6px;
    padding: 10px 14px;
    font-family: 'play', sans-serif;
    font-size: 0.95rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    background-color: #fafafa;
}
.lat-field .form-control:focus {
    border-color: #800000;
    box-shadow: 0 0 0 3px rgba(128, 0, 0, 0.1);
    background-color: #fff;
    outline: none;
}
.lat-field .form-control.is-invalid {
    border-color: #dc3545;
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
}
.lat-field .form-control.is-valid {
    border-color: #28a745;
}
.lat-field textarea.form-control {
    resize: vertical;
    min-height: 80px;
}

.lat-error {
    color: #dc3545;
    font-size: 0.85rem;
    margin-top: 4px;
    min-height: 0;
    font-family: 'play', sans-serif;
}

/* --- Toggle switch --- */
.lat-switch {
    position: relative;
    display: inline-block;
    width: 56px;
    height: 30px;
}
.lat-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.lat-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 30px;
}
.lat-slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 4px;
    bottom: 4px;
    background-color: #fff;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.lat-switch input:checked + .lat-slider {
    background-color: #800000;
}
.lat-switch input:checked + .lat-slider:before {
    transform: translateX(26px);
}
.lat-switch input:focus + .lat-slider {
    box-shadow: 0 0 0 3px rgba(128, 0, 0, 0.15);
}

/* --- Karty wyżywienia --- */
.lat-meal-options {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.lat-meal-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    border: 2px solid #e8e8e8;
    border-radius: 8px;
    transition: border-color 0.3s, background-color 0.3s;
}
.lat-meal-card:hover {
    border-color: #800000;
    background-color: #fdf5f5;
}
.lat-meal-card.active {
    border-color: #800000;
    background-color: #fdf5f5;
}
.lat-meal-icon {
    font-size: 1.8rem;
    color: #800000;
    width: 50px;
    text-align: center;
}
.lat-meal-info {
    flex: 1;
}
.lat-meal-info h4 {
    margin: 0 0 4px;
    font-family: 'play', sans-serif;
    font-size: 1.05rem;
    color: #333;
}
.lat-meal-price {
    margin: 0;
    font-size: 1.3rem;
    font-weight: bold;
    color: #800000;
    font-family: 'play', sans-serif;
}
.lat-meal-price small {
    font-size: 0.8rem;
    font-weight: normal;
    color: #666;
}
.lat-meal-toggle {
    min-width: 60px;
    display: flex;
    justify-content: center;
}

/* --- Uczestnik niepełnoletni --- */
.lat-minor-toggle {
    margin-bottom: 20px;
}
.lat-field-inline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    font-family: 'play', sans-serif;
    font-weight: bold;
    font-size: 1rem;
    color: #333;
    cursor: pointer;
}

.lat-subsection {
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
    border: 1px solid #e8e8e8;
    margin-bottom: 20px;
}
.lat-subsection h4 {
    font-family: 'play', sans-serif;
    color: #800000;
    margin: 20px 0 16px;
    font-size: 1.05rem;
}
.lat-subsection h4:first-child {
    margin-top: 0;
}
.lat-subsection h4 i {
    margin-right: 8px;
}

/* --- Boxy informacyjne --- */
.lat-info-box {
    background: #f9f6f0;
    border-left: 4px solid #800000;
    border-radius: 0 8px 8px 0;
    padding: 24px;
    margin-top: 10px;
}
.lat-info-box h4 {
    font-family: 'play', sans-serif;
    color: #800000;
    margin: 0 0 12px;
    font-size: 1.05rem;
}
.lat-info-box h4 i {
    margin-right: 8px;
}
.lat-info-box ul {
    margin: 0;
    padding-left: 20px;
}
.lat-info-box ul li {
    margin-bottom: 10px;
    font-family: 'play', sans-serif;
    font-size: 0.93rem;
    line-height: 1.6;
    color: #444;
}
.lat-info-box a {
    color: #800000;
    font-weight: bold;
    text-decoration: underline;
}
.lat-info-box a:hover {
    color: #a00000;
}

.lat-info-minor {
    background: #fff8f0;
    border-left-color: #e67e22;
}
.lat-info-minor h4 {
    color: #d35400;
}

/* --- Info items w sekcji "Ważne informacje" --- */
.lat-info-item {
    display: flex;
    gap: 16px;
    padding: 20px 0;
    border-bottom: 1px solid #eee;
}
.lat-info-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.lat-info-item:first-child {
    padding-top: 0;
}
.lat-info-icon {
    font-size: 1.6rem;
    color: #800000;
    min-width: 40px;
    text-align: center;
    padding-top: 2px;
}
.lat-info-content {
    flex: 1;
    font-family: 'play', sans-serif;
    font-size: 0.93rem;
    line-height: 1.6;
    color: #444;
}
.lat-info-content p {
    margin: 0 0 8px;
}
.lat-info-content p:last-child {
    margin-bottom: 0;
}
.lat-info-content a {
    color: #800000;
    font-weight: bold;
}
.lat-info-content a:hover {
    color: #a00000;
}

.lat-bank-details {
    background: #f5f0ea;
    border-radius: 8px;
    padding: 16px;
    margin-top: 12px;
}
.lat-bank-details p {
    margin: 0 0 6px;
}
.lat-account-number {
    font-size: 1.05rem;
    letter-spacing: 0.03em;
}

/* --- Checkboxy (zgody) --- */
.lat-checkbox-field {
    margin-bottom: 16px;
}
.lat-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    font-family: 'play', sans-serif;
    font-size: 0.93rem;
    line-height: 1.5;
    color: #444;
    position: relative;
    padding-left: 0;
}
.lat-checkbox input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}
.lat-checkmark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    width: 24px;
    height: 24px;
    border: 2px solid #ccc;
    border-radius: 4px;
    margin-top: 1px;
    transition: all 0.3s ease;
    background: #fafafa;
}
.lat-checkmark::after {
    content: '';
    display: none;
    width: 6px;
    height: 12px;
    border: solid white;
    border-width: 0 2.5px 2.5px 0;
    transform: rotate(45deg);
    margin-top: -2px;
}
.lat-checkbox input:checked ~ .lat-checkmark {
    background: #800000;
    border-color: #800000;
}
.lat-checkbox input:checked ~ .lat-checkmark::after {
    display: block;
}
.lat-checkbox input:focus ~ .lat-checkmark {
    box-shadow: 0 0 0 3px rgba(128, 0, 0, 0.15);
}
.lat-checkbox .req {
    color: #800000;
}

/* --- Przycisk wysyłki --- */
.lat-submit-section {
    text-align: center;
    padding: 20px 0 10px;
}
.lat-submit-btn {
    display: inline-block;
    background: linear-gradient(135deg, #800000 0%, #a00000 100%);
    color: #fff;
    border: none;
    padding: 16px 48px;
    font-size: 1.15rem;
    font-family: 'play', sans-serif;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(128, 0, 0, 0.3);
    letter-spacing: 0.02em;
}
.lat-submit-btn:hover {
    background: linear-gradient(135deg, #a00000 0%, #c00000 100%);
    box-shadow: 0 6px 20px rgba(128, 0, 0, 0.4);
    transform: translateY(-1px);
}
.lat-submit-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(128, 0, 0, 0.3);
}
.lat-submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}
.lat-submit-btn i {
    margin-right: 8px;
}

/* --- Error/Success boxy --- */
.lat-error-box {
    background: #fdf0f0;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    padding: 14px 20px;
    margin-bottom: 20px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: 'play', sans-serif;
    color: #721c24;
    font-size: 0.95rem;
    text-align: left;
}
.lat-error-box i {
    font-size: 1.2rem;
    color: #dc3545;
}

.lat-success-box {
    background: linear-gradient(135deg, #f0fdf4, #dcfce7);
    border: 2px solid #86efac;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    font-family: 'play', sans-serif;
}
.lat-success-box i {
    font-size: 3rem;
    color: #22c55e;
    margin-bottom: 16px;
    display: block;
}
.lat-success-box h3 {
    color: #166534;
    margin: 0 0 10px;
    font-size: 1.4rem;
}
.lat-success-box p {
    color: #15803d;
    font-size: 1rem;
    margin: 0;
}

/* --- Zamknięta rejestracja --- */
.lat-closed-notice {
    background: linear-gradient(135deg, #f9f6f0, #f0ebe0);
    border: 2px solid #d4a574;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    font-family: 'play', sans-serif;
    margin: 20px 0;
}
.lat-closed-notice i {
    font-size: 3rem;
    color: #800000;
    margin-bottom: 16px;
    display: block;
}
.lat-closed-notice h3 {
    color: #800000;
    margin: 0 0 10px;
}
.lat-closed-notice p {
    color: #666;
    font-size: 1rem;
    margin: 0;
}

/* --- Animacje --- */
@keyframes latFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
#lat-minor-fields {
    animation: latFadeIn 0.4s ease;
}

/* --- Nagranie --- */
.lat-nagranie-box {
    background: #f9f6f0;
    border-left: 4px solid #800000;
    border-radius: 0 8px 8px 0;
    padding: 20px 24px;
    margin-bottom: 20px;
}
.lat-nagranie-header {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    margin-bottom: 16px;
}
.lat-nagranie-header i {
    font-size: 1.6rem;
    color: #800000;
    margin-top: 2px;
    min-width: 28px;
}
.lat-nagranie-header h4 {
    font-family: 'play', sans-serif;
    color: #800000;
    margin: 0 0 6px;
    font-size: 1.05rem;
}
.lat-nagranie-header p {
    margin: 0;
    font-family: 'play', sans-serif;
    font-size: 0.93rem;
    color: #555;
    line-height: 1.5;
}
.lat-nagranie-box .lat-field {
    margin-bottom: 0;
}

/* --- Field hint --- */
.lat-field-hint {
    font-family: 'play', sans-serif;
    font-size: 0.88rem;
    color: #666;
    margin: 6px 0 8px;
    font-style: italic;
}

/* --- Pedagogowie --- */
.lat-pedagogow-field > label {
    display: block;
    margin-bottom: 6px;
    font-family: 'play', sans-serif;
    font-weight: bold;
    color: #333;
    font-size: 0.95rem;
}
.lat-pedagogow-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}
.lat-pedagogow-list label.lat-pedagog-option {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    font-family: 'play', sans-serif;
    font-size: 0.95rem;
    font-weight: bold;
    color: #333;
    padding: 10px 14px;
    margin: 0;
    border: 2px solid #e8e8e8;
    border-radius: 6px;
    transition: border-color 0.2s, background-color 0.2s;
}
.lat-pedagogow-list label.lat-pedagog-option:hover {
    border-color: #800000;
    background-color: #fdf5f5;
}
.lat-pedagogow-list label.lat-pedagog-option input[type="checkbox"] {
    width: 20px;
    height: 20px;
    min-width: 20px;
    accent-color: #800000;
    cursor: pointer;
    margin: 0;
    flex-shrink: 0;
}
.lat-pedagogow-list label.lat-pedagog-option input[type="checkbox"]:disabled {
    accent-color: #ccc;
    cursor: not-allowed;
}
.lat-pedagogow-list label.lat-pedagog-option input:disabled ~ span {
    color: #aaa;
    cursor: not-allowed;
}
.lat-pedagogow-list label.lat-pedagog-option > span {
    flex: 1;
    line-height: 1.2;
}

/* --- Daty wyżywienia / noclegu --- */
.lat-meal-dates {
    margin-top: 0;
    border: 2px solid #e0d0d0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    background: #fdf8f8;
    padding: 16px 20px;
}
.lat-dates-intro {
    font-family: 'play', sans-serif;
    font-size: 0.9rem;
    font-weight: bold;
    color: #800000;
    margin-bottom: 12px;
}
.lat-dates-intro i {
    margin-right: 6px;
}
.lat-date-rows {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.lat-date-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 12px;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
}
.lat-date-label {
    font-family: 'play', sans-serif;
    font-size: 0.93rem;
    color: #444;
    flex: 1;
}
.lat-people-select {
    border: 2px solid #ddd;
    border-radius: 6px;
    padding: 6px 10px;
    font-family: 'play', sans-serif;
    font-size: 0.9rem;
    background: #fafafa;
    min-width: 90px;
    cursor: pointer;
    transition: border-color 0.2s;
}
.lat-people-select:focus {
    border-color: #800000;
    outline: none;
}

/* --- Sekcja nocleg --- */
.lat-nocleg-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}
.lat-nocleg-blocked-notice {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 16px;
    padding: 14px 16px;
    border-left: 4px solid #c0392b;
    border-radius: 0 8px 8px 0;
    background: #fff4f2;
    color: #4a2d28;
    font-family: 'play', sans-serif;
    line-height: 1.45;
}
.lat-nocleg-blocked-notice i {
    margin-top: 2px;
    color: #c0392b;
    font-size: 1.2rem;
}
.lat-nocleg-blocked-notice strong {
    display: block;
    margin-bottom: 3px;
    color: #8a1f14;
}
.lat-nocleg-blocked-notice p {
    margin: 0;
}
.lat-nocleg-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    border: 2px solid #e8e8e8;
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.3s, background-color 0.3s;
}
.lat-nocleg-card:hover {
    border-color: #800000;
    background-color: #fdf5f5;
}
.lat-nocleg-card.active {
    border-color: #800000;
    background-color: #fdf5f5;
}
.lat-nocleg-card-disabled,
.lat-nocleg-card-disabled:hover {
    border-color: #e8e8e8;
    background: #f7f7f7;
    cursor: not-allowed;
    opacity: 0.65;
}
.lat-nocleg-card-disabled .lat-nocleg-radio-wrap input[type="radio"] {
    cursor: not-allowed;
}
.lat-nocleg-card-none {
    border-style: dashed;
}
.lat-nocleg-icon {
    font-size: 1.6rem;
    color: #800000;
    min-width: 40px;
    text-align: center;
}
.lat-nocleg-info {
    flex: 1;
}
.lat-nocleg-info h4 {
    margin: 0 0 4px;
    font-family: 'play', sans-serif;
    font-size: 1rem;
    color: #333;
}
.lat-nocleg-price {
    margin: 0;
    font-size: 1.2rem;
    font-weight: bold;
    color: #800000;
    font-family: 'play', sans-serif;
}
.lat-nocleg-price small {
    font-size: 0.8rem;
    font-weight: normal;
    color: #666;
}
.lat-nocleg-radio-wrap {
    min-width: 24px;
    display: flex;
    justify-content: center;
}
.lat-nocleg-radio-wrap input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: #800000;
    cursor: pointer;
}

/* Daty noclegowe */
#lat-nocleg-dates {
    margin-top: 4px;
    border: 2px solid #e0d0d0;
    border-radius: 8px;
    background: #fdf8f8;
    padding: 16px 20px;
    margin-bottom: 16px;
}
.lat-nocleg-date-rows {
    margin-top: 0;
}
.lat-date-checkbox-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    cursor: pointer;
    font-family: 'play', sans-serif;
    font-size: 0.93rem;
    color: #444;
    transition: border-color 0.2s, background-color 0.2s;
    position: relative;
}
.lat-date-checkbox-row:hover {
    border-color: #800000;
    background-color: #fdf5f5;
}
.lat-date-checkbox-row input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}
.lat-date-checkbox-row input:checked ~ .lat-checkmark {
    background: #800000;
    border-color: #800000;
}
.lat-date-checkbox-row input:checked ~ .lat-checkmark::after {
    display: block;
}
.lat-date-checkbox-row small {
    color: #888;
    font-size: 0.85rem;
}

/* Box informacyjny o internacie */
.lat-nocleg-info-box {
    background: #f0f5ff;
    border-left: 4px solid #3a7bd5;
    border-radius: 0 8px 8px 0;
    padding: 16px 20px;
    margin-top: 4px;
    font-family: 'play', sans-serif;
    font-size: 0.93rem;
    color: #444;
    line-height: 1.6;
}
.lat-nocleg-info-box p {
    margin: 0 0 8px;
}
.lat-nocleg-info-box p:last-child {
    margin-bottom: 0;
}
.lat-nocleg-info-box a {
    color: #3a7bd5;
    font-weight: bold;
}
.lat-nocleg-info-box a:hover {
    color: #2a5ba5;
}
.lat-nocleg-info-box i {
    margin-right: 6px;
    color: #3a7bd5;
}
.lat-nocleg-warning {
    color: #c0392b;
    font-weight: bold;
}
.lat-nocleg-warning i {
    color: #c0392b;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .lat-section-body {
        padding: 16px;
    }
    .lat-section-header {
        padding: 12px 16px;
    }
    .lat-section-header h3 {
        font-size: 1.05rem;
    }
    .lat-meal-card {
        flex-wrap: wrap;
        padding: 14px;
    }
    .lat-meal-icon {
        width: auto;
    }
    .lat-info-item {
        flex-direction: column;
        gap: 8px;
    }
    .lat-submit-btn {
        width: 100%;
        padding: 14px 24px;
    }
    .lat-field-inline {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .lat-bank-details {
        padding: 12px;
    }
    .lat-checkbox {
        font-size: 0.88rem;
    }
}
