/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family:
        -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu,
        Cantarell, sans-serif;
    line-height: 1.6;
    color: #333333;
    background: #f5f5f5;
    overflow-x: hidden;
}

/* Main Content */
main {
    min-height: calc(100vh - 30rem);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 2rem;
}

/* Contact Page */
.contact-page-container {
    background: transparent;
    width: 100%;
    max-width: 120rem;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-form-wrapper {
    max-width: 60rem;
    width: 100%;
    margin: 0 auto;
    text-align: center;
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.1);
    background: white;
    border-radius: 1.2rem;
    padding: 4rem;
}

.contact-form-header {
    margin-bottom: 3rem;
}

.contact-form-header h1 {
    font-size: 3rem;
    font-weight: 700;
    color: #2c5530;
    margin-bottom: 1rem;
    letter-spacing: 0.1rem;
    text-transform: uppercase;
}

.contact-form-header p {
    font-size: 1.4rem;
    color: #666;
    margin-bottom: 0.6rem;
    line-height: 1.6;
}

.faq-link {
    color: #2c5530;
    text-decoration: underline;
    font-size: 1.4rem;
    transition: color 0.3s ease;
    font-weight: 500;
}

.faq-link:hover {
    color: #1a3d1f;
}

.contact-form-body {
    text-align: left;
}

.contact-form-group {
    margin-bottom: 2.5rem;
    position: relative;
}

.contact-form-group label {
    display: block;
    margin-bottom: 0.8rem;
    font-weight: 600;
    color: #333;
    font-size: 1.6rem;
}

.contact-form-group input,
.contact-form-group textarea {
    width: 100%;
    padding: 1.5rem;
    border: 0.2rem solid #ddd;
    border-radius: 0.4rem;
    font-size: 1.6rem;
    font-family: inherit;
    background: white;
    transition: all 0.3s ease;
    color: #333;
}

.contact-form-group input::placeholder,
.contact-form-group textarea::placeholder {
    color: #999;
}

.contact-form-group input:focus,
.contact-form-group textarea:focus {
    outline: none;
    border-color: #2c5530;
    box-shadow: 0 0 0 0.3rem rgba(44, 85, 48, 0.1);
}

.contact-form-group textarea {
    resize: vertical;
    min-height: 15rem;
}

.contact-error-message {
    color: #e74c3c;
    font-size: 1.2rem;
    margin-top: 0.5rem;
    display: none;
}

.captcha-section {
    margin: 3rem 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.captcha-checkbox {
    width: 2rem;
    height: 2rem;
    cursor: pointer;
}

.captcha-text {
    font-size: 1.4rem;
    color: #333;
}

.captcha-icon {
    width: 4rem;
    height: 4rem;
    background: #2c5530;
    border-radius: 0.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    margin-left: 1rem;
}

/* Cloudflare Turnstile responsive fix */
.cf-turnstile {
    display: flex;
    justify-content: center;
    width: 100%;
}

.contact-submit-btn {
    background: #2c5530;
    color: white;
    border: none;
    padding: 1.8rem 4rem;
    border-radius: 0.4rem;
    font-size: 1.6rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin-top: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1.4;
    min-height: 5.4rem;
    text-transform: uppercase;
    letter-spacing: 0.1rem;
}

.contact-submit-btn:hover {
    background: #1a3d1f;
    transform: translateY(-0.2rem);
    box-shadow: 0 0.4rem 0.8rem rgba(44, 85, 48, 0.3);
}

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

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

.contact-success-message {
    background: #27ae60;
    color: white;
    padding: 1.5rem;
    border-radius: 0.4rem;
    margin-bottom: 2rem;
    display: none;
    text-align: center;
    font-size: 1.4rem;
}

.contact-footer {
    margin-top: 4rem;
    text-align: right;
    font-size: 1.2rem;
    color: #666;
}

/* Loading animation */
.contact-loading {
    display: inline-block;
    width: 2rem;
    height: 2rem;
    border: 0.2rem solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: contactSpin 1s ease-in-out infinite;
    margin-right: 1rem;
}

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

/* Tablet Styles */
@media (max-width: 1024px) {
    main {
        padding: 5rem 2rem;
    }

    .contact-form-wrapper {
        max-width: 70rem;
        padding: 3.5rem;
    }

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

/* Mobile Landscape / Small Tablet */
@media (max-width: 768px) {
    main {
        padding: 4rem 1.5rem;
        min-height: calc(100vh - 20rem);
    }

    .contact-form-wrapper {
        padding: 3rem 2.5rem;
        box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.08);
        border-radius: 0.6rem;
    }

    .contact-form-header {
        margin-bottom: 2.5rem;
    }

    .contact-form-header h1 {
        font-size: 2.4rem;
        letter-spacing: 0.05rem;
    }

    .contact-form-header p {
        font-size: 1.3rem;
    }

    .faq-link {
        font-size: 1.3rem;
    }

    .contact-form-group {
        margin-bottom: 2rem;
    }

    .contact-form-group label {
        font-size: 1.5rem;
        margin-bottom: 0.6rem;
    }

    .contact-form-group input,
    .contact-form-group textarea {
        padding: 1.2rem;
        font-size: 1.5rem;
        border-width: 0.15rem;
    }

    .contact-form-group textarea {
        min-height: 12rem;
    }

    .captcha-section {
        margin: 2.5rem 0;
    }

    .contact-submit-btn {
        padding: 1.5rem 3rem;
        font-size: 1.5rem;
        min-height: 5rem;
    }

    .contact-footer {
        text-align: center;
        margin-top: 3rem;
        font-size: 1.1rem;
    }
}

/* Mobile Portrait */
@media (max-width: 480px) {
    main {
        padding: 3rem 1rem;
        min-height: calc(100vh - 15rem);
    }

    .contact-page-container {
        padding: 0;
    }

    .contact-form-wrapper {
        padding: 2.5rem 1.8rem;
        border-radius: 0.5rem;
        box-shadow: 0 0.3rem 1.5rem rgba(0, 0, 0, 0.1);
    }

    .contact-form-header {
        margin-bottom: 2rem;
    }

    .contact-form-header h1 {
        font-size: 2rem;
        letter-spacing: 0.05rem;
    }

    .contact-form-header p {
        font-size: 1.2rem;
        line-height: 1.5;
    }

    .faq-link {
        font-size: 1.2rem;
        display: inline-block;
        margin-top: 0.5rem;
    }

    .contact-form-group {
        margin-bottom: 1.8rem;
    }

    .contact-form-group label {
        font-size: 1.4rem;
        margin-bottom: 0.5rem;
    }

    .contact-form-group input,
    .contact-form-group textarea {
        font-size: 1.4rem;
        padding: 1.1rem;
        border-radius: 0.3rem;
    }

    .contact-form-group textarea {
        min-height: 10rem;
    }

    .captcha-section {
        margin: 2rem 0;
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
    }

    .cf-turnstile {
        transform: scale(0.9);
        transform-origin: center;
    }

    .contact-submit-btn {
        font-size: 1.4rem;
        padding: 1.4rem 2rem;
        min-height: 4.8rem;
        letter-spacing: 0.08rem;
    }

    .contact-submit-btn:hover {
        transform: none;
    }

    .contact-loading {
        width: 1.6rem;
        height: 1.6rem;
        margin-right: 0.8rem;
    }

    .contact-footer {
        margin-top: 2.5rem;
        font-size: 1rem;
    }
}

/* Very Small Mobile (iPhone SE, etc.) */
@media (max-width: 375px) {
    main {
        padding: 2.5rem 0.8rem;
    }

    .contact-form-wrapper {
        padding: 2rem 1.5rem;
    }

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

    .contact-form-header p {
        font-size: 1.1rem;
    }

    .faq-link {
        font-size: 1.1rem;
    }

    .contact-form-group label {
        font-size: 1.3rem;
    }

    .contact-form-group input,
    .contact-form-group textarea {
        font-size: 1.3rem;
        padding: 1rem;
    }

    .contact-submit-btn {
        font-size: 1.3rem;
        padding: 1.3rem 1.8rem;
    }

    .cf-turnstile {
        transform: scale(0.85);
    }
}

/* Landscape orientation on mobile */
@media (max-width: 768px) and (orientation: landscape) {
    main {
        padding: 2rem 1.5rem;
        min-height: auto;
    }

    .contact-form-wrapper {
        padding: 2rem;
    }

    .contact-form-header {
        margin-bottom: 1.5rem;
    }

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

    .contact-form-group {
        margin-bottom: 1.5rem;
    }

    .contact-form-group textarea {
        min-height: 8rem;
    }
}