/* 
   Cafe Website Design System - One Page Version
*/

:root {
    /* Color Palette */
    --color-coffee-pastel: #C7A17A;
    --color-milk-white: #FAF7F2;
    --color-coffee-dark: #4A2C2A;
    --color-earth: #D9C5A3;
    --color-green: #71816D;
    --color-text-dark: #2C1810;
    --color-white: #FFFFFF;
    --color-bg-light: #FDFBF8;

    /* Fonts */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Poppins', sans-serif;

    /* Spacing & Layout */
    --container-width: 1200px;
    --border-radius: 12px;
    --header-height: 80px;

    /* Transitions */
    --transition-fast: 0.3s ease;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--color-bg-light);
    color: var(--color-text-dark);
    line-height: 1.6;
    padding-top: var(--header-height);
    /* Offset for fixed header */
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--color-coffee-dark);
    font-weight: 700;
}

img {
    max-width: 100%;
    display: block;
    border-radius: var(--border-radius);
    object-fit: cover;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Utilities */
.text-center {
    text-align: center;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--color-coffee-dark);
}

.section-subtitle {
    font-family: var(--font-body);
    color: var(--color-coffee-pastel);
    letter-spacing: 2px;
    text-transform: uppercase;
    font-size: 0.9rem;
    font-weight: 600;
    display: block;
    margin-bottom: 0.5rem;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition-fast);
}

.btn-primary {
    background-color: var(--color-coffee-dark);
    color: var(--color-milk-white);
}

.btn-primary:hover {
    background-color: var(--color-coffee-pastel);
    transform: translateY(-3px);
}

.btn-secondary {
    background-color: transparent;
    border-color: var(--color-coffee-dark);
    /* Ensure visible on light bg */
    color: var(--color-coffee-dark);
}

/* If secondary button is on a dark background/hero, we might need a modifier */
.btn-secondary.btn-light {
    border-color: var(--color-milk-white);
    color: var(--color-milk-white);
}

.btn-secondary:hover {
    background-color: var(--color-coffee-dark);
    color: var(--color-milk-white);
}

/* Header & Nav */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background-color: rgba(250, 247, 242, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--color-coffee-dark);
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    padding: 5px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--color-coffee-pastel);
    transition: var(--transition-fast);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.hamburger {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
}

/* Hero Section */
#home {
    padding-top: 0;
    /* Reset for hero */
    margin-top: calc(-1 * var(--header-height));
    /* Pull up behind header */
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    color: var(--color-milk-white);
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.5));
    z-index: -1;
}

.hero-content {
    max-width: 600px;
}

.hero-content h1 {
    font-size: 3.5rem;
    line-height: 1.2;
    margin-bottom: 20px;
    color: var(--color-milk-white);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    gap: 15px;
}

/* Features Grid (Home) */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-card {
    background: white;
    padding: 20px;
    border-radius: var(--border-radius);
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    transition: var(--transition-fast);
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-card img {
    height: 200px;
    width: 100%;
    margin-bottom: 15px;
}

.feature-badge {
    background: var(--color-coffee-pastel);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    position: absolute;
    top: 10px;
    right: 10px;
}

.card-content {
    position: relative;
}

/* For badge positioning if needed inside */

/* Menu Section */
#menu {
    background-color: var(--color-white);
}

.menu-tabs {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

.tab-btn {
    background: none;
    border: none;
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-text-dark);
    padding: 10px 25px;
    border-radius: 30px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.tab-btn.active,
.tab-btn:hover {
    background-color: var(--color-coffee-pastel);
    color: white;
}

.menu-category {
    display: none;
}

.menu-category.active {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    animation: fadeIn 0.5s ease;
}

.menu-item {
    background: #fff;
    border: 1px solid #eee;
    padding: 20px;
    border-radius: var(--border-radius);
    display: flex;
    gap: 20px;
    align-items: center;
    transition: var(--transition-fast);
}

.menu-item:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.menu-img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    /* Circle images */
    object-fit: cover;
}

.menu-details {
    flex: 1;
}

.menu-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.menu-title {
    font-weight: 700;
    color: var(--color-coffee-dark);
}

.menu-price {
    color: var(--color-coffee-pastel);
    font-weight: 700;
}

.menu-desc {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 10px;
}

.menu-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dietary-icons {
    font-size: 0.8rem;
    color: var(--color-green);
    display: flex;
    gap: 5px;
}

.whatsapp-btn {
    font-size: 0.8rem;
    color: var(--color-coffee-dark);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Reservation Section */
#reservation {
    background-color: var(--color-milk-white);
    padding: 80px 0;
}

.reservation-form-container {
    max-width: 700px;
    margin: 0 auto;
    background: white;
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group.full {
    grid-column: span 2;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 0.9rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: var(--font-body);
}

.form-group textarea {
    resize: vertical;
    height: 100px;
}

/* Gallery Section */
#gallery {
    padding: 80px 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 40px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    height: 300px;
    cursor: pointer;
    border-radius: var(--border-radius);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    transition: transform 0.4s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* Contact & Footer */
#contact {
    background-color: var(--color-coffee-dark);
    color: var(--color-milk-white);
    padding: 80px 0;
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-info h3 {
    color: var(--color-coffee-pastel);
    margin-bottom: 20px;
}

.opening-hours table {
    width: 100%;
    border-collapse: collapse;
}

.opening-hours td {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.map-container {
    height: 100%;
    min-height: 300px;
    border-radius: var(--border-radius);
    overflow: hidden;
}

/* Modal/Lightbox */
#lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

#lightbox.active {
    opacity: 1;
    pointer-events: all;
}

#lightbox img {
    max-height: 90vh;
    max-width: 90vw;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 20px;
        text-align: center;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    }

    .nav-links.active {
        display: flex;
    }

    .hamburger {
        display: block;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
        height: auto;
    }

    .gallery-item {
        height: 250px;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-group.full {
        grid-column: span 1;
    }
}