/* Best Vanilla Slice - Styles */

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

:root {
    --custard: #f5d547;
    --custard-light: #fef3c7;
    --pastry: #d4a574;
    --pastry-dark: #8b5a2b;
    --cream: #fffbeb;
    --rich-brown: #4a2c2a;
    --text: #1f2937;
    --text-light: #6b7280;
    --white: #ffffff;
    --shadow: rgba(0, 0, 0, 0.1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: var(--cream);
}

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

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(135deg, rgba(245, 213, 71, 0.85) 0%, rgba(212, 165, 116, 0.85) 100%),
                url('images/hero.png') center/cover no-repeat;
    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='%23ffffff' fill-opacity='0.15'%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.3;
}

.hero-content {
    position: relative;
    z-index: 1;
    padding: 20px;
}

.hero h1 {
    font-size: clamp(2.5rem, 8vw, 5rem);
    font-weight: 800;
    color: var(--rich-brown);
    text-shadow: 2px 2px 0 var(--white);
    margin-bottom: 10px;
}

.hero .tagline {
    font-size: clamp(1rem, 3vw, 1.5rem);
    color: var(--pastry-dark);
    font-weight: 600;
    margin-bottom: 10px;
}

.hero .subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--rich-brown);
    margin-bottom: 30px;
    opacity: 0.9;
}

.cta-button {
    display: inline-block;
    padding: 15px 40px;
    background: var(--rich-brown);
    color: var(--white);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px var(--shadow);
}

.cta-button:hover {
    background: var(--pastry-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--shadow);
}

/* Sticky Navigation */
.sticky-nav {
    position: sticky;
    top: 0;
    background: transparent;
    z-index: 100;
    transition: all 0.3s ease;
}

.sticky-nav.scrolled {
    background: var(--white);
    box-shadow: 0 2px 10px var(--shadow);
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--rich-brown);
}

.sticky-nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

.sticky-nav a {
    text-decoration: none;
    color: var(--rich-brown);
    font-weight: 500;
    transition: color 0.3s;
}

.sticky-nav a:hover {
    color: var(--pastry);
}

/* About Section */
.about {
    padding: 100px 0;
    background: var(--white);
}

.about h2 {
    font-size: 2.5rem;
    color: var(--rich-brown);
    text-align: center;
    margin-bottom: 50px;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 60px;
    align-items: start;
}

.about-text p {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: var(--text);
}

.about-text strong {
    color: var(--rich-brown);
}

.about-stats {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stat {
    background: var(--custard-light);
    padding: 25px;
    border-radius: 15px;
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--rich-brown);
}

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

/* Contenders Section */
.contenders {
    padding: 100px 0;
    background: var(--custard-light);
}

.contenders h2 {
    font-size: 2.5rem;
    color: var(--rich-brown);
    text-align: center;
    margin-bottom: 15px;
}

.section-intro {
    text-align: center;
    color: var(--text-light);
    font-size: 1.1rem;
    margin-bottom: 50px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

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

.town-card {
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 20px var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
}

.town-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px var(--shadow);
}

.town-card.featured {
    border: 3px solid var(--custard);
}

.town-card.champion {
    border: 3px solid #e74c3c;
}

.town-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--rich-brown);
    color: var(--white);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    z-index: 1;
}

.town-image {
    height: 180px;
    overflow: hidden;
}

.town-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.town-card:hover .town-image img {
    transform: scale(1.05);
}

.town-info {
    padding: 25px;
}

.town-info h3 {
    font-size: 1.5rem;
    color: var(--rich-brown);
    margin-bottom: 5px;
}

.town-region {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.town-claim {
    font-style: italic;
    color: var(--pastry-dark);
    font-weight: 500;
    margin-bottom: 15px;
}

.town-description {
    color: var(--text);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.town-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--text-light);
    padding-top: 15px;
    border-top: 1px solid #eee;
}

/* Vote Section */
.vote {
    padding: 100px 0;
    background: var(--white);
}

.vote h2 {
    font-size: 2.5rem;
    color: var(--rich-brown);
    text-align: center;
    margin-bottom: 15px;
}

.vote-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    max-width: 900px;
    margin: 0 auto 30px;
}

.vote-button {
    background: var(--custard-light);
    border: 2px solid transparent;
    border-radius: 15px;
    padding: 30px 20px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.vote-button:hover {
    border-color: var(--custard);
    background: var(--white);
    transform: scale(1.02);
}

.vote-emoji {
    font-size: 2.5rem;
}

.vote-town {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--rich-brown);
}

.vote-count {
    font-size: 0.9rem;
    color: var(--text-light);
}

.vote-notice {
    text-align: center;
    color: var(--text-light);
    font-style: italic;
    font-size: 0.9rem;
}

/* Submit Section */
.submit {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--pastry) 0%, var(--custard) 100%);
}

.submit h2 {
    font-size: 2.5rem;
    color: var(--rich-brown);
    text-align: center;
    margin-bottom: 15px;
}

.submit .section-intro {
    color: var(--rich-brown);
    opacity: 0.9;
}

.submit-form {
    max-width: 600px;
    margin: 0 auto;
    background: var(--white);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 40px var(--shadow);
}

.form-group {
    margin-bottom: 25px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: var(--rich-brown);
    margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--custard);
}

.form-group textarea {
    resize: vertical;
}

.submit-button {
    width: 100%;
    padding: 15px;
    background: var(--rich-brown);
    color: var(--white);
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}

.submit-button:hover {
    background: var(--pastry-dark);
}

.form-notice {
    text-align: center;
    color: var(--text-light);
    font-size: 0.85rem;
    margin-top: 15px;
    font-style: italic;
}

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

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 2fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.footer-brand p {
    opacity: 0.8;
}

.footer-links h4,
.footer-event h4 {
    margin-bottom: 15px;
    font-size: 1rem;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a,
.footer-event a {
    color: var(--white);
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s;
}

.footer-links a:hover,
.footer-event a:hover {
    opacity: 1;
}

.footer-event p {
    opacity: 0.8;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

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

/* Responsive */
@media (max-width: 900px) {
    .about-content {
        grid-template-columns: 1fr;
    }

    .about-stats {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .stat {
        flex: 1;
        min-width: 150px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .sticky-nav ul {
        display: none;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .about-stats {
        flex-direction: column;
    }

    .stat {
        min-width: auto;
    }
}
