:root {
    --background-color: #FFF9F2;
    --headline-color: #A45A1E;
    --subtext-color: #4F5561;
    --input-bg: #FFFFFF;
    --button-color: #E5A823;
    --button-text: #1A1A1A;
    --border-radius: 0.5rem;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--subtext-color);
    background-color: var(--background-color);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: clamp(1rem, 3vw, 2rem);
}

header {
    text-align: center;
    margin-bottom: clamp(2rem, 5vw, 3rem);
    padding: 0 clamp(1rem, 3vw, 2rem);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 1s ease-out forwards;
}

@keyframes fadeInSlide {
    0% {
        opacity: 0;
        transform: translateX(-20px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(1rem, 3vw, 2rem);
    margin-bottom: clamp(1.5rem, 4vw, 2rem);
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    padding: clamp(0.6rem, 2vw, 0.8rem) clamp(1rem, 4vw, 2rem);
    background: #FFF9F2;
}

.logo {
    max-width: clamp(60px, 8vw, 80px);
    height: auto;
    flex-shrink: 0;
    background: transparent;
    padding: 0;
    animation: fadeInSlide 0.8s ease-out;
}

.tagline {
    color: var(--headline-color);
    font-size: clamp(1.2rem, 3vw, 1.6rem);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    position: relative;
    animation: fadeInSlide 0.8s ease-out 0.3s backwards;
}

.tagline::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    width: 5px;
    background-color: var(--headline-color);
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% {
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(164, 90, 30, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(164, 90, 30, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(164, 90, 30, 0);
    }
}

h1 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: clamp(0.8rem, 2vw, 1rem);
    color: var(--headline-color);
}

.subheading {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--subtext-color);
    margin-bottom: clamp(1.5rem, 3vw, 2rem);
}

.conditions-container {
    display: flex;
    flex-wrap: wrap;
    gap: clamp(0.8rem, 2vw, 1rem);
    justify-content: center;
    margin-bottom: clamp(1.5rem, 3vw, 2rem);
    padding: 0 clamp(1rem, 3vw, 2rem);
}

.condition-pill {
    padding: clamp(0.6rem, 2vw, 0.8rem) clamp(1rem, 3vw, 1.5rem);
    border: 2px solid var(--headline-color);
    border-radius: var(--border-radius);
    background: var(--input-bg);
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    color: var(--subtext-color);
    font-size: clamp(0.9rem, 2vw, 1rem);
    min-width: clamp(120px, 15vw, 140px);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.condition-pill::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(164, 90, 30, 0.1);
    transition: transform 0.6s ease;
    z-index: 0;
}

.condition-pill:hover::before {
    transform: translateX(100%);
}

.condition-pill:hover {
    background: var(--headline-color);
    color: var(--input-bg);
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.condition-pill.selected {
    background: var(--headline-color);
    color: var(--input-bg);
    animation: pulse 1.5s ease-in-out;
}

.subscription-section {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    padding: 0 clamp(1rem, 3vw, 2rem);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 1s ease-out 0.3s forwards;
    position: relative;
}

.email-form {
    display: flex;
    flex-direction: column;
    gap: clamp(0.8rem, 2vw, 1rem);
    margin-bottom: clamp(0.8rem, 2vw, 1rem);
}

.input-group {
    flex: 1;
    display: flex;
}

.email-input {
    flex: 1;
    padding: clamp(0.6rem, 2vw, 0.8rem) clamp(0.8rem, 2vw, 1rem);
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-size: clamp(0.9rem, 2vw, 1rem);
    background: var(--input-bg);
    width: 100%;
}

.phone-input-group {
    display: flex;
    gap: clamp(0.4rem, 1vw, 0.5rem);
    width: 100%;
}

.country-code {
    padding: clamp(0.6rem, 2vw, 0.8rem);
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    background: var(--input-bg);
    font-size: clamp(0.9rem, 2vw, 1rem);
    cursor: pointer;
    min-width: clamp(100px, 12vw, 120px);
}

.phone-input {
    flex: 1;
    padding: clamp(0.6rem, 2vw, 0.8rem) clamp(0.8rem, 2vw, 1rem);
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-size: clamp(0.9rem, 2vw, 1rem);
    background: var(--input-bg);
}

.send-button {
    padding: clamp(0.6rem, 2vw, 0.8rem) clamp(1.5rem, 4vw, 2rem);
    background: var(--button-color);
    color: var(--button-text);
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    width: 100%;
    font-size: clamp(0.9rem, 2vw, 1rem);
}

.send-button:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    animation: bounce 0.6s ease-in-out;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.support-text {
    color: var(--subtext-color);
    font-size: clamp(0.9rem, 2vw, 1.2rem);
    margin: 0.5rem 0;
    padding: clamp(0.5rem, 1.5vw, 0.8rem) clamp(1rem, 2vw, 1.5rem);
    border-radius: var(--border-radius);
    background: rgba(255, 255, 255, 0.5);
    display: inline-block;
    width: 100%;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.support-text::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.9);
    border-left: 3px solid var(--headline-color);
    animation: typing 3s steps(40, end) forwards;
}

@keyframes typing {
    to {
        width: 0;
    }
}

.support-text strong {
    color: var(--headline-color);
    font-size: clamp(1rem, 2vw, 1.3rem);
    font-weight: 700;
    text-decoration-thickness: 2px;
    padding: 0 0.2rem;
}

.message {
    padding: clamp(0.8rem, 2vw, 1rem);
    margin: clamp(0.8rem, 2vw, 1rem) 0;
    border-radius: var(--border-radius);
    text-align: center;
    font-size: clamp(0.9rem, 2vw, 1rem);
}

.message.error {
    color: #dc3545;
    background-color: #f8d7da;
}

.message.success {
    color: #28a745;
    background-color: #d4edda;
}

/* Status Display for Debugging */
.status-display {
    margin-top: 2rem;
    padding: 1rem;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    background-color: #f8f9fa;
    max-height: 300px;
    overflow-y: auto;
    display: none; /* Hidden by default */
}

.status-display h3 {
    margin-bottom: 0.5rem;
    color: var(--headline-color);
    font-size: 1rem;
}

.instructions {
    margin-top: 1rem;
    padding: 1rem;
    background-color: #fff3cd;
    border: 1px solid #ffeeba;
    border-radius: var(--border-radius);
}

.instructions h4 {
    color: #856404;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.instructions ol {
    margin-left: 1.2rem;
    font-size: 0.85rem;
}

.instructions ul {
    margin-left: 1.2rem;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.instructions li {
    margin-bottom: 0.3rem;
}

.instructions code {
    background-color: #f8f9fa;
    padding: 0.1rem 0.3rem;
    border-radius: 3px;
    font-family: monospace;
    font-size: 0.8rem;
}

.sql-code {
    background-color: #2b2b2b;
    color: #e6e6e6;
    padding: 1rem;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.8rem;
    white-space: pre-wrap;
    overflow-x: auto;
    margin: 0.5rem 0;
    line-height: 1.4;
}

#status-log {
    font-family: monospace;
    font-size: 0.8rem;
    white-space: pre-wrap;
    margin: 0;
    color: #333;
}

/* Show the status display when debugging is needed */
.debug-mode .status-display {
    display: block;
}

/* Confetti Animation */
.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    background-color: var(--button-color);
    top: -10px;
    z-index: 10;
    opacity: 0.8;
    border-radius: 0;
    animation: fall linear forwards;
}

@keyframes fall {
    0% {
        top: -10px;
        transform: translateX(0) rotate(0deg);
        opacity: 1;
    }
    
    25% {
        opacity: 0.9;
        transform: translateX(30px) rotate(45deg);
    }
    
    50% {
        opacity: 0.8;
        transform: translateX(-30px) rotate(90deg);
    }
    
    75% {
        opacity: 0.7;
        transform: translateX(30px) rotate(135deg);
    }
    
    100% {
        top: 100%;
        transform: translateX(-30px) rotate(180deg);
        opacity: 0;
    }
}

@media (max-width: 768px) {
    .logo-container {
        padding: 0.6rem 1rem;
    }

    .logo {
        max-width: 60px;
    }

    .tagline {
        font-size: 1.2rem;
    }

    .conditions-container {
        flex-direction: column;
        align-items: stretch;
    }

    .email-form {
        padding: 0 1rem;
    }

    .phone-input-group {
        flex-direction: column;
    }

    .country-code {
        width: 100%;
        min-width: unset;
    }

    .phone-input {
        width: 100%;
    }

    h1 {
        font-size: 2rem;
    }

    .subscription-section {
        padding: 0 1rem;
    }

    .support-text {
        font-size: 0.9rem;
        padding: 0.8rem 1rem;
        flex-wrap: wrap;
    }

    .support-text strong {
        font-size: 1rem;
    }

    .condition-pill {
        width: 100%;
        min-width: unset;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .email-form {
        padding: 0 1rem;
    }

    .conditions-container {
        gap: 0.8rem;
    }

    .condition-pill {
        min-width: 120px;
    }
}

@media (hover: none) {
    .condition-pill:hover {
        transform: none;
    }

    .send-button:hover {
        transform: none;
    }
} 