/* ============================================
   Modern Loaf - Premium Bread Website
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
    --cream: #FAF7F2;
    --cream-alt: #F0EBE3;
    --white: #FFFFFF;
    --text: #2D2420;
    --text-light: #7A6E65;
    --accent: #C16A3F;
    --accent-hover: #A8552E;
    --accent-light: #E8C4A8;
    --accent-pale: #FDF3EB;
    --sage: #8B9D83;
    --sage-light: #E8EDE5;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.04);
    --shadow: 0 2px 16px rgba(0,0,0,0.05);
    --shadow-lg: 0 8px 40px rgba(0,0,0,0.07);
    --shadow-xl: 0 16px 64px rgba(0,0,0,0.09);
    --radius-sm: 8px;
    --radius: 16px;
    --radius-lg: 24px;
    --radius-xl: 32px;
    --nav-height: 80px;
    --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--cream);
    color: var(--text);
    line-height: 1.7;
    overflow-x: hidden;
    font-weight: 400;
    font-size: 16px;
}

h1, h2, h3, h4, h5 {
    font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

h1 { font-size: clamp(3rem, 6vw, 5.5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.2rem); }
h3 { font-size: clamp(1.4rem, 2.5vw, 1.8rem); }

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition);
}

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

.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 32px;
}

/* --- Navigation --- */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: rgba(250, 247, 242, 0.75);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    border-bottom: 1px solid rgba(0,0,0,0.04);
    transition: background var(--transition), box-shadow var(--transition);
}

.nav.scrolled {
    background: rgba(250, 247, 242, 0.92);
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.01em;
}

.nav-logo img {
    height: 44px;
    width: auto;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
}

.nav-links a {
    font-size: 0.875rem;
    font-weight: 500;
    padding: 10px 18px;
    border-radius: 100px;
    color: var(--text-light);
    transition: all var(--transition);
    letter-spacing: 0.01em;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text);
    background: var(--cream-alt);
}

.nav-links a.cta-nav {
    background: var(--accent);
    color: var(--white);
    font-weight: 600;
    margin-left: 8px;
}

.nav-links a.cta-nav:hover {
    background: var(--accent-hover);
    color: var(--white);
}

/* Mobile menu toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: var(--transition);
}

.nav-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* --- Hero Section --- */
.hero {
    min-height: 75vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding-top: var(--nav-height);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: url('../images/Banana banner.jpg') center/cover no-repeat;
    filter: brightness(0.55) saturate(0.9);
    transform: scale(1.05);
    transition: transform 8s ease-out;
}

.hero:hover .hero-bg {
    transform: scale(1.1);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(45, 36, 32, 0.2) 0%,
        rgba(45, 36, 32, 0.5) 50%,
        rgba(45, 36, 32, 0.7) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: var(--white);
    max-width: 800px;
    padding: 0 32px;
}

/* Longer hero headlines (e.g. "Probably the Best Banana Bread...") */
.hero-title-long {
    font-size: clamp(1.8rem, 4.5vw, 3.5rem) !important;
}

.hero-badge {
    display: inline-block;
    background: rgba(255,255,255,0.12);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.18);
    padding: 8px 20px;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 32px;
    animation: fadeUp 0.8s var(--transition-slow) both;
}

.hero-title {
    font-size: clamp(3.5rem, 8vw, 7rem);
    line-height: 1.05;
    margin-bottom: 24px;
    animation: fadeUp 0.8s 0.1s var(--transition-slow) both;
}

.hero-title em {
    font-style: italic;
    display: block;
    color: var(--accent-light);
}

.hero-subtitle {
    font-size: 1.2rem;
    font-weight: 300;
    opacity: 0.85;
    margin-bottom: 40px;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
    animation: fadeUp 0.8s 0.2s var(--transition-slow) both;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeUp 0.8s 0.3s var(--transition-slow) both;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 16px 32px;
    border-radius: 100px;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    border: none;
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
}

.btn-primary {
    background: var(--accent);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(193, 106, 63, 0.35);
}

.btn-outline {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.25);
    color: var(--white);
}

.btn-outline:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

.btn-ghost {
    background: transparent;
    color: var(--accent);
    padding: 12px 24px;
}

.btn-ghost:hover {
    background: var(--accent-pale);
}

/* --- Page Header (for sub-pages) --- */
.page-header {
    padding: calc(var(--nav-height) + 80px) 32px 60px;
    text-align: center;
    background: linear-gradient(180deg, var(--cream-alt) 0%, var(--cream) 100%);
}

.page-header h1 {
    margin-bottom: 12px;
}

.page-header p {
    color: var(--text-light);
    font-size: 1.1rem;
    max-width: 560px;
    margin: 0 auto;
}

/* --- Sections --- */
.section {
    padding: 120px 0;
}

.section-label {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 16px;
}

.section-title {
    margin-bottom: 16px;
}

.section-desc {
    color: var(--text-light);
    font-size: 1.1rem;
    max-width: 560px;
}

.section-header {
    text-align: center;
    margin-bottom: 64px;
}

.section-header .section-desc {
    margin: 0 auto;
}

/* --- Product Cards --- */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: 32px;
}

.product-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all var(--transition-slow);
    opacity: 0;
    transform: translateY(30px);
}

.product-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
}

.product-card-image {
    width: 100%;
    height: 420px;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.product-card:hover .product-card-image {
    transform: scale(1.03);
}

.product-card-body {
    padding: 32px;
}

.product-card-body h3 {
    margin-bottom: 8px;
}

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

.product-card-tag {
    display: inline-block;
    background: var(--sage-light);
    color: var(--sage);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 4px 12px;
    border-radius: 100px;
    margin-bottom: 16px;
}

/* --- Ingredients List --- */
.ingredients-list {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.ingredients-list li {
    background: var(--cream-alt);
    padding: 8px 16px;
    border-radius: 100px;
    font-size: 0.85rem;
    color: var(--text-light);
    font-weight: 500;
}

/* --- Great For --- */
.great-for {
    background: var(--cream-alt);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    max-width: 800px;
    margin: 40px auto 0;
}

.great-for-heading {
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-light);
    margin-bottom: 16px;
}

.great-for-list {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.9;
}

/* --- About Section --- */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-image {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    position: relative;
}

.about-image img {
    width: 100%;
    height: 560px;
    object-fit: cover;
}

.about-image-accent {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 160px;
    height: 160px;
    background: var(--accent-pale);
    border-radius: var(--radius-lg);
    z-index: -1;
}

.about-text .section-label {
    margin-bottom: 12px;
}

.about-text h2 {
    margin-bottom: 20px;
}

.about-text p {
    color: var(--text-light);
    margin-bottom: 16px;
    font-size: 1.05rem;
    line-height: 1.8;
}

/* --- Commitment Banner --- */
.commitment {
    background: var(--text);
    color: var(--white);
    padding: 100px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.commitment::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('../images/Banana banner.jpg') center/cover no-repeat;
    filter: brightness(0.15) saturate(0.5);
    opacity: 0.3;
}

.commitment-content {
    position: relative;
    z-index: 1;
}

.commitment h2 {
    margin-bottom: 16px;
}

.commitment p {
    font-size: 1.15rem;
    opacity: 0.8;
    max-width: 560px;
    margin: 0 auto 32px;
}

/* --- Content Card (policies, etc.) --- */
.content-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 48px;
    max-width: 800px;
    margin: 0 auto;
}

.ingredient-card-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: var(--radius);
    margin-bottom: 28px;
}

.content-card h2 {
    font-size: 1.4rem;
    color: var(--accent);
    margin: 40px 0 12px 0;
}

.content-card h2:first-child {
    margin-top: 24px;
}

.content-card p {
    color: var(--text-light);
    margin-bottom: 20px;
    line-height: 1.8;
}

.content-card .contact-email {
    display: inline-block;
    color: var(--accent);
    font-weight: 600;
    padding: 4px 0;
    border-bottom: 2px solid var(--accent-light);
}

/* --- FAQ --- */
.faq-item {
    margin-bottom: 32px;
}

.faq-question {
    font-weight: 700;
    color: var(--text);
    font-size: 1.05rem;
    margin-bottom: 8px;
}

.faq-answer {
    font-weight: 400;
    color: var(--text-light);
    margin-bottom: 0;
}

.faq-callout {
    background: var(--cream-alt);
    border-left: 3px solid var(--accent-light);
    border-radius: var(--radius-sm);
    padding: 20px 24px;
    margin-top: 40px;
}

.faq-callout p {
    margin-bottom: 0;
}

.faq-callout p + p {
    margin-top: 4px;
}

.faq-callout strong {
    color: var(--text);
}

.content-card .contact-email:hover {
    color: var(--accent-hover);
    border-bottom-color: var(--accent-hover);
}

/* --- Footer --- */
.footer {
    background: var(--text);
    color: rgba(255,255,255,0.7);
    padding: 64px 32px 32px;
}

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

.footer-brand h3 {
    color: var(--white);
    font-size: 1.6rem;
    margin-bottom: 12px;
}

.footer-brand p {
    font-size: 0.9rem;
    line-height: 1.7;
}

.footer-links h4 {
    color: var(--white);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 20px;
}

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

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

.footer-links a {
    font-size: 0.9rem;
    transition: color var(--transition);
}

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

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    flex-wrap: wrap;
    gap: 12px;
}

/* --- Animations --- */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s var(--transition-slow), transform 0.7s var(--transition-slow);
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Scroll indicator --- */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
    animation: bounce 2s infinite;
}

.scroll-indicator span {
    display: block;
    width: 24px;
    height: 40px;
    border: 2px solid rgba(255,255,255,0.4);
    border-radius: 100px;
    position: relative;
}

.scroll-indicator span::after {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: rgba(255,255,255,0.6);
    border-radius: 4px;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(8px); }
}

/* --- Back to Top --- */
.back-to-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--accent);
    color: var(--white);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
    transition: all var(--transition);
    box-shadow: 0 4px 16px rgba(193, 106, 63, 0.35);
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.back-to-top:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(193, 106, 63, 0.45);
}

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

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

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 320px;
        height: 100vh;
        background: var(--white);
        flex-direction: column;
        align-items: flex-start;
        padding: calc(var(--nav-height) + 20px) 32px;
        gap: 4px;
        transition: right var(--transition-slow);
        box-shadow: -4px 0 24px rgba(0,0,0,0.08);
    }

    .nav-links.open {
        right: 0;
    }

    .nav-links a {
        width: 100%;
        font-size: 1.1rem;
        padding: 14px 20px;
    }

    .nav-toggle {
        display: flex;
    }

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

    .section {
        padding: 80px 0;
    }

    .content-card {
        padding: 24px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }

    .hero-title {
        font-size: clamp(2.5rem, 10vw, 4rem);
    }
}

.btn-order-now {
    display: inline-block;
    margin-top: 16px;
    padding: 10px 20px;
    border-radius: 100px;
    background: var(--accent);
    color: var(--white);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    transition: all var(--transition);
}

.btn-order-now:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(193, 106, 63, 0.3);
}

@media (max-width: 480px) {
    .container {
        padding: 0 20px;
    }

    .hero-actions {
        flex-direction: column;
    }

    .btn {
        justify-content: center;
    }

    .product-card-image {
        height: 280px;
    }

    .about-image img {
        height: 360px;
    }
}
