:root {
    --primary: #2d5f4f;
    --primary-light: #3d7a63;
    --primary-dark: #1e4237;
    --accent: #d97706;
    --accent-light: #f59e0b;
    --text: #1f2937;
    --text-light: #6b7280;
    --bg-color: #faf8f5;
    --card-bg: #ffffff;
    --shadow: rgba(0, 0, 0, 0.08);
    --shadow-hover: rgba(0, 0, 0, 0.12);
}

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

body {
    font-family: 'DM Sans', sans-serif;
    background-color: var(--bg-color);
    color: var(--text);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    position: relative;
    overflow-x: hidden;
}

.grain-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    z-index: 100;
}

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

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: white;
    padding: 3rem;
    border-radius: 20px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s ease;
    position: relative;
}

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

.modal-header {
    text-align: center;
    margin-bottom: 2rem;
}

.modal-header h2 {
    font-family: 'Crimson Pro', serif;
    font-size: 1.75rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.modal-header p {
    color: var(--text-light);
    font-size: 0.95rem;
}

.email-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 500;
    color: var(--text);
    font-size: 0.9rem;
}

.form-group input[type="email"] {
    padding: 0.875rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
    font-family: 'DM Sans', sans-serif;
    transition: all 0.3s ease;
}

.form-group input[type="email"]:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(45, 95, 79, 0.1);
}

.form-group input[type="email"].error {
    border-color: #ef4444;
}

.error-message {
    color: #ef4444;
    font-size: 0.85rem;
    display: none;
}

.error-message.active {
    display: block;
}

.checkbox-group {
    margin-top: 0.5rem;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 0.85rem;
    color: var(--text-light);
    cursor: pointer;
    line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
    margin-top: 0.25rem;
    width: 18px;
    height: 18px;
    cursor: pointer;
    flex-shrink: 0;
}

.checkbox-label a {
    color: var(--primary);
    text-decoration: underline;
}

.submit-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 1rem 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

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

.submit-btn::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;
}

.submit-btn:hover:not(:disabled) {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(45, 95, 79, 0.3);
}

.submit-btn:hover:not(:disabled)::before {
    left: 100%;
}

.success-message {
    text-align: center;
    padding: 2rem 0;
}

.success-message svg {
    color: #10b981;
    margin-bottom: 1rem;
}

.success-message h3 {
    font-family: 'Crimson Pro', serif;
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.success-message p {
    color: var(--text-light);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    position: relative;
    padding: 8rem 0 6rem;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(-30px, 50px) scale(1.05); }
    66% { transform: translate(30px, -30px) scale(0.95); }
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    animation: fadeInUp 1s ease-out;
}

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

.title {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.title-top,
.title-bottom {
    font-family: 'Crimson Pro', serif;
    font-weight: 700;
    color: white;
    line-height: 1;
}

.title-top {
    font-size: clamp(3rem, 8vw, 5rem);
    animation: slideInLeft 0.8s ease-out;
}

.title-bottom {
    font-size: clamp(3rem, 8vw, 5rem);
    margin-left: 3rem;
    animation: slideInRight 0.8s ease-out 0.2s backwards;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.subtitle {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    font-weight: 400;
    animation: fadeInUp 1s ease-out 0.4s backwards;
}

.wave-divider {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
}

.wave-divider svg {
    display: block;
    width: calc(100% + 1.3px);
    height: 80px;
}

/* Intro Section */
.intro {
    padding: 5rem 0 3rem;
}

.intro-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    animation: fadeInUp 1s ease-out 0.6s backwards;
}

.intro-text h2 {
    font-family: 'Crimson Pro', serif;
    font-size: clamp(2rem, 4vw, 2.5rem);
    color: var(--primary);
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.intro-text p {
    font-size: 1.15rem;
    color: var(--text-light);
    line-height: 1.8;
}

/* Resources Section */
.resources {
    padding: 3rem 0 5rem;
}

.section-title {
    font-family: 'Crimson Pro', serif;
    font-size: clamp(2rem, 4vw, 2.5rem);
    color: var(--primary);
    text-align: center;
    margin-bottom: 3rem;
    font-weight: 600;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.resource-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 20px var(--shadow);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    animation: fadeInUp 0.8s ease-out backwards;
}

.resource-card:nth-child(1) { animation-delay: 0.1s; }
.resource-card:nth-child(2) { animation-delay: 0.2s; }
.resource-card:nth-child(3) { animation-delay: 0.3s; }
.resource-card:nth-child(4) { animation-delay: 0.4s; }

.resource-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.resource-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px var(--shadow-hover);
}

.resource-card:hover::before {
    transform: scaleX(1);
}

.resource-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: white;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.resource-card:hover .resource-icon {
    transform: rotate(5deg) scale(1.05);
}

.resource-content {
    margin-bottom: 1.5rem;
}

.resource-category {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--accent);
    background: rgba(217, 119, 6, 0.1);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    margin-bottom: 1rem;
}

.resource-content h3 {
    font-family: 'Crimson Pro', serif;
    font-size: 1.5rem;
    color: var(--text);
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.resource-content p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.resource-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--text-light);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.meta-item svg {
    opacity: 0.6;
}

.download-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.95rem;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.download-btn.locked {
    background: #6b7280;
}

.download-btn.locked:hover {
    background: #4b5563;
}

.download-btn.unlocked {
    background: var(--primary);
}

.download-btn::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;
}

.download-btn:hover::before {
    left: 100%;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(45, 95, 79, 0.3);
}

.download-btn.unlocked:hover {
    background: var(--primary-dark);
}

.download-btn svg {
    transition: transform 0.3s ease;
}

.download-btn:hover svg {
    transform: translateY(2px);
}

/* CTA Section */
.cta {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    padding: 4rem 0;
    position: relative;
    overflow: hidden;
}

.cta::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
    border-radius: 50%;
}

.cta-content {
    text-align: center;
    position: relative;
    z-index: 2;
    max-width: 700px;
    margin: 0 auto;
}

.cta-content h2 {
    font-family: 'Crimson Pro', serif;
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    color: white;
    margin-bottom: 1rem;
    font-weight: 600;
}

.cta-content p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.7;
}

/* Footer */
footer {
    background: var(--primary-dark);
    padding: 2rem 0;
    text-align: center;
}

footer p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .modal-content {
        padding: 2rem 1.5rem;
    }

    .hero {
        padding: 6rem 0 4rem;
    }

    .title-bottom {
        margin-left: 1.5rem;
    }

    .intro {
        padding: 3rem 0 2rem;
    }

    .resources {
        padding: 2rem 0 3rem;
    }

    .resources-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .cta {
        padding: 3rem 0;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1.25rem;
    }

    .resource-card {
        padding: 1.5rem;
    }

    .title-top,
    .title-bottom {
        font-size: 2.5rem;
    }

    .modal-content {
        width: 95%;
        padding: 1.5rem;
    }
}
