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

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #f59e0b;
    --text: #1f2937;
    --text-light: #6b7280;
    --bg: #ffffff;
    --bg-alt: #f9fafb;
    --border: #e5e7eb;
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.1);
    --radius: 8px;
    --radius-lg: 12px;
    --container-width: 1200px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: 1rem;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--primary-dark);
}

.text-link {
    color: var(--primary);
    text-decoration: underline;
}

/* Header */
.header {
    position: sticky;
    top: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    z-index: 100;
    box-shadow: var(--shadow);
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text);
    font-weight: 700;
    font-size: 1.25rem;
}

.logo:hover {
    color: var(--primary);
}

.logo svg {
    color: var(--primary);
}

.nav {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: var(--text);
    font-weight: 500;
    transition: color 0.2s;
}

.nav-link:hover {
    color: var(--primary);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text);
    padding: 0.5rem;
}

/* Main Content */
main {
    min-height: 60vh;
}

/* Page Hero */
.page-hero {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f5f7ff 0%, #fef3c7 100%);
    text-align: center;
}

.page-hero h1 {
    margin-bottom: 0.5rem;
}

.lead {
    font-size: 1.25rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

/* Content Sections */
.content-section {
    padding: 4rem 0;
}

.content-section.alt-bg {
    background: var(--bg-alt);
}

/* Hero Section (Homepage) */
.hero {
    padding: 6rem 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-lg);
    padding: 3rem;
    width: 100%;
    max-width: 400px;
    position: relative;
}

.avatar-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
}

/* Avatar color variants */
.avatar-1 { background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%); }
.avatar-2 { background: linear-gradient(135deg, #a18cd1 0%, #fbc2eb 100%); }
.avatar-3 { background: linear-gradient(135deg, #84fab0 0%, #8fd3f4 100%); }
.avatar-4 { background: linear-gradient(135deg, #fccb90 0%, #d57eeb 100%); }

.connection-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    background: 
        linear-gradient(45deg, rgba(255,255,255,0.15) 1px, transparent 1px),
        linear-gradient(-45deg, rgba(255,255,255,0.15) 1px, transparent 1px);
    background-size: 30% 30%;
    background-position: center;
    opacity: 0.5;
}

/* Features Grid */
.features {
    padding: 6rem 0;
}

.features h2 {
    text-align: center;
    margin-bottom: 3rem;
}

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

.feature-card {
    background: var(--bg);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    transition: transform 0.2s, box-shadow 0.2s;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    margin-bottom: 1rem;
    color: var(--primary);
}

.feature-card h3 {
    margin-bottom: 0.5rem;
}

.feature-card p {
    color: var(--text);
    margin-bottom: 0;
}

/* How It Works */
.how-it-works {
    padding: 6rem 0;
    background: var(--bg-alt);
}

.how-it-works h2 {
    text-align: center;
    margin-bottom: 3rem;
}

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

.step {
    text-align: center;
    padding: 2rem;
}

.step-number {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1.5rem;
}

.step h3 {
    margin-bottom: 0.5rem;
}

.step p {
    color: var(--text);
    margin-bottom: 0;
}

/* Stats */
.stats {
    padding: 4rem 0;
    background: var(--primary);
    color: white;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    text-align: center;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1rem;
    opacity: 0.9;
}

.stat {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Testimonials */
.testimonials {
    padding: 6rem 0;
}

.testimonials h2 {
    text-align: center;
    margin-bottom: 3rem;
}

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

.testimonial-card {
    background: var(--bg-alt);
    padding: 2rem;
    border-radius: var(--radius-lg);
    font-style: italic;
}

.testimonial-author {
    margin-top: 1rem;
    font-weight: 600;
    font-style: normal;
    color: var(--text);
}

/* CTA Section */
.cta-section {
    padding: 6rem 0;
    text-align: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.cta-section h2 {
    margin-bottom: 1rem;
}

.cta-section p {
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* CTA Buttons */
.cta-btn {
    display: inline-block;
    padding: 1rem 2rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.cta-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    color: white;
}

.cta-primary {
    background: var(--primary);
}

.cta-large {
    padding: 1.25rem 3rem;
    font-size: 1.125rem;
}

.cta-floating {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--primary);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    transition: all 0.2s;
}

.cta-floating:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
    color: white;
}

.cta-center {
    text-align: center;
    margin: 2rem 0;
}

/* Footer */
.footer {
    background: var(--text);
    color: white;
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand .logo {
    color: white;
    margin-bottom: 1rem;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0;
}

.footer-links h4 {
    margin-bottom: 1rem;
    color: white;
}

.footer-links a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.5rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
}

/* Blog */
.blog-post {
    min-height: 60vh;
}

.blog-header {
    background: linear-gradient(135deg, #f5f7ff 0%, #fef3c7 100%);
    padding: 4rem 0;
    margin-bottom: 3rem;
}

.blog-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: var(--text-light);
}

.blog-category {
    background: var(--primary);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-weight: 500;
}

.blog-date {
    font-size: 0.875rem;
    color: var(--text-light);
}

.blog-header h1 {
    margin-bottom: 0.5rem;
}

.blog-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
}

.blog-body {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0;
}

.blog-body h2 {
    margin-top: 3rem;
}

.blog-body h3 {
    margin-top: 2rem;
}

.blog-body ul, .blog-body ol {
    margin: 1rem 0 1.5rem 1.5rem;
}

.blog-body li {
    margin-bottom: 0.5rem;
}

.blog-body blockquote {
    background: var(--bg-alt);
    padding: 1.5rem;
    border-left: 4px solid var(--primary);
    margin: 1.5rem 0;
    border-radius: 0 var(--radius) var(--radius) 0;
    font-style: italic;
}

.blog-cta {
    margin: 3rem 0;
    text-align: center;
}

.blog-navigation {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

.back-to-blog {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.related-posts {
    margin-top: 2rem;
}

.related-posts h4 {
    margin-bottom: 1rem;
}

.related-posts ul {
    list-style: none;
    margin-left: 0;
}

.related-posts li {
    margin-bottom: 0.5rem;
}

/* Blog Grid (Listing) */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.blog-card {
    background: var(--bg);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.2s;
}

.blog-card:hover {
    transform: translateY(-4px);
}

.blog-image {
    height: 200px;
}

.blog-content {
    padding: 1.5rem;
}

.blog-content h2 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.blog-content h2 a {
    color: var(--text);
    transition: color 0.2s;
}

.blog-content h2 a:hover {
    color: var(--primary);
}

.blog-content p {
    color: var(--text);
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

/* Blog card gradient backgrounds */
.blog-card:nth-child(1) .blog-image {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}
.blog-card:nth-child(2) .blog-image {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}
.blog-card:nth-child(3) .blog-image {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}
.blog-card:nth-child(4) .blog-image {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}
.blog-card:nth-child(5) .blog-image {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}
.blog-card:nth-child(6) .blog-image {
    background: linear-gradient(135deg, #a18cd1 0%, #fbc2eb 100%);
}
.blog-card:nth-child(7) .blog-image {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.read-more {
    display: inline-block;
    margin-top: 0.75rem;
    font-weight: 600;
}

/* Contact */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 3rem;
}

.contact-info h2, .contact-form-wrapper h2 {
    margin-bottom: 1.5rem;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
}

.contact-method {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.contact-icon {
    width: 48px;
    height: 48px;
    background: var(--bg-alt);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    flex-shrink: 0;
}

.contact-method h4 {
    margin-bottom: 0.25rem;
}

.contact-method p {
    margin-bottom: 0;
    color: var(--text);
}

.contact-form {
    background: var(--bg-alt);
    padding: 2rem;
    border-radius: var(--radius-lg);
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* FAQ */
.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-preview {
    max-width: 800px;
    margin: 0 auto;
}

.faq-preview + p {
    text-align: center;
    margin-top: 2rem;
}

.faq-item {
    border-bottom: 1px solid var(--border);
}

.faq-question {
    width: 100%;
    padding: 1.5rem 0;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text);
    text-align: left;
    transition: color 0.2s;
}

.faq-question:hover {
    color: var(--primary);
}

.faq-icon {
    transition: transform 0.2s;
    flex-shrink: 0;
}

.faq-question[aria-expanded="true"] .faq-icon {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.faq-answer p {
    padding-bottom: 1.5rem;
    color: var(--text-light);
}

.faq-item.active .faq-answer {
    max-height: 500px;
}

/* Legal Pages */
.legal-content {
    max-width: 800px;
    margin: 0 auto;
}

.legal-content h2 {
    margin-top: 3rem;
}

.legal-content h2:first-child {
    margin-top: 0;
}

.legal-content ul {
    margin: 1rem 0 1.5rem 1.5rem;
}

.legal-content li {
    margin-bottom: 0.5rem;
}

/* How It Works */
.steps-large {
    max-width: 900px;
    margin: 0 auto;
}

.step-large {
    background: var(--bg-alt);
    padding: 3rem;
    border-radius: var(--radius-lg);
    text-align: center;
    position: relative;
}

.step-icon {
    margin-bottom: 1rem;
    color: var(--primary);
}

.step-large .step-number {
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
}

.step-large h2 {
    margin-bottom: 1rem;
}

.step-details {
    list-style: none;
    margin: 1.5rem 0 0 0;
    padding: 0;
    text-align: left;
}

.step-details li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-light);
}

.step-details li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: bold;
}

.step-connector {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
    color: var(--primary);
}

/* Safety */
.safety-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.safety-card {
    background: var(--bg);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.safety-icon {
    width: 64px;
    height: 64px;
    background: var(--bg-alt);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.safety-card h2 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.safety-card > ul {
    margin: 1rem 0 0 0;
    padding-left: 1.25rem;
}

.emergency-notice {
    background: var(--primary);
    color: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    text-align: center;
    margin-top: 2rem;
}

/* Features Detailed */
.features-detailed {
    max-width: 900px;
    margin: 0 auto;
}

.feature-detailed {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 2rem;
    align-items: start;
    padding: 2rem 0;
    border-bottom: 1px solid var(--border);
}

.feature-detailed:last-child {
    border-bottom: none;
}

.feature-visual {
    color: var(--primary);
}

.feature-info h2 {
    margin-bottom: 0.75rem;
}

.feature-info > ul {
    margin: 1rem 0 0 0;
    padding-left: 1.25rem;
}

/* Stories */
.stories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.story-card {
    background: var(--bg);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    text-align: center;
}

.story-avatar {
    width: 80px;
    height: 80px;
    background: var(--bg-alt);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: var(--primary);
}

.story-card h3 {
    margin-bottom: 0.25rem;
}

.story-label {
    color: var(--primary);
    font-weight: 500;
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.story-meta {
    margin-top: 1.5rem;
    font-size: 0.875rem;
    color: var(--text-light);
}

/* Tips & Principles */
.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.tip-card {
    background: var(--bg-alt);
    padding: 2rem;
    border-radius: var(--radius-lg);
}

.tip-card h3 {
    margin-bottom: 1rem;
}

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

.principle {
    background: var(--bg);
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

/* Values section */
.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.value-card {
    background: var(--bg);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

/* Legal Content */
.legal-content {
    line-height: 1.8;
}

.legal-content ul, .legal-content ol {
    margin: 1rem 0 1.5rem 2rem;
}

.legal-content li {
    margin-bottom: 0.5rem;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    :root {
        --container-width: 100%;
    }

    .nav {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--bg);
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow);
    }

    .nav.active {
        display: flex;
    }

    .nav-link {
        padding: 0.75rem 0;
        border-bottom: 1px solid var(--border);
    }

    .mobile-menu-btn {
        display: block;
    }

    .hero .container,
    .footer-grid,
    .contact-grid,
    .feature-detailed {
        grid-template-columns: 1fr;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .hero {
        padding: 3rem 0;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.5rem; }

    .cta-floating {
        position: static;
        margin: 2rem auto;
        display: block;
        width: fit-content;
    }

    .blog-grid,
    .features-grid,
    .testimonials-grid,
    .stories-grid,
    .tips-grid,
    .safety-grid {
        grid-template-columns: 1fr;
    }

    .page-hero {
        padding: 3rem 0;
    }

    .content-section {
        padding: 3rem 0;
    }

    .step-large {
        padding: 2rem 1.5rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Focus states */
button:focus,
a:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Selection */
::selection {
    background: var(--primary);
    color: white;
}
