/* ===== CSS Variables ===== */
:root {
    --primary-brown: #5D4037;
    --dark-brown: #3E2723;
    --light-brown: #8D6E63;
    --warm-beige: #D7CCC8;
    --bg-cream: #FFF8E7;
    --accent-gold: #FFD54F;
    --accent-green: #81C784;
    --text-primary: #3E2723;
    --text-secondary: #6D4C41;
    --gradient-hero: linear-gradient(135deg, #5D4037 0%, #3E2723 50%, #2E1B14 100%);
}

/* ===== Reset & Base ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-primary);
    background: var(--bg-cream);
    line-height: 1.6;
}

.tamil {
    font-family: 'Noto Sans Tamil', sans-serif;
}

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

/* ===== Navigation ===== */
.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    position: relative;
    z-index: 100;
}

.nav-brand .tamil {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--accent-gold);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.nav-links {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-links a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

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

.btn-nav {
    background: var(--accent-gold) !important;
    color: var(--dark-brown) !important;
    padding: 10px 24px;
    border-radius: 30px;
    font-weight: 600;
}

.btn-nav:hover {
    background: #FFE082 !important;
    transform: translateY(-2px);
}

/* ===== Hero Section ===== */
.hero {
    background: var(--gradient-hero);
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23FFD54F' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 60px 40px 120px;
    position: relative;
    z-index: 10;
    min-height: calc(100vh - 80px);
}

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

.hero-text h1 {
    margin-bottom: 20px;
}

.tamil-title {
    display: block;
    font-family: 'Noto Sans Tamil', sans-serif;
    font-size: 4rem;
    font-weight: 700;
    color: var(--accent-gold);
    text-shadow: 3px 3px 6px rgba(0,0,0,0.3);
    line-height: 1.2;
}

.english-title {
    display: block;
    font-size: 2.5rem;
    font-weight: 600;
    color: rgba(255,255,255,0.95);
    margin-top: 8px;
}

.subtitle {
    font-size: 1.4rem;
    color: var(--accent-gold);
    margin-bottom: 20px;
    font-weight: 500;
}

.description {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.85);
    margin-bottom: 32px;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-primary {
    background: var(--accent-gold);
    color: var(--dark-brown);
    box-shadow: 0 4px 20px rgba(255, 213, 79, 0.4);
}

.btn-primary:hover {
    background: #FFE082;
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(255, 213, 79, 0.5);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid rgba(255,255,255,0.5);
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.1);
    border-color: white;
}

/* ===== Phone Mockup ===== */
.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.phone-mockup {
    transform: perspective(1000px) rotateY(-15deg) rotateX(5deg);
    transition: transform 0.5s ease;
}

.phone-mockup:hover {
    transform: perspective(1000px) rotateY(-5deg) rotateX(2deg);
}

.phone-frame {
    width: 320px;
    height: 200px;
    background: linear-gradient(145deg, #8D6E63, #5D4037, #3E2723);
    border-radius: 20px;
    padding: 16px;
    box-shadow: 
        0 25px 80px rgba(0,0,0,0.5),
        inset 0 2px 4px rgba(255,255,255,0.1);
    border: 3px solid #2E1B14;
}

.game-board-preview {
    background: linear-gradient(135deg, #6D4C41, #4E342E);
    border-radius: 12px;
    padding: 12px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
}

.pit-row {
    display: flex;
    justify-content: space-around;
}

.pit {
    width: 32px;
    height: 36px;
    background: linear-gradient(180deg, #4E342E, #2E1B14);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.5);
}

.pit span {
    color: rgba(255,255,255,0.8);
    font-size: 10px;
    font-weight: 600;
}

.pit.glow {
    box-shadow: 
        inset 0 2px 4px rgba(0,0,0,0.5),
        0 0 15px rgba(129, 199, 132, 0.6);
    border: 2px solid var(--accent-green);
}

.hero-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}

.hero-wave svg {
    display: block;
    width: 100%;
    height: auto;
}

/* ===== Features Section ===== */
.features {
    padding: 100px 0;
    background: var(--bg-cream);
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title .tamil {
    display: block;
    font-size: 1.2rem;
    color: var(--light-brown);
    margin-bottom: 8px;
}

.section-title span:last-child {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-brown);
}

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

.feature-card {
    background: white;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    border: 1px solid rgba(93, 64, 55, 0.1);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 1.3rem;
    color: var(--dark-brown);
    margin-bottom: 12px;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* ===== How to Play Section ===== */
.how-to-play {
    padding: 100px 0;
    background: linear-gradient(180deg, var(--bg-cream), var(--warm-beige));
}

.rules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.rule-step {
    background: white;
    padding: 30px;
    border-radius: 16px;
    text-align: center;
    position: relative;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

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

.rule-step h3 {
    color: var(--dark-brown);
    margin-bottom: 10px;
}

.rule-step p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.video-placeholder {
    background: linear-gradient(135deg, var(--primary-brown), var(--dark-brown));
    border-radius: 20px;
    height: 300px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: transform 0.3s;
}

.video-placeholder:hover {
    transform: scale(1.02);
}

.play-button {
    width: 80px;
    height: 80px;
    background: var(--accent-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--dark-brown);
    margin-bottom: 16px;
    box-shadow: 0 4px 20px rgba(255,213,79,0.4);
}

/* ===== Heritage Section ===== */
.heritage {
    padding: 100px 0;
    background: var(--bg-cream);
}

.heritage-content {
    display: flex;
    align-items: center;
    gap: 60px;
}

.heritage-text {
    flex: 1;
}

.heritage-text h2 .tamil {
    display: block;
    font-size: 1.2rem;
    color: var(--light-brown);
    margin-bottom: 8px;
}

.heritage-text h2 span:last-child {
    display: block;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--dark-brown);
    margin-bottom: 24px;
}

.heritage-text p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.8;
}

.heritage-image {
    flex: 1;
    display: flex;
    justify-content: center;
}

.kolam-pattern {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, var(--primary-brown), var(--dark-brown));
    border-radius: 50%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

.kolam-pattern::before {
    content: '';
    position: absolute;
    inset: 20px;
    border: 3px dashed var(--accent-gold);
    border-radius: 50%;
    animation: spin 20s linear infinite;
}

.kolam-pattern::after {
    content: '🪔';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 4rem;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ===== Download Section ===== */
.download {
    padding: 100px 0;
    background: var(--gradient-hero);
    text-align: center;
}

.section-title.light .tamil {
    color: var(--accent-gold);
}

.section-title.light span:last-child {
    color: white;
}

.download-subtitle {
    color: rgba(255,255,255,0.8);
    font-size: 1.1rem;
    margin-bottom: 40px;
}

.download-buttons {
    margin-bottom: 40px;
}

.store-badge img {
    transition: transform 0.3s;
}

.store-badge:hover img {
    transform: scale(1.05);
}

.app-info {
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
}

.info-item {
    color: white;
}

.info-item strong {
    display: block;
    color: var(--accent-gold);
    font-size: 0.9rem;
    margin-bottom: 4px;
}

.info-item span {
    font-size: 1.1rem;
}

/* ===== Footer ===== */
.footer {
    background: var(--dark-brown);
    padding: 60px 0 30px;
    color: white;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
    gap: 30px;
}

.footer-brand h3 {
    font-family: 'Noto Sans Tamil', sans-serif;
    font-size: 1.5rem;
    color: var(--accent-gold);
    margin-bottom: 4px;
}

.footer-brand p {
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
}

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

.footer-links a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: color 0.3s;
}

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

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
}

/* ===== Responsive ===== */
@media (max-width: 968px) {
    .hero-content {
        flex-direction: column;
        text-align: center;
        padding: 40px 20px 100px;
    }
    
    .tamil-title {
        font-size: 3rem;
    }
    
    .english-title {
        font-size: 2rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .hero-visual {
        margin-top: 40px;
    }
    
    .phone-mockup {
        transform: none;
    }
    
    .heritage-content {
        flex-direction: column;
        text-align: center;
    }
    
    .kolam-pattern {
        width: 200px;
        height: 200px;
    }
}

@media (max-width: 768px) {
    .nav {
        flex-direction: column;
        gap: 20px;
        padding: 16px 20px;
    }
    
    .nav-links {
        gap: 20px;
    }
    
    .phone-frame {
        width: 280px;
        height: 180px;
    }
    
    .pit {
        width: 26px;
        height: 30px;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .rules-grid {
        grid-template-columns: 1fr;
    }
    
    .app-info {
        gap: 30px;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 16px;
    }
}
