/* ===================================
   Zodya Tarot - Main Stylesheet
   Mystical Theme with Purple & Gold
   =================================== */

/* CSS Variables - Color Palette */
:root {
    /* Primary Colors */
    --primary-dark: #0d0515;
    --primary-purple: #1a0a2e;
    --secondary-purple: #2d1b4e;
    --accent-purple: #4a1c6e;

    /* Accent Colors */
    --accent-gold: #d4af37;
    --accent-gold-light: #f4d03f;
    --accent-violet: #8b5cf6;
    --accent-pink: #ec4899;

    /* Text Colors */
    --text-light: #f5f5f5;
    --text-white: #ffffff;
    --text-muted: #a0a0a0;
    --text-gold: #d4af37;

    /* Background Colors */
    --card-bg: rgba(255, 255, 255, 0.05);
    --card-bg-hover: rgba(255, 255, 255, 0.1);
    --glass-bg: rgba(255, 255, 255, 0.03);

    /* Gradients */
    --gradient-mystical: linear-gradient(135deg, #0d0515 0%, #1a0a2e 25%, #2d1b4e 50%, #1a0a2e 75%, #0d0515 100%);
    --gradient-card: linear-gradient(145deg, rgba(74, 28, 110, 0.3) 0%, rgba(13, 5, 21, 0.8) 100%);
    --gradient-gold: linear-gradient(135deg, #d4af37 0%, #f4d03f 50%, #d4af37 100%);

    /* Shadows */
    --shadow-glow: 0 0 40px rgba(139, 92, 246, 0.3);
    --shadow-gold: 0 0 30px rgba(212, 175, 55, 0.3);
    --shadow-card: 0 10px 40px rgba(0, 0, 0, 0.5);

    /* Typography */
    --font-heading: 'Cinzel', serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing */
    --section-padding: 100px 0;
    --container-width: 1200px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* Reset & Base Styles */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background: var(--primary-dark);
    color: var(--text-light);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ===================================
   Navigation Bar
   =================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 15px 0;
    background: rgba(13, 5, 21, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(139, 92, 246, 0.1);
    transition: var(--transition-normal);
}

.navbar.scrolled {
    padding: 10px 0;
    background: rgba(13, 5, 21, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    transition: var(--transition-fast);
}

.navbar-brand:hover {
    transform: scale(1.02);
}

.navbar-logo {
    width: 40px;
    height: 40px;
    border-radius: 10px;
}

.navbar-name {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--accent-gold);
}

.navbar-menu {
    display: flex;
    align-items: center;
    gap: 40px;
}

.navbar-link {
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-light);
    text-decoration: none;
    padding: 8px 0;
    position: relative;
    transition: var(--transition-fast);
}

.navbar-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gold);
    transition: var(--transition-normal);
}

.navbar-link:hover {
    color: var(--accent-gold);
}

.navbar-link:hover::after {
    width: 100%;
}

/* Navbar CTA Button */
.navbar-cta {
    display: flex;
    align-items: center;
    margin-left: 20px;
    transition: var(--transition-fast);
}

.navbar-cta:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

.navbar-badge {
    height: 40px;
    width: auto;
}

/* Mobile Menu Toggle */
.navbar-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}

.navbar-toggle-icon {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-light);
    position: relative;
    transition: var(--transition-fast);
}

.navbar-toggle-icon::before,
.navbar-toggle-icon::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 2px;
    background: var(--text-light);
    transition: var(--transition-fast);
}

.navbar-toggle-icon::before {
    top: -8px;
}

.navbar-toggle-icon::after {
    bottom: -8px;
}

/* Mobile Menu Active State */
.navbar-toggle.active .navbar-toggle-icon {
    background: transparent;
}

.navbar-toggle.active .navbar-toggle-icon::before {
    top: 0;
    transform: rotate(45deg);
}

.navbar-toggle.active .navbar-toggle-icon::after {
    bottom: 0;
    transform: rotate(-45deg);
}

/* Container */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    line-height: 1.2;
    color: var(--text-white);
}

.section-title {
    font-size: clamp(2rem, 5vw, 3rem);
    text-align: center;
    margin-bottom: 15px;
    background: var(--gradient-gold);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 60px;
}

/* Highlight Text */
.highlight {
    background: var(--gradient-gold);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===================================
   Hero Section
   =================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    background: var(--gradient-mystical);
    overflow: hidden;
    padding: 120px 0 80px;
}

/* Animated Stars Background */
.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    z-index: 0;
}

.stars, .stars2, .stars3 {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-repeat: repeat;
    animation: animateStar 50s linear infinite;
}

.stars {
    background: transparent url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="1" fill="white" opacity="0.8"/></svg>') repeat;
    background-size: 100px 100px;
}

.stars2 {
    background: transparent url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="30" cy="70" r="0.5" fill="white" opacity="0.5"/></svg>') repeat;
    background-size: 150px 150px;
    animation-duration: 100s;
}

.stars3 {
    background: transparent url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="70" cy="30" r="0.8" fill="%23d4af37" opacity="0.6"/></svg>') repeat;
    background-size: 200px 200px;
    animation-duration: 150s;
}

@keyframes animateStar {
    from {
        transform: translateY(0);
    }
    to {
        transform: translateY(-100px);
    }
}

/* Hero Content */
.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-text {
    max-width: 600px;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    margin-bottom: 25px;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 35px;
    line-height: 1.8;
}

.hero-cta {
    margin-bottom: 40px;
}

.app-store-link {
    display: inline-block;
    transition: var(--transition-normal);
}

.app-store-link:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

.app-store-badge {
    height: 60px;
    width: auto;
}

/* Hero Stats */
.hero-stats {
    display: flex;
    gap: 40px;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.stat-icon {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.stat-value {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-gold);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Hero Image */
.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.phone-mockup {
    max-width: 100%;
    max-height: 700px;
    width: auto;
    height: auto;
    border-radius: 40px;
    box-shadow: var(--shadow-glow);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* ===================================
   Features Section
   =================================== */
.features {
    padding: var(--section-padding);
    background: var(--primary-dark);
    position: relative;
}

.features::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(to bottom, var(--primary-purple), transparent);
    pointer-events: none;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.feature-card {
    background: var(--gradient-card);
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: 24px;
    overflow: hidden;
    transition: var(--transition-normal);
    cursor: pointer;
}

.feature-card:hover {
    transform: translateY(-10px);
    border-color: var(--accent-gold);
    box-shadow: var(--shadow-gold);
}

.feature-image {
    padding: 30px 30px 0;
    display: flex;
    justify-content: center;
}

.feature-image img {
    max-height: 400px;
    width: auto;
    border-radius: 20px;
}

.feature-content {
    padding: 30px;
    text-align: center;
}

.feature-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 15px;
}

.feature-title {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--text-white);
}

.feature-description {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.7;
}

/* ===================================
   Why Zodya Section
   =================================== */
.why-zodya {
    padding: var(--section-padding);
    background: var(--gradient-mystical);
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.benefit-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    transition: var(--transition-normal);
}

.benefit-card:hover {
    background: var(--card-bg-hover);
    border-color: var(--accent-gold);
    transform: translateY(-5px);
}

.benefit-icon {
    font-size: 3.5rem;
    display: block;
    margin-bottom: 20px;
}

.benefit-title {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--accent-gold);
}

.benefit-description {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* ===================================
   Showcase Section
   =================================== */
.showcase {
    padding: 80px 0;
    background: var(--primary-dark);
}

.showcase-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.showcase-item {
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: var(--transition-normal);
}

.showcase-item:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-glow);
}

.showcase-item img {
    width: 100%;
    height: auto;
    display: block;
}

/* ===================================
   Testimonials Section
   =================================== */
.testimonials {
    padding: var(--section-padding);
    background: var(--gradient-mystical);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.testimonial-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(139, 92, 246, 0.15);
    border-radius: 20px;
    padding: 35px;
    transition: var(--transition-normal);
}

.testimonial-card:hover {
    border-color: var(--accent-gold);
    background: var(--card-bg-hover);
}

/* Make middle card in second row span two columns or center it */
.testimonial-card:nth-child(4) {
    grid-column: 1 / 2;
}

.testimonial-card:nth-child(5) {
    grid-column: 2 / 3;
}

.testimonial-stars {
    margin-bottom: 20px;
    font-size: 1.2rem;
    letter-spacing: 3px;
}

.testimonial-text {
    font-style: italic;
    color: var(--text-light);
    margin-bottom: 25px;
    line-height: 1.8;
    font-size: 0.95rem;
}

.testimonial-author {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.author-name {
    font-family: var(--font-heading);
    color: var(--accent-gold);
    font-weight: 600;
}

.author-location {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ===================================
   App Rating Section
   =================================== */
.app-rating {
    padding: var(--section-padding);
    background: var(--primary-dark);
}

.rating-card {
    background: var(--gradient-card);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 30px;
    padding: 60px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
}

.rating-content {
    flex: 1;
}

.rating-stars {
    font-size: 2rem;
    letter-spacing: 5px;
    margin-bottom: 15px;
}

.rating-score {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: 700;
    color: var(--accent-gold);
    line-height: 1;
    margin-bottom: 10px;
}

.rating-max {
    font-size: 1.5rem;
    color: var(--text-muted);
}

.rating-text {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 5px;
}

.rating-subtext {
    color: var(--text-light);
    font-size: 1.2rem;
}

.rating-badges {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.app-store-badge-large {
    height: 80px;
    width: auto;
}

.qr-code {
    text-align: center;
}

.qr-code img {
    width: 120px;
    height: 120px;
    border-radius: 12px;
    background: white;
    padding: 10px;
}

.qr-code span {
    display: block;
    margin-top: 10px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ===================================
   Final CTA Section
   =================================== */
.final-cta {
    padding: 120px 0;
    background: var(--gradient-mystical);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.final-cta::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.2) 0%, transparent 70%);
    pointer-events: none;
}

.cta-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.cta-subtitle {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 40px;
    position: relative;
    z-index: 1;
}

/* ===================================
   Footer
   =================================== */
.footer {
    padding: 40px 0;
    background: var(--primary-dark);
    border-top: 1px solid rgba(139, 92, 246, 0.2);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-logo {
    width: 45px;
    height: 45px;
    border-radius: 10px;
}

.footer-name {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--accent-gold);
}

.footer-links {
    display: flex;
    gap: 30px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: var(--accent-gold);
}

.footer-copyright {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ===================================
   Scroll Reveal Animations
   =================================== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ===================================
   Responsive Design
   =================================== */

/* Tablets */
@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 50px;
    }

    .hero-text {
        max-width: 100%;
    }

    .hero-stats {
        justify-content: center;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .benefits-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .testimonials-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .testimonial-card:nth-child(5) {
        grid-column: 1 / -1;
        max-width: 400px;
        margin: 0 auto;
    }

    .rating-card {
        flex-direction: column;
        text-align: center;
    }
}

/* Mobile */
@media (max-width: 768px) {
    :root {
        --section-padding: 70px 0;
    }

    /* Mobile Navigation */
    .navbar-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background: rgba(13, 5, 21, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        gap: 30px;
        padding: 60px 40px;
        transition: var(--transition-normal);
        border-left: 1px solid rgba(139, 92, 246, 0.2);
    }

    .navbar-menu.active {
        right: 0;
    }

    .navbar-toggle {
        display: block;
    }

    .navbar-link {
        font-size: 1.2rem;
    }

    .navbar-cta {
        margin-left: 0;
        margin-top: 20px;
    }

    .navbar-badge {
        height: 45px;
    }

    .hero {
        padding: 100px 0 60px;
    }

    .hero-title {
        font-size: 2.2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-stats {
        flex-direction: column;
        gap: 20px;
        align-items: center;
    }

    .stat {
        align-items: center;
        text-align: center;
    }

    .phone-mockup {
        max-height: 500px;
    }

    .benefits-grid {
        grid-template-columns: 1fr;
    }

    .testimonials-grid {
        grid-template-columns: 1fr;
    }

    .testimonial-card:nth-child(4),
    .testimonial-card:nth-child(5) {
        grid-column: auto;
    }

    .showcase-grid {
        grid-template-columns: 1fr;
    }

    .rating-card {
        padding: 40px 25px;
    }

    .rating-score {
        font-size: 3rem;
    }

    .footer-links {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .feature-card {
        border-radius: 20px;
    }

    .feature-image {
        padding: 20px 20px 0;
    }

    .feature-content {
        padding: 20px;
    }

    .feature-icon {
        font-size: 2.5rem;
    }

    .app-store-badge {
        height: 50px;
    }

    .cta-title {
        font-size: 1.8rem;
    }
}

/* ===================================
   TikTok In-App Browser Toast
   =================================== */
.tiktok-toast {
    position: fixed;
    top: 120px;
    left: 50%;
    transform: translateX(-50%) scale(0.9);
    z-index: 10000;
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
}

.tiktok-toast.show {
    opacity: 1;
    transform: translateX(-50%) scale(1);
    pointer-events: auto;
}

.tiktok-toast-bubble {
    position: relative;
    background: #f5f0e8;
    border-radius: 24px;
    padding: 28px 32px;
    max-width: 340px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.tiktok-toast-tail {
    position: absolute;
    top: -20px;
    right: 40px;
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-bottom: 24px solid #f5f0e8;
}

.tiktok-toast-bubble p {
    margin: 0;
    font-size: 22px;
    line-height: 1.5;
    color: #000;
    font-weight: 500;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.tiktok-toast-bubble .tiktok-icon {
    width: 28px;
    height: 28px;
    vertical-align: middle;
    margin: 0 2px;
}

.tiktok-toast-bubble .dots-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 2px solid #000;
    border-radius: 50%;
    font-size: 14px;
    letter-spacing: -1px;
    vertical-align: middle;
    margin: 0 2px;
}

.tiktok-toast-bubble .highlight {
    color: #d63384;
    font-weight: 600;
}

@media (max-width: 480px) {
    .tiktok-toast {
        top: 100px;
        left: 16px;
        right: 16px;
        transform: translateX(0) scale(0.9);
    }

    .tiktok-toast.show {
        transform: translateX(0) scale(1);
    }

    .tiktok-toast-bubble {
        max-width: 100%;
        padding: 24px;
    }

    .tiktok-toast-bubble p {
        font-size: 18px;
    }

    .tiktok-toast-tail {
        right: 30px;
    }
}
