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

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #000;
    background-color: #fff;
    padding-top: 100px;
    /* Add padding to account for fixed header */
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
header {
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    height: 100px;
    border-bottom: 2px solid #e8f0eb;
    padding-top: env(safe-area-inset-top, 0px);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    height: 100%;
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
}

.header-flex {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    height: 100px;
    padding: 0 20px;
    gap: 2rem;
    position: relative;
}

.header-left {
    display: flex;
    align-items: center;
    gap: .75rem;
}

.logo {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    z-index: 2;
    /* Remove absolute positioning and transforms for desktop */
    position: static;
    left: unset;
    top: unset;
    transform: none;
    margin: 0;
}

.logo img {
    height: 60px;
    width: auto;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.05);
}

.tagline-container {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    background: linear-gradient(135deg, #f8fafc, #e8f0eb);
    padding: 8px 20px;
    border-radius: 25px;
    box-shadow: 0 2px 8px rgba(23, 95, 66, 0.05);
    z-index: 1;
}

.tagline {
    font-size: 1.1rem;
    color: #175f42;
    font-weight: 600;
    text-transform: capitalize;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

nav {
    flex: 0 0 auto;
    margin-left: auto;
    position: relative;
    z-index: 2;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin: 0;
    padding: 0;
}

nav ul li {
    margin: 0;
}

nav ul li a {
    text-decoration: none;
    color: #000;
    font-weight: 600;
    transition: all 0.3s ease;
    padding: 8px 16px;
    border-radius: 20px;
    position: relative;
    white-space: nowrap;
}

nav ul li a:hover {
    color: #175f42;
    background-color: #e8f0eb;
    transform: translateY(-2px);
}

nav ul li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: #175f42;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

nav ul li a:hover::after {
    width: 80%;
}

.login-btn {
    margin-left: -5.25rem;
    background: #175f42;
    color: #fff;
    padding: 5px 22px;
    border-radius: 25px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s;
    border: none;
    display: inline-block;
}

.login-btn:hover {
    background: #0d3626;
    color: #fff;
    text-decoration: none;
}

/* Hero Section */
.hero {
    padding: 80px 0 60px;
    /* Reduced top padding since body has padding-top */
    background: linear-gradient(135deg, #fff 0%, #e8f0eb 100%);
    text-align: center;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: #175f42;
}

/* Form Styles */
.form-group {
    position: relative;
    margin-bottom: 1.5rem;
    width: 100%;
}

.waiting-list-form {
    max-width: 500px;
    margin: 2rem auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.waiting-list-form .form-group,
.contact-form .form-group {
    width: 100%;
}

input,
textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    background-color: #fff;
    color: #000;
    transition: border-color 0.3s, box-shadow 0.3s;
}

input:focus,
textarea:focus {
    border-color: #175f42;
    outline: none;
    box-shadow: 0 0 0 2px rgba(23, 95, 66, 0.2);
}

.error-message {
    color: #dc3545;
    font-size: 0.875rem;
    position: absolute;
    bottom: -20px;
    left: 0;
    display: none;
}

.form-group.error input,
.form-group.error textarea {
    border-color: #dc3545;
}

.form-group.error .error-message {
    display: block;
}

/* International Telephone Input Styles */
.iti {
    width: 100%;
}

.iti__flag {
    background-image: url("https://cdnjs.cloudflare.com/ajax/libs/intl-tel-input/17.0.8/img/flags.png");
}

@media (-webkit-min-device-pixel-ratio: 2),
(min-resolution: 192dpi) {
    .iti__flag {
        background-image: url("https://cdnjs.cloudflare.com/ajax/libs/intl-tel-input/17.0.8/img/flags@2x.png");
    }
}

button {
    background-color: #175f42;
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s;
    width: auto;
    min-width: 200px;
}

button:hover {
    background-color: #0d3626;
}

button:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}

/* About Section */
.about {
    padding: 80px 0 80px;
    /* Reduced top padding since body has padding-top */
    background-color: #fff;
}

.about-content {
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
}

.about h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: #175f42;
    /* Consistent with hero section */
    font-size: 2.5rem;
}

/* Problems Section */
.problems-section {
    margin-top: 4rem;
}

.problems-section h3 {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: #175f42;
}

.problems-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    padding: 1rem;
}

.problem-card {
    background: #fff;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: left;
}

.problem-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.problem-card i {
    font-size: 2.5rem;
    color: #175f42;
    margin-bottom: 1rem;
}

.problem-card h4 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: #000;
}

.problem-card p {
    color: #666;
    line-height: 1.6;
}

/* Contact Section */
.contact {
    padding: 80px 0;
    background-color: #f8f9fa;
}

.contact h2 {
    text-align: center;
    margin-bottom: 2rem;
}

.contact-wrapper {
    max-width: 600px;
    margin: 0 auto;
}

.contact-form form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

textarea {
    height: 150px;
    resize: vertical;
}

/* Support Chat */
.support-chat {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #175f42;
    color: white;
    border: none;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    min-width: unset;
}

.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 300px;
    height: 400px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    display: none;
}

.chat-window.active {
    display: flex;
    flex-direction: column;
}

.chat-header {
    padding: 15px;
    background-color: #175f42;
    color: white;
    border-radius: 10px 10px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-messages {
    flex-grow: 1;
    padding: 15px;
    overflow-y: auto;
}

.chat-input {
    padding: 15px;
    border-top: 1px solid #ddd;
    display: flex;
    gap: 10px;
}

.chat-input input {
    flex-grow: 1;
}

.chat-input button {
    min-width: unset;
    padding: 8px 12px;
}

/* Message Styles */
.user-message {
    background-color: #175f42;
    color: white;
    padding: 8px 12px;
    border-radius: 15px;
    margin: 5px 0;
    align-self: flex-end;
}

.system-message {
    background-color: #f0f0f0;
    color: #000;
    padding: 8px 12px;
    border-radius: 15px;
    margin: 5px 0;
    align-self: flex-start;
}

/* Footer */
footer {
    background-color: #000;
    color: white;
    padding: 20px 0;
    text-align: center;
}

/* Success/Error Message Animations */
@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

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

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-flex {
        flex-direction: row;
        align-items: flex-start;
        justify-content: flex-start;
        height: 70px;
        padding: 0 10px;
        position: relative;
    }

    .logo {
        margin: 0;
        display: flex;
        align-items: flex-start;
        justify-content: flex-start;
        width: auto;
        z-index: 2;
    }

    .logo img {
        height: 38px;
        margin: 0;
        padding: 0;
    }

    .login-btn {
        margin: 0;
        position: relative;
        z-index: 2;
        padding: 6px 16px;
        font-size: 0.95rem;
        height: 38px;
        display: flex;
        align-items: center;
    }

    .tagline-container {
        position: static;
        margin: 0 auto 0 auto;
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
        left: unset;
        top: unset;
        transform: none;
        margin-top: 0.5rem;
        z-index: 0;
    }

    nav {
        width: 100%;
        margin-left: 0;
        margin-top: 0.5rem;
        justify-content: center;
        position: static;
        z-index: 0;
    }

    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    nav ul li a {
        padding: 6px 12px;
        font-size: 0.9rem;
    }

    header .container {
        flex-direction: column;
        padding: 0.75rem 10px;
        gap: 0;
        height: auto;
        min-height: 70px;
    }

    body {
        padding-top: 110px;
    }
}

@media (max-width: 480px) {
    header .container {
        padding: 0.75rem 15px;
    }

    .logo img {
        height: 45px;
    }

    .tagline {
        font-size: 0.9rem;
        padding: 6px 15px;
    }

    nav ul {
        gap: 0.5rem;
    }

    nav ul li a {
        padding: 5px 10px;
        font-size: 0.85rem;
    }

    body {
        padding-top: 110px;
    }
}

@media (max-width: 900px) {
    .header-flex {
        flex-direction: column;
        align-items: stretch;
        height: auto;
        gap: 0.5rem;
        padding: 1rem 10px;
    }

    .header-left {
        justify-content: center;
        margin-bottom: 0.5rem;
    }

    nav {
        justify-content: center;
        margin-bottom: 0.5rem;
    }

    .login-btn {
        align-self: flex-end;
        margin: 0 0 0.5rem 0;
    }
}

.dashboard-header {
    width: 100%;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 1rem 2rem;
    position: relative;
}

#logout-btn.header-btn {
    background-color: #fff;
    color: #1a1a1a;
    border: 2px solid #1a1a1a;
    border-radius: 6px;
    padding: 0.5rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    margin-right: auto;
}

#logout-btn.header-btn:hover {
    background-color: #1a1a1a;
    color: #fff;
}