/* ============================================
   UMOJA WETU - Contact Page Custom Styles
   ============================================ */

/* Contact Hero Section */
.contact-hero-section {
    position: relative;
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #1EB53A;
    padding: 100px 0 60px;
}

.contact-hero-section .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.contact-hero-section .hero-background-flag {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('/assets/img/Flag-of-Tanzania.png');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    z-index: 0;
    filter: blur(3px);
    -webkit-filter: blur(3px);
    animation: flagBackgroundShift 30s ease-in-out infinite;
}

@keyframes flagBackgroundShift {
    0%, 100% { 
        transform: scale(1);
        opacity: 1;
    }
    50% { 
        transform: scale(1.05);
        opacity: 0.95;
    }
}

.contact-hero-section .hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.contact-hero-section .hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 20px;
    color: white;
    text-shadow: 3px 3px 10px rgba(0, 0, 0, 0.7), 0 0 20px rgba(0, 0, 0, 0.5);
    letter-spacing: 4px;
    position: relative;
    display: inline-block;
    animation: titleSlideIn 1s ease-out forwards;
}

.contact-hero-section .hero-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.8), transparent);
    animation: contactUnderlineExpand 1s ease-out 0.5s forwards;
    border-radius: 2px;
}

@keyframes contactUnderlineExpand {
    0% {
        width: 0;
    }
    100% {
        width: 60%;
    }
}

.contact-hero-section .hero-subtitle {
    font-size: 1.3rem;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.95);
    letter-spacing: 2px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.6), 0 0 15px rgba(0, 0, 0, 0.4);
    animation: subtitleFadeIn 1s ease-out 0.3s forwards;
    opacity: 0;
}

@keyframes titleSlideIn {
    0% {
        opacity: 0;
        transform: translateY(-30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes subtitleFadeIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Contact Info Section */
.contact-info-section {
    background: white;
    padding: 80px 0;
}

.contact-info-card {
    background: white;
    padding: 40px 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 100%;
    border-top: 4px solid var(--primary-color, #1EB53A);
    position: relative;
    overflow: hidden;
}

.contact-info-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #1EB53A, #0047AB);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.contact-info-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.contact-info-card:hover::before {
    transform: scaleX(1);
}

.contact-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 25px;
    background: linear-gradient(135deg, #1EB53A, #0047AB);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(30, 181, 58, 0.3);
    transition: all 0.3s ease;
}

.contact-info-card:hover .contact-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 6px 20px rgba(30, 181, 58, 0.4);
}

.contact-icon i {
    font-size: 2rem;
    color: white;
}

.contact-info-card h4 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: var(--text-dark, #2c3e50);
    font-weight: 700;
}

.contact-label {
    color: var(--text-light, #6c757d);
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.contact-link {
    display: inline-block;
    color: #1EB53A;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.contact-link:hover {
    color: #0047AB;
    transform: translateX(5px);
}

/* Contact Form Section */
.contact-form-section {
    background: var(--bg-light, #f8f9fa);
    padding: 100px 0;
}

.contact-intro {
    padding: 20px;
    padding-top: 0;
}

.contact-intro .section-tag {
    display: inline-block;
    padding: 8px 24px;
    background: linear-gradient(135deg, var(--primary-color, #1EB53A), var(--secondary-color, #0047AB));
    color: white;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 3px;
    border-radius: 30px;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
    animation: tagSlideIn 0.8s ease-out forwards;
    opacity: 0;
}

.contact-intro .section-tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: shine 2s infinite;
}

@keyframes tagSlideIn {
    0% {
        opacity: 0;
        transform: translateX(-30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes shine {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

.contact-intro h2 {
    font-size: 3rem;
    font-weight: 800;
    margin-top: 40px;
    margin-bottom: 25px;
    color: var(--text-dark, #2c3e50);
    position: relative;
    display: inline-block;
    animation: h2SlideIn 0.8s ease-out 0.2s forwards;
    opacity: 0;
    letter-spacing: 1px;
    padding-top: 20px;
}

.contact-intro h2::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color, #1EB53A), var(--secondary-color, #0047AB));
    border-radius: 2px;
    animation: underlineGrow 1s ease-out 0.6s forwards;
}

@keyframes h2SlideIn {
    0% {
        opacity: 0;
        transform: translateX(-30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes underlineGrow {
    0% {
        width: 0;
    }
    100% {
        width: 150px;
    }
}

.contact-intro .lead {
    font-size: 1.25rem;
    line-height: 1.8;
    margin-bottom: 20px;
    color: var(--text-dark, #2c3e50);
    font-weight: 500;
}

.contact-intro p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 20px;
    color: var(--text-light, #6c757d);
}

/* Form Card */
.contact-form-wrapper {
    padding: 20px;
}

.form-card {
    background: white;
    padding: 50px 40px;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.form-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #1EB53A, #0047AB);
}

/* Form Styling */
.contact-form {
    margin-top: 20px;
}

.form-group {
    margin-bottom: 25px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-dark, #2c3e50);
    font-weight: 600;
    font-size: 0.95rem;
}

.form-label i {
    margin-right: 8px;
    color: #1EB53A;
    width: 20px;
}

.form-control {
    width: 100%;
    padding: 14px 18px;
    font-size: 1rem;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    transition: all 0.3s ease;
    background: #f8f9fa;
    color: var(--text-dark, #2c3e50);
}

.form-control:focus {
    outline: none;
    border-color: #1EB53A;
    background: white;
    box-shadow: 0 0 0 3px rgba(30, 181, 58, 0.1);
}

.form-control::placeholder {
    color: #adb5bd;
}

select.form-control {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%231EB53A' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 18px center;
    padding-right: 45px;
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* Submit Button */
.btn-submit {
    width: 100%;
    padding: 16px 30px;
    font-size: 1.1rem;
    font-weight: 600;
    color: white;
    background: linear-gradient(135deg, #1EB53A, #0047AB);
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(30, 181, 58, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-submit::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-submit:hover::before {
    left: 100%;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(30, 181, 58, 0.4);
    background: linear-gradient(135deg, #179830, #003d8f);
}

.btn-submit:active {
    transform: translateY(0);
}

.btn-submit i {
    transition: transform 0.3s ease;
}

.btn-submit:hover i {
    transform: translateX(5px);
}

/* Validation Error Styling */
.text-danger {
    display: block;
    margin-top: 5px;
    font-size: 0.85rem;
    color: #dc3545;
}

.form-control.is-invalid {
    border-color: #dc3545;
}

.form-control.is-valid {
    border-color: #28a745;
}

/* Responsive Design */
@media (max-width: 768px) {
    .contact-hero-section {
        min-height: 40vh;
        padding: 80px 0 40px;
    }
    
    .contact-hero-section .hero-title {
        font-size: 2.8rem;
        letter-spacing: 2px;
    }
    
    .contact-hero-section .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .contact-intro h2 {
        font-size: 2.2rem;
    }
    
    .contact-intro .section-tag {
        font-size: 0.75rem;
        padding: 6px 18px;
        letter-spacing: 2px;
    }
    
    .form-card {
        padding: 30px 20px;
    }
    
    .contact-info-card {
        margin-bottom: 20px;
    }
    
    .section-spacing {
        padding: 60px 0;
    }
}

@media (max-width: 576px) {
    .contact-form-section .row {
        flex-direction: column-reverse;
    }
    
    .contact-intro {
        margin-top: 30px;
    }
}

