/* Pulcinu/pieteikumu formas un validacijas stili. */

/* ===== ANIMĀCIJAS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.intro-section,
.pieteikuma-forma-container,
.kontakti-box {
    animation: fadeInUp 0.6s ease forwards;
    opacity: 0;
}

.intro-section { animation-delay: 0.1s; }
.pieteikuma-forma-container { animation-delay: 0.2s; }
.kontakti-box { animation-delay: 0.3s; }

/* ===== MĀCĪBU PIETEIKUMA LAPA ===== */
.macibu-pieteikums-page {
    padding: 60px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    min-height: 100vh;
    position: relative;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 2;
}

/* Atpakaļ saite */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #520505;
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 30px;
    transition: all 0.2s;
    background: white;
    padding: 10px 20px;
    border-radius: 30px;
    border: 1px solid #520505;
    box-shadow: 0 2px 8px rgba(82,5,5,0.1);
}

.back-link:hover {
    background: #520505;
    color: white;
    transform: translateX(-5px);
}

/* Lapas galvene */
.page-header {
    text-align: center;
    margin-bottom: 50px;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: #520505;
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.page-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, #ffcc00, #ffd700);
    border-radius: 2px;
}

.page-subtitle {
    font-size: 1.2rem;
    color: #666;
    max-width: 800px;
    margin: 20px auto 0;
}

.page-success-message {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    max-width: 800px;
    margin: 0 auto 35px;
    padding: 20px 24px;
    background: linear-gradient(135deg, #f3fff5 0%, #e1f7e7 100%);
    border: 1px solid rgba(40, 167, 69, 0.25);
    border-left: 5px solid #28a745;
    border-radius: 18px;
    box-shadow: 0 12px 28px rgba(40, 167, 69, 0.12);
    position: relative;
    z-index: 3;
    transition: opacity 0.4s ease, transform 0.4s ease, max-height 0.4s ease, margin 0.4s ease, padding 0.4s ease;
    max-height: 200px;
    overflow: hidden;
}

.page-success-message.is-hidden {
    opacity: 0;
    transform: translateY(-8px);
    max-height: 0;
    margin-bottom: 0;
    padding-top: 0;
    padding-bottom: 0;
    border-width: 0;
}

.page-success-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #28a745;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.2rem;
    box-shadow: 0 10px 20px rgba(40, 167, 69, 0.2);
}

.page-success-content strong {
    display: block;
    color: #166534;
    font-size: 1.05rem;
    margin-bottom: 6px;
}

.page-success-content p {
    margin: 0;
    color: #285c34;
    line-height: 1.6;
}

/* Ievada sekcija */
.intro-section {
    background: white;
    border-radius: 30px;
    padding: 40px;
    margin-bottom: 40px;
    box-shadow: 0 15px 35px rgba(82,5,5,0.1);
    border: 1px solid rgba(82,5,5,0.1);
    position: relative;
    overflow: hidden;
}

.intro-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background: linear-gradient(180deg, #520505, #ffcc00);
}

.intro-content {
    display: flex;
    align-items: center;
    gap: 40px;
}

.intro-icon {
    width: 100px;
    height: 100px;
    background: #520505;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    flex-shrink: 0;
    box-shadow: 0 15px 30px rgba(82,5,5,0.2);
}

.intro-text {
    flex: 1;
}

.intro-text h2 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #520505;
    margin-bottom: 15px;
}

.intro-text p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #2d3748;
}

/* Pieteikuma forma */
.pieteikuma-forma-section {
    margin-bottom: 50px;
}

.pieteikuma-forma-container {
    background: white;
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(82,5,5,0.1);
    border: 1px solid rgba(82,5,5,0.1);
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.pieteikuma-forma-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background: linear-gradient(180deg, #520505, #ffcc00);
}

.pieteikuma-forma {
    width: 100%;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

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

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #520505;
    margin-bottom: 8px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s;
    background: white;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #ffcc00;
    box-shadow: 0 0 0 3px rgba(255,204,0,0.2);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.error-message {
    color: #dc3545;
    font-size: 0.8rem;
    margin-top: 5px;
}

.form-submit {
    text-align: center;
    margin-top: 20px;
}

.pieteikties-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #520505;
    color: white;
    padding: 14px 35px;
    border-radius: 50px;
    border: none;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.pieteikties-btn:hover {
    background: #7a0f0f;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(82,5,5,0.2);
}

.pieteikties-btn i {
    transition: transform 0.3s;
}

.pieteikties-btn:hover i {
    transform: translateX(5px);
}

/* Kontaktinformācija */
.kontakti-info {
    margin-bottom: 40px;
}

.kontakti-box {
    background: white;
    border-radius: 20px;
    padding: 30px;
    border-left: 5px solid #ffcc00;
    box-shadow: 0 10px 25px rgba(82,5,5,0.1);
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.kontakti-box:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(82,5,5,0.15);
}

.kontakti-box::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(255,204,0,0.1) 0%, transparent 70%);
}

.kontakti-box h3 {
    font-size: 1.3rem;
    color: #520505;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.kontakti-box p {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #2d3748;
    margin-bottom: 8px;
}

.kontakti-box i {
    color: #ffcc00;
    width: 20px;
}

.kontakti-box a {
    color: #520505;
    text-decoration: none;
    transition: color 0.2s;
}

.kontakti-box a:hover {
    color: #7a0f0f;
    text-decoration: underline;
}

/* Responsīvais dizains */
@media (max-width: 768px) {
    .page-title {
        font-size: 2rem;
    }
    
    .intro-content {
        flex-direction: column;
        text-align: center;
    }
    
    .intro-icon {
        width: 80px;
        height: 80px;
        font-size: 2.5rem;
    }
    
    .intro-text h2 {
        font-size: 1.5rem;
    }
    
    .pieteikuma-forma-container {
        padding: 25px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
}

@media (max-width: 576px) {
    .page-success-message {
        flex-direction: column;
        align-items: stretch;
        padding: 18px;
    }

    .page-success-icon {
        width: 40px;
        height: 40px;
    }

    .page-title {
        font-size: 1.8rem;
    }
    
    .page-subtitle {
        font-size: 1rem;
    }
    
    .intro-section {
        padding: 25px;
    }
    
    .intro-icon {
        width: 70px;
        height: 70px;
        font-size: 2rem;
    }
    
    .pieteikuma-forma-container {
        padding: 20px;
    }
    
    .pieteikties-btn {
        width: 100%;
        justify-content: center;
    }
    
    .kontakti-box {
        padding: 20px;
    }
}