/* public/css/home.css */

:root {
    --sg-orange: #e0592a;
    --sg-yellow: #f8c84e;
    --sg-blue: #9bcbeb;
    --sg-dark: #111111;
    --sg-cream: #fff7e6;
    --sg-white: #ffffff;
    --sg-muted: #666666;
    --sg-border: rgba(17, 17, 17, 0.12);
}

* {
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

body {
    font-family: var(--beer-font-family, Arial, sans-serif);
    margin: 0;
    padding: 0;
    background-color: #fbfbfb;
    color: #111;
}

.sg-home-page {
    width: 100%;
    max-width: 100%;
    background: var(--sg-cream);
    overflow: hidden;
}

.sg-home-page h1,
.sg-home-page h2,
.sg-home-page h3,
.sg-home-page h4,
.sg-home-page .section-title {
    font-family: var(--beer-font-family, Arial, sans-serif);
    text-transform: uppercase;
    font-weight: 900;
    letter-spacing: -0.5px;
}

.sg-home-page a {
    color: inherit;
}

.sg-container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 22px;
}

/* =========================
   HERO ỔN ĐỊNH
========================= */

.sg-hero {
    width: 100%;
    max-width: 100%;
    min-height: 68vh;
    position: relative;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sg-white);
    text-align: center;
    padding: 90px 20px;
    margin: 0;
    overflow: hidden;
}

.sg-hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at center, rgba(224, 89, 42, 0.16), transparent 42%),
        rgba(0, 0, 0, 0.56);
    z-index: 1;
}

.sg-hero-content {
    position: relative;
    z-index: 2;
    max-width: 860px;
    width: 100%;
    margin: 0 auto;
}

.sg-eyebrow,
.sg-section-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--sg-yellow);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-size: 12px;
    margin: 0 0 12px;
}

.sg-hero h1 {
    font-size: clamp(38px, 6vw, 78px);
    line-height: 1.2;
    margin: 0;
    text-shadow: 0 10px 35px rgba(0, 0, 0, 0.45);
}

.sg-hero-text {
    max-width: 640px;
    margin: 20px auto 0;
    font-size: clamp(14px, 1.4vw, 18px);
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.92);
    font-weight: 700;
}

/* Nếu trong cache hoặc file cũ vẫn còn hero-products thì ẩn để không vỡ giao diện */
.sg-hero-products {
    display: none !important;
}

/* =========================
   BUTTONS
========================= */

.sg-hero-actions {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 26px;
}

.sg-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 18px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 900;
    text-transform: uppercase;
    border: 2px solid transparent;
    font-size: 13px;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.sg-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.18);
}

.sg-btn-primary {
    background: var(--sg-orange);
    color: var(--sg-white);
    border-color: var(--sg-orange);
}

.sg-btn-outline {
    background: rgba(255, 255, 255, 0.08);
    color: var(--sg-white);
    border-color: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
}

.sg-btn-outline.light {
    background: transparent;
    color: var(--sg-white);
    border-color: var(--sg-white);
}

.sg-btn-dark {
    background: #6f42c1;
    color: var(--sg-white);
    border-color: #6f42c1;
}

/* =========================
   STORY
========================= */

.sg-story-section {
    width: 100%;
    max-width: 100%;
    background: var(--sg-blue);
    padding: 70px 0;
    overflow: hidden;
}

.sg-story-grid {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 38px;
    align-items: center;
}

.sg-story-art {
    display: flex;
    justify-content: center;
}

.sg-circle-bg {
    width: min(300px, 72vw);
    height: min(300px, 72vw);
    border-radius: 50%;
    background:
        linear-gradient(135deg, rgba(255,255,255,0.45), rgba(255,255,255,0.05)),
        var(--sg-orange);
    border: 7px solid rgba(255, 255, 255, 0.45);
    box-shadow: 0 20px 42px rgba(0, 0, 0, 0.16);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--sg-white);
    text-align: center;
}

.sg-circle-bg span {
    font-weight: 900;
    letter-spacing: 3px;
    font-size: 14px;
}

.sg-circle-bg strong {
    font-size: clamp(42px, 6vw, 68px);
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.sg-circle-bg em {
    font-style: normal;
    font-weight: 900;
    font-size: 16px;
    letter-spacing: 4px;
}

.sg-story-content h2,
.sg-section-heading h2,
.sg-event-content h2,
.sg-newsletter-box h2 {
    font-size: clamp(26px, 3.4vw, 44px);
    line-height: 1.2;
    margin: 0 0 18px;
}

.sg-story-content p {
    color: #123;
    font-size: 15px;
    line-height: 1.6;
}

.sg-large-text {
    font-size: 17px !important;
    font-weight: 800;
    line-height: 1.5 !important;
}

/* =========================
   PRODUCTS
========================= */

.sg-products-section {
    width: 100%;
    max-width: 100%;
    padding: 65px 0;
    background: var(--sg-cream);
    overflow: hidden;
}

.sg-section-heading {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 34px;
}

.sg-section-heading h2 {
    margin-bottom: 10px;
}

.sg-section-heading p {
    color: var(--sg-muted);
    line-height: 1.6;
    font-size: 15px;
}

.sg-product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.sg-product-card {
    background: var(--sg-white);
    border: 1px solid var(--sg-border);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.sg-product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 18px 38px rgba(0, 0, 0, 0.11);
}

.sg-product-image {
    height: 220px;
    background:
        radial-gradient(circle at center, rgba(248, 200, 78, 0.35), transparent 55%),
        #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    overflow: hidden;
}

.sg-product-image img {
    width: 100%;
    max-width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.25s ease;
}

.sg-product-card:hover .sg-product-image img {
    transform: scale(1.04) rotate(-2deg);
}

.sg-product-body {
    padding: 16px;
    text-align: center;
}

.sg-product-type {
    margin: 0 0 7px;
    color: var(--sg-orange);
    font-weight: 900;
    letter-spacing: 1px;
    font-size: 11px;
}

.sg-product-body h3 {
    margin: 0 0 10px;
    font-size: 18px;
    line-height: 1.15;
}

.sg-product-price {
    font-weight: 900;
    font-size: 16px;
    margin-bottom: 14px;
}

.sg-product-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    background: #6f42c1;
    color: var(--sg-white);
    border-radius: 999px;
    padding: 8px 14px;
    font-weight: 900;
    text-transform: uppercase;
    font-size: 12px;
}

/* =========================
   EVENT CTA
========================= */

.sg-event-cta {
    width: 100%;
    max-width: 100%;
    position: relative;
    min-height: 400px;
    display: flex;
    align-items: center;
    background:
        url('https://images.unsplash.com/photo-1516450360452-9312f5e86fc7?auto=format&fit=crop&w=1920&q=80')
        center/cover no-repeat;
    color: var(--sg-white);
    padding: 65px 0;
    overflow: hidden;
}

.sg-event-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(0,0,0,0.75), rgba(0,0,0,0.25)),
        rgba(0, 0, 0, 0.25);
}

.sg-event-content {
    position: relative;
    z-index: 2;
    max-width: 620px;
}

.sg-event-content p {
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.88);
    font-size: 15px;
}

/* =========================
   NEWSLETTER
========================= */

.sg-newsletter-section {
    width: 100%;
    max-width: 100%;
    background: var(--sg-dark);
    padding: 50px 0;
    color: var(--sg-white);
    overflow: hidden;
}

.sg-newsletter-box {
    display: grid;
    grid-template-columns: 1fr 0.9fr;
    gap: 32px;
    align-items: center;
}

.sg-newsletter-box h2 {
    font-size: clamp(26px, 3.4vw, 42px);
    margin: 0;
}

.sg-newsletter-form {
    display: flex;
    gap: 10px;
    background: rgba(255, 255, 255, 0.08);
    padding: 9px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.16);
}

.sg-newsletter-form input {
    flex: 1;
    min-width: 0;
    border: none;
    outline: none;
    background: transparent;
    color: var(--sg-white);
    padding: 0 14px;
    font-size: 14px;
}

.sg-newsletter-form input::placeholder {
    color: rgba(255, 255, 255, 0.62);
}

.sg-newsletter-form button {
    border: none;
    background: var(--sg-orange);
    color: var(--sg-white);
    padding: 10px 16px;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 900;
    text-transform: uppercase;
    font-size: 13px;
}

.sg-empty-box {
    background: rgba(255, 255, 255, 0.75);
    color: var(--sg-dark);
    border: 1px dashed var(--sg-border);
    border-radius: 16px;
    padding: 28px;
    text-align: center;
    font-weight: 700;
}

/* =========================
   COMPAT OLD CLASSES
========================= */

.sg-home-page .container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 22px;
}

.sg-home-page .main-red-button {
    background-color: var(--sg-orange);
    color: white;
    border: 2px solid var(--sg-orange);
    padding: 10px 18px;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
    border-radius: 999px;
    transition: background-color 0.3s;
    font-family: var(--beer-font-family, Arial, sans-serif);
}

.sg-home-page .main-red-button:hover {
    background-color: var(--sg-dark);
}

/* =========================
   FOOTER FIX
========================= */

.footer-section {
    width: 100%;
    max-width: 100%;
    background: #111;
    color: #fff;
    padding: 48px 0 36px;
    font-size: 14px;
    overflow: hidden;
}

.footer-container,
.footer-section .container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 22px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 32px;
    align-items: flex-start;
}

.footer-col h4 {
    color: #e0592a;
    font-size: 24px;
    margin: 0 0 14px;
    font-weight: 900;
    text-transform: uppercase;
}

.footer-col p {
    margin: 0 0 12px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
}

.footer-col strong {
    color: #fff;
}

.footer-links-col {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links-col a {
    color: #fff;
    text-decoration: none;
    font-weight: 800;
    letter-spacing: 0.5px;
    transition: color 0.25s ease, transform 0.25s ease;
}

.footer-links-col a:hover {
    color: #e0592a;
    transform: translateX(4px);
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 1100px) {
    .sg-product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .sg-story-grid,
    .sg-newsletter-box {
        grid-template-columns: 1fr;
    }

    .sg-story-section {
        padding: 55px 0;
    }

    .sg-hero {
        min-height: 62vh;
        padding: 70px 16px;
    }
}

@media (max-width: 768px) {
    .footer-section {
        padding: 36px 0 28px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 22px;
    }

    .footer-col h4 {
        font-size: 22px;
    }
}

@media (max-width: 650px) {
    .sg-hero {
        min-height: 58vh;
        padding: 60px 16px;
    }

    .sg-hero h1 {
        font-size: clamp(32px, 10vw, 48px);
    }

    .sg-hero-text {
        font-size: 14px;
    }

    .sg-hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .sg-btn {
        width: 100%;
    }

    .sg-story-section,
    .sg-products-section,
    .sg-event-cta {
        padding: 45px 0;
    }

    .sg-product-grid {
        grid-template-columns: 1fr;
    }

    .sg-newsletter-form {
        border-radius: 22px;
        flex-direction: column;
    }

    .sg-newsletter-form input {
        min-height: 42px;
    }

    .sg-newsletter-form button {
        width: 100%;
    }

    .sg-circle-bg {
        width: 260px;
        height: 260px;
    }
}