/**
 * Contact Page Styles
 * 
 * Provides responsive, accessible styling for the contact form and information.
 * Matches the Teatar za tebe brand identity.
 */

:root {
    --font-title: 'Caveat', 'Poiret One', cursive, sans-serif;
    --font-body: 'Poiret One', 'Caveat', cursive, sans-serif;
}

.contact-page {
    padding: 30px 20px 20px 20px;
    background: linear-gradient(135deg, #ffffff 0%, #ffe6e6 100%);
    display: flex;
    flex-direction: column;
    flex: 1 0 auto;
}

.contact-container {
    max-width: 1200px;
    margin: 0 auto;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Header Section */
.contact-header {
    text-align: center;
    margin-bottom: 20px;
}

.contact-header-image {
    margin-bottom: 15px;
    display: flex;
    justify-content: center;
}

.contact-header-image img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid #dc143c;
    box-shadow: 0 8px 20px rgba(220, 20, 60, 0.3);
    transition: transform 0.3s ease;
}

.contact-header-image img:hover {
    transform: scale(1.05);
}

.contact-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #dc143c;
    margin-bottom: 8px;
    font-family: var(--font-title, 'Caveat', cursive);
    text-shadow: 2px 2px 4px rgba(220, 20, 60, 0.1);
}

.contact-subtitle {
    font-size: 1.1rem;
    color: #c41e3a;
    margin-bottom: 8px;
    font-family: var(--font-body, 'Poiret One', sans-serif);
}

.contact-description {
    font-size: 0.95rem;
    color: #333;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.4;
    font-family: var(--font-body, 'Poiret One', sans-serif);
}

/* Content Layout */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    margin-top: 15px;
    flex: 1;
}

/* Form Wrapper */
.contact-form-wrapper {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

/* Form Groups */
.form-group {
    margin-bottom: 15px;
}

.form-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
    font-family: var(--font-body, 'Poiret One', sans-serif);
}

.required {
    color: #dc143c;
    font-weight: bold;
}

/* Form Controls */
.form-control {
    width: 100%;
    padding: 8px 12px;
    font-size: 0.9rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-family: var(--font-body, 'Poiret One', sans-serif);
    background-color: #f9f9f9;
    box-sizing: border-box;
    /* Fix width calculation with padding and border */
    -webkit-appearance: none;
    /* Remove iOS styling */
    appearance: none;
}

.form-control:focus {
    outline: none;
    border-color: #dc143c;
    box-shadow: 0 0 0 3px rgba(220, 20, 60, 0.1);
    background-color: #ffffff;
    /* Ensure white background on focus */
}

.form-control::placeholder {
    color: #999;
    opacity: 1;
    /* Ensure placeholder is visible */
}

.form-control:hover {
    border-color: #bdc3c7;
}

.form-control.error {
    border-color: #dc143c;
}

.form-control.success {
    border-color: #28a745;
}

textarea.form-control {
    resize: vertical;
    min-height: 60px;
}

/* Error Messages */
.error-message {
    color: #dc143c;
    font-size: 0.875rem;
    margin-top: 5px;
    min-height: 20px;
    display: block;
}

/* Submit Button */
.btn-submit {
    width: 100%;
    padding: 10px 20px;
    font-size: 1rem;
    font-weight: 600;
    color: white;
    background: linear-gradient(135deg, #dc143c 0%, #c41e3a 100%);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-body, 'Poiret One', sans-serif);
    position: relative;
    overflow: hidden;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(220, 20, 60, 0.4);
    background: linear-gradient(135deg, #c41e3a 0%, #a01729 100%);
}

.btn-submit:active {
    transform: translateY(0);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn-submit:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(220, 20, 60, 0.3);
}

.btn-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-loading::after {
    content: '';
    width: 16px;
    height: 16px;
    border: 2px solid white;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Form Messages */
.form-message {
    margin-top: 10px;
    padding: 10px;
    border-radius: 8px;
    font-size: 0.9rem;
    display: none;
    animation: slideIn 0.3s ease;
}

.form-message.success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    display: block;
}

.form-message.error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    display: block;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Contact Information */
.contact-info {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.contact-info h2 {
    font-size: 1.5rem;
    color: #dc143c;
    margin-bottom: 15px;
    font-family: var(--font-title, 'Caveat', cursive);
}

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e0e0e0;
}

.info-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 0;
}

.info-icon {
    font-size: 1.3rem;
    line-height: 1;
}

.info-content h3 {
    font-size: 0.95rem;
    color: #dc143c;
    margin-bottom: 3px;
    font-family: var(--font-body, 'Poiret One', sans-serif);
}

.info-content p,
.info-content a {
    font-size: 0.9rem;
    color: #555;
    text-decoration: none;
    transition: color 0.3s ease;
}

.info-content a:hover {
    color: #dc143c;
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 968px) {
    .contact-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .contact-header h1 {
        font-size: 2.5rem;
    }

    .contact-subtitle {
        font-size: 1.3rem;
    }
}

@media (max-width: 768px) {
    .contact-page {
        padding: 40px 15px;
    }

    .contact-form-wrapper,
    .contact-info {
        padding: 25px;
    }

    .contact-header h1 {
        font-size: 2rem;
    }

    .contact-subtitle {
        font-size: 1.2rem;
    }

    .contact-description {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .contact-header h1 {
        font-size: 1.75rem;
    }

    .contact-subtitle {
        font-size: 1.1rem;
    }

    .form-control {
        padding: 10px 12px;
        font-size: 0.95rem;
    }

    .btn-submit {
        padding: 12px 25px;
        font-size: 1rem;
    }
}

/* Accessibility Enhancements */
@media (prefers-reduced-motion: reduce) {

    .form-control,
    .btn-submit,
    .info-content a {
        transition: none;
    }

    .form-message {
        animation: none;
    }
}

/* Focus visible for keyboard navigation */
.form-control:focus-visible,
.btn-submit:focus-visible {
    outline: 3px solid #dc143c;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .form-control {
        border-width: 3px;
    }

    .btn-submit {
        border: 2px solid white;
    }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
    .contact-page {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d0a0a 100%);
    }

    .contact-form-wrapper,
    .contact-info {
        background: #2a2a2a;
    }

    .contact-header h1,
    .contact-info h2 {
        color: #ff6b6b;
    }

    .contact-subtitle,
    .contact-description,
    .form-label {
        color: #e0e0e0;
    }

    .form-control {
        background-color: #1a1a1a;
        border-color: #dc143c;
        color: white;
    }

    .form-control:focus {
        background-color: #2a2a2a;
    }

    .info-content h3 {
        color: #ff6b6b;
    }

    .info-content p,
    .info-content a {
        color: #b0b0b0;
    }
}