/* CSS Variables & Design Tokens */
:root {
    /* Branding Colors */
    --primary-color: #FF4B7D;
    --primary-hover: #E63D6C;
    --accent-light: #FFE5EE;
    --accent-gray: #F7F7FB;

    /* Text Colors */
    --text-main: #1A1A1A;
    --text-muted: #666666;
    --text-light: #FFFFFF;

    /* Backgrounds & Borders */
    --bg-main: #FFFFFF;
    --bg-card: #FFFFFF;
    --border-color: #E2E8F0;

    /* Typography */
    --font-family: 'Outfit', sans-serif;

    /* Shadows & Layout */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 12px 32px rgba(255, 75, 125, 0.15);
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;
    --border-radius-pill: 9999px;

    /* Spacing */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;
    --spacing-3xl: 64px;

    /* Layout constraints */
    --max-width: 1200px;
    --header-height: 70px;
}

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

html {
    font-family: var(--font-family);
    color: var(--text-main);
    background-color: var(--bg-main);
    scroll-behavior: smooth;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    cursor: pointer;
    font-family: inherit;
    border: none;
    background: none;
}

/* Typography Utility */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 600;
    line-height: 1.2;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: var(--spacing-sm);
}

h2 {
    font-size: 2rem;
    margin-bottom: var(--spacing-md);
}

h3 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-sm);
}

p {
    margin-bottom: var(--spacing-md);
}

/* Global Layout */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

.app-main {
    flex: 1;
    padding-top: var(--header-height);
    /* For sticky header */
}

/* Section Spacing */
.section {
    padding: var(--spacing-3xl) 0;
}

.section-light {
    background-color: var(--accent-gray);
}

.section-title {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

/* Global Header */
.global-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 100;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
}

.header-container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -0.5px;
}

/* Navigation Menu */
.main-nav {
    display: none;
    /* Mobile first: hide */
}

.nav-list {
    display: flex;
    gap: var(--spacing-lg);
}

.nav-link {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-main);
    transition: color 0.2s ease;
}

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

.mobile-menu-toggle {
    display: block;
    color: var(--text-main);
}

/* Global Footer */
.global-footer {
    background-color: var(--text-main);
    color: var(--text-light);
    padding: var(--spacing-2xl) 0 var(--spacing-xl);
    margin-top: auto;
}

.footer-container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
}

.footer-section h3 {
    color: var(--accent-light);
    font-size: 1.1rem;
    margin-bottom: var(--spacing-md);
}

.footer-section p {
    color: #CCCCCC;
    font-size: 0.9rem;
    margin-bottom: var(--spacing-sm);
}

.footer-section a {
    color: var(--accent-light);
}

.footer-section a:hover {
    text-decoration: underline;
}

.meta-info {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--spacing-lg);
    text-align: center;
    color: #999999;
}

.payment-note {
    font-size: 0.8rem;
    margin-top: var(--spacing-xs);
}

/* Loading & Empty States */
.loader-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-3xl) 0;
    color: var(--text-muted);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--accent-light);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: var(--spacing-md);
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Mobile Nav Overlay Wrapper */
@media (max-width: 768px) {
    .main-nav {
        position: absolute;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background-color: var(--bg-main);
        box-shadow: var(--shadow-md);
        padding: var(--spacing-lg);
        display: none;
        /* Toggled via JS */
        flex-direction: column;
        border-bottom: 1px solid var(--border-color);
    }

    .main-nav.is-open {
        display: flex;
    }

    .nav-list {
        flex-direction: column;
        gap: var(--spacing-md);
    }

    .nav-link {
        display: block;
        padding: var(--spacing-sm) 0;
        font-size: 1.1rem;
    }
}

/* Desktop Defaults */
@media (min-width: 769px) {
    .mobile-menu-toggle {
        display: none;
    }

    .main-nav {
        display: block;
    }

    .footer-container {
        grid-template-columns: 1fr 1fr;
        align-items: start;
    }

    .meta-info {
        text-align: right;
        border-top: none;
        padding-top: 0;
    }

    h1 {
        font-size: 3.5rem;
    }

    h2 {
        font-size: 2.5rem;
    }
}

/* Button Component CSS */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-weight: 600;
    font-size: 1rem;
    border-radius: var(--border-radius-pill);
    transition: all 0.2s ease;
    text-align: center;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn-lg {
    padding: 16px 32px;
    font-size: 1.1rem;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--text-light);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--accent-light);
}

.btn-block {
    width: 100%;
}

/* Hero Section */
.hero-section {
    position: relative;
    background-image: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.3)), url('https://images.unsplash.com/photo-1563241527-3004b7be0ffd?auto=format&fit=crop&q=80&w=1200&h=800');
    background-size: cover;
    background-position: center;
    color: var(--text-light);
    padding: var(--spacing-3xl) 0;
    min-height: 60vh;
    display: flex;
    align-items: center;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    color: white;
    margin-bottom: var(--spacing-md);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-xl);
    font-weight: 300;
    color: rgba(255, 255, 255, 0.9);
}

.hero-badges {
    margin-top: var(--spacing-xl);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    align-items: center;
}

.badge {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(4px);
    padding: 6px 16px;
    border-radius: var(--border-radius-pill);
    font-size: 0.85rem;
    display: inline-block;
}

@media (min-width: 768px) {
    .hero-badges {
        flex-direction: row;
        justify-content: center;
    }
}

/* Filter Chips */
.filter-chips-wrapper {
    margin-bottom: var(--spacing-xl);
    width: 100%;
    overflow: hidden;
}

.filter-chips-container {
    display: flex;
    gap: var(--spacing-sm);
    overflow-x: auto;
    padding-bottom: var(--spacing-sm);
    -webkit-overflow-scrolling: touch;
}

.filter-chips-container::-webkit-scrollbar {
    display: none;
}

.filter-chip {
    padding: 8px 20px;
    border-radius: var(--border-radius-pill);
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 500;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.filter-chip:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.filter-chip.active {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Product Cards Grid */
.product-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
}

@media (min-width: 480px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--spacing-lg);
    }
}

@media (min-width: 1024px) {
    .product-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Modern Product Cards */
.product-card {
    background-color: var(--bg-card);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-color);
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.product-card__image {
    display: block;
    position: relative;
    aspect-ratio: 4/5;
    overflow: hidden;
    background-color: var(--accent-gray);
}

.product-card__image img,
.product-card__image .placeholder-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.product-card:hover .product-card__image img {
    transform: scale(1.04);
}

.product-card__badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 6px 12px;
    border-radius: var(--border-radius-pill);
    font-size: 0.75rem;
    font-weight: 700;
    z-index: 2;
    box-shadow: var(--shadow-sm);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-card__badge.bestseller {
    background-color: #FFD700;
    color: #000;
}

.product-card__badge.occasion {
    background-color: #FFF9C4;
    color: #F57F17;
}

.product-card__content {
    padding: var(--spacing-md);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-card__title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: var(--spacing-xs);
    line-height: 1.3;
}

.product-card__title a {
    color: var(--text-main);
}

.product-card__title a:hover {
    color: var(--primary-color);
}

.product-card__desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-md);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
}

.product-card__price-row {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: var(--spacing-sm);
    border-top: 1px solid var(--border-color);
}

.product-card__price {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--primary-color);
}

.product-card__btn {
    font-weight: 600;
    border-radius: 8px;
    padding: 8px 16px;
}

/* Steps (How it works) */
.steps-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
}

@media (min-width: 768px) {
    .steps-container {
        grid-template-columns: repeat(3, 1fr);
    }
}

.step-item {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-md);
    background: var(--bg-card);
    padding: var(--spacing-xl);
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-sm);
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--accent-light);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.step-title {
    font-size: 1.1rem;
    margin-bottom: var(--spacing-xs);
}

.step-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 0;
}

/* Bouquet Detail */
.detail-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
}

@media (min-width: 768px) {
    .detail-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--spacing-3xl);
    }
}

.detail-image-wrapper {
    border-radius: var(--border-radius-md);
    overflow: hidden;
}

.detail-image {
    width: 100%;
    aspect-ratio: 4/5;
    object-fit: cover;
}

.detail-title {
    margin-bottom: var(--spacing-xs);
}

.detail-price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-main);
}

.detail-desc {
    font-size: 1.1rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.detail-badge {
    background-color: var(--accent-light);
    color: var(--primary-color);
    padding: 6px 12px;
    border-radius: var(--border-radius-pill);
    font-size: 0.85rem;
    font-weight: 600;
    margin-right: 8px;
    display: inline-block;
    margin-bottom: 8px;
}

.promise-list {
    padding-left: var(--spacing-lg);
    color: var(--text-muted);
    list-style-type: disc;
}

.promise-list li {
    margin-bottom: var(--spacing-xs);
}

.local-promise-box {
    background-color: var(--accent-gray);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-md);
    border: 1px solid var(--border-color);
}

.local-promise-box h4 {
    margin-bottom: var(--spacing-sm);
    color: var(--text-main);
    font-size: 1.1rem;
}

/* Forms */
.order-form-container {
    background-color: var(--bg-card);
    padding: var(--spacing-xl);
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
}

.form-title {
    margin-bottom: var(--spacing-lg);
    padding-bottom: var(--spacing-sm);
    border-bottom: 1px solid var(--border-color);
}

.form-group {
    margin-bottom: var(--spacing-md);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
}

@media (min-width: 480px) {
    .form-row {
        grid-template-columns: 1fr 1fr;
    }
}

label {
    display: block;
    font-weight: 500;
    margin-bottom: var(--spacing-xs);
    font-size: 0.95rem;
}

.required {
    color: red;
}

input[type="text"],
input[type="tel"],
input[type="date"],
select,
textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s;
    background-color: #FAFAFA;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background-color: white;
}

.radio-group {
    display: flex;
    gap: var(--spacing-lg);
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: normal;
}

.form-note {
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: var(--spacing-md);
    margin-bottom: 0;
}

/* Mobile Sticky CTA */
.mobile-sticky-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: white;
    padding: var(--spacing-md) var(--spacing-lg);
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    border-top: 1px solid var(--border-color);
}

.sticky-price-row flex {
    display: flex;
    flex-direction: column;
}

@media (min-width: 768px) {
    .mobile-sticky-cta {
        display: none;
    }

    .app-main {
        padding-bottom: 0;
    }
}

/* Page specific */
.page-header {
    padding: var(--spacing-2xl) 0 var(--spacing-lg);
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.about-contact-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-xl);
}

@media (min-width: 768px) {
    .about-contact-container {
        grid-template-columns: 1fr 1fr;
    }
}

.about-card,
.contact-card {
    background: white;
    padding: var(--spacing-xl);
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-sm);
}

.highlight-stats {
    margin-top: var(--spacing-md);
}

.highlight-stats li {
    margin-bottom: var(--spacing-sm);
    color: var(--text-main);
    font-weight: 500;
}

/* Placeholder and Instagram Link Styles */
.placeholder-image {
    background-color: var(--accent-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-weight: 500;
}

.ig-link {
    transition: color 0.2s ease;
}

.ig-link:hover,
.ig-link svg:hover {
    color: var(--primary-color);
}

/* Premium Voucher Popup */
.voucher-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
    padding: var(--spacing-lg);
}

.voucher-overlay.show {
    opacity: 1;
    visibility: visible;
}

.voucher-card {
    background: #FFFBFB;
    border-radius: var(--border-radius-lg);
    padding: var(--spacing-3xl) var(--spacing-2xl);
    text-align: center;
    max-width: 420px;
    width: 100%;
    box-shadow: 0 24px 48px rgba(255, 75, 125, 0.25), 0 0 0 1px rgba(255, 215, 0, 0.15), 0 0 20px rgba(255, 182, 193, 0.3) inset;
    border: 2px solid rgba(255, 215, 0, 0.4); /* subtle gold glowing border */
    position: relative;
    transform: translateY(100px);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.voucher-overlay.show .voucher-card {
    transform: translateY(0);
}

.voucher-title {
    font-size: 1.6rem;
    color: var(--text-main);
    margin-bottom: var(--spacing-sm);
    font-weight: 700;
}

.voucher-subtitle {
    font-size: 1.15rem;
    color: var(--text-muted);
    margin-bottom: var(--spacing-xl);
}

.voucher-code-box {
    border: 2px dashed var(--primary-color);
    background: var(--accent-light);
    color: var(--primary-color);
    font-size: 1.6rem;
    font-weight: 700;
    padding: var(--spacing-md);
    border-radius: var(--border-radius-sm);
    margin-bottom: var(--spacing-xl);
    letter-spacing: 2px;
}