:root {
    --bg: #0A0F0C;
    --ink2: #000000;
    --green: #2d5737;
    --card: #2d5737;
    --line: #24402E;
    --ink: white;
}

* {
    box-sizing: border-box
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 5rem
}

@media (prefers-reduced-motion:reduce) {
    html {
        scroll-behavior: auto
    }

    .slide {
        transition: none
    }
}

body {
    margin: 0;
    /* background: linear-gradient(rgba(10, 15, 12, .6), rgba(10, 15, 12, .3)), url(img/kem2b_bg.jpeg) center/cover fixed var(--bg); */
    background: var(--ink);
    color: var(--ink2);
    font-family: "Be Vietnam Pro", system-ui, sans-serif;
    line-height: 1.6
}

body * {
    font-family: "Paytone One", system-ui, sans-serif
}

p,
p *,
.grid h3 {
    font-family: "Be Vietnam Pro", system-ui, sans-serif
}

a {
    color: inherit
}

:focus-visible {
    outline: 3px solid var(--green);
    outline-offset: 3px
}

.skip {
    position: absolute;
    left: -999px;
    background: var(--green);
    color: var(--bg);
    padding: .5rem 1rem
}

.skip:focus {
    left: 1rem;
    top: 1rem;
    z-index: 20
}

.top {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: .75rem;
    font: 700 1.6rem "Paytone One", system-ui, sans-serif;
    padding: .9rem clamp(1rem, 5vw, 4rem);
    background: var(--ink);
    /* color: var(--bg)*/
    color: var(--ink2);
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    font: 700 1.6rem "Paytone One", system-ui, sans-serif;
    text-decoration: none
}

.logo img {
    display: block;
    height: 50px;
    /* chỉnh to/nhỏ ở đây */
    width: auto;
    /* giữ đúng tỉ lệ */
    display: block;
}

.logo-inline {
    height: 1em;
    /* cao bằng chữ, tự co theo cỡ font */
    width: auto;
    vertical-align: -0.15em;
    /* căn logo ngang hàng với chữ */
    display: inline-block;
}

.branch-photo {
    display: block;
    width: min(100%, 24rem);
    height: auto;
    margin-bottom: 1rem;
}

.top nav a {
    margin-left: 1.25rem;
    text-decoration: none;
    font-weight: 700
}

.top nav a:hover {
    text-decoration: underline
}

.top :focus-visible {
    outline-color: var(--bg)
}

nav[aria-label="Chính"] {
    display: flex;
    gap: 2rem;
}

nav[aria-label="Chính"] a {
    font-size: 1.25rem;
    /* chữ to hơn, chỉnh ở đây */
    font-weight: 600;
    color: #000;
    text-decoration: none;
}

nav[aria-label="Chính"] a:hover {
    opacity: 0.7;
}

section {
    padding: clamp(2.5rem, 7vw, 5rem) clamp(1rem, 5vw, 4rem);
    max-width: 68rem;
    margin: 0 auto
}

h1,
h2,
h3 {
    font-family: "Paytone One", system-ui, sans-serif;
    line-height: 1.15;
    margin: 0
}

h1 {
    font-size: clamp(2.4rem, 7vw, 4.5rem)
}

.hero-italic {
    font-style: italic;
    white-space: nowrap
}

.hero h1 .logo-inline {
    height: 1.3em;
    vertical-align: -.25em
}

h2 {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    margin-bottom: 1.5rem
}

h3 {
    font-size: 1.1rem
}

.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
    gap: 0;
    max-width: none;
    padding: 0;
    background: var(--green);
    color: var(--ink);
    overflow: hidden
}

.hero-text {
    padding: clamp(2rem, 6vw, 5rem) clamp(1rem, 5vw, 4rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start
}

.hero p {
    max-width: 34rem;
    margin: .2rem 0;
    font-size: 1.5rem
}

.hero h1+p {
    margin-top: .75rem
}

.hero p:last-of-type {
    margin-bottom: 1.75rem
}

.hero .btn {
    background: #fff;
    color: var(--ink2)
}

.hero .btn:hover {
    background: #FFC93C
}

.hero-img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 22rem;
    object-fit: cover
}

.btn {
    display: inline-block;
    background: var(--green);
    color: var(--bg);
    padding: .8rem 1.6rem;
    border-radius: 999px;
    font-weight: 700;
    text-decoration: none
}

.btn:hover {
    background: var(--ink)
}

/* Tab chọn cỡ: chỉ dùng CSS */
.sizes input {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none
}

.tablist {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
    margin-bottom: 1.5rem
}

.tablist label {
    cursor: pointer;
    padding: .55rem 1.3rem;
    border: 2px solid var(--green);
    border-radius: 999px;
    font-weight: 700
}

.tablist label:hover {
    background: var(--line)
}

#s80:checked~.tablist [for=s80],
#s160:checked~.tablist [for=s160],
#s500:checked~.tablist [for=s500],
#s2l:checked~.tablist [for=s2l] {
    background: var(--green);
    color: var(--ink)
}

#s80:focus-visible~.tablist [for=s80],
#s160:focus-visible~.tablist [for=s160],
#s500:focus-visible~.tablist [for=s500],
#s2l:focus-visible~.tablist [for=s2l] {
    outline: 3px solid var(--ink);
    outline-offset: 3px
}

.panel {
    display: none
}

#s80:checked~.s80,
#s160:checked~.s160,
#s500:checked~.s500,
#s2l:checked~.s2l {
    display: block
}

/* Panel mới */
#sdrink:checked~.sdrink,
#sextra:checked~.sextra {
    display: block
}

#sdrink:checked~.tablist [for=sdrink],
#sextra:checked~.tablist [for=sextra],
#b1:checked~.branchlist [for=b1],
#b2:checked~.branchlist [for=b2] {
    background: var(--green);
    color: var(--ink)
}

#sdrink:focus-visible~.tablist [for=sdrink],
#sextra:focus-visible~.tablist [for=sextra],
#b1:focus-visible~.branchlist [for=b1],
#b2:focus-visible~.branchlist [for=b2] {
    outline: 3px solid var(--ink);
    outline-offset: 3px
}

/* Ghi chú theo chi nhánh */
.note-b1,
.note-b2 {
    display: none
}

#b1:checked~.note-b1,
#b2:checked~.note-b2 {
    display: block
}

/* Cỡ kem ly 80ml và 160ml chỉ có tại chi nhánh 1 */
#b1:checked~.tablist .b2-only {
    display: none
}

#b2:checked~.tablist .b1-only,
#b2:checked~.panel.s80,
#b2:checked~.panel.s160,
#b2:checked~.panel.s2l,
#b1:checked~.panel.sdrink,
#b1:checked~.panel.sextra {
    display: none
}

.size-note {
    margin: 0 0 1.25rem;
    opacity: .85
}

.grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(12.5rem, 1fr));
    gap: 1.25rem;
    color: var(--ink);
}

.panel.sdrink>h3 {
    margin: 1rem 0
}

.grid li {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: .9rem;
    padding: .75rem .75rem 1rem;
    display: flex;
    flex-direction: column
}

.grid img {
    width: 100%;
    height: 11rem;
    object-fit: contain;
    border-radius: .5rem;
    margin-bottom: .7rem;
    background: #fff
}

.grid p {
    margin: .15rem 0 .5rem;
    font-size: .92rem;
    opacity: .75;
    flex: 1
}

.grid b {
    color: var(--green)
}

.note {
    margin-top: 1.5rem;
    font-size: .95rem;
    opacity: .85
}

.visit {
    background: var(--green);
    color: var(--ink);
    max-width: none;
}

.visit :not(h2) {
    font-family: "Be Vietnam Pro", system-ui, sans-serif
}

.visit .branches {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px
}

.visit .branch h3 {
    margin: 0 0 20px
}

.visit .icon-link {
    display: inline-flex;
    align-items: center;
    gap: 8px
}

.visit .icon-link svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0
}

.visit .social {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 20px
}

dl {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: .6rem 1.5rem;
    margin: 0
}

dt {
    font-weight: 700
}

dd {
    margin: 0
}

footer {
    text-align: center;
    padding: 2rem 1rem;
    border-top: 2px solid var(--line)
}

/* Slider nổi bật: chỉ dùng CSS */
.promo {
    position: relative;
    display: grid;
    max-width: 80rem
}

/* Radio ẩn đặt sát chấm tròn để trình duyệt không cuộn lên đầu section */
.promo input {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none
}

/* Tất cả slide chồng cùng 1 ô nên chiều cao không đổi */
.slide {
    grid-area: 1 / 1;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: clamp(1rem, 4vw, 3rem);
    align-items: center;
    visibility: hidden;
    opacity: 0;
    transition: opacity .4s ease, visibility .4s
}

#p1:checked~.s1,
#p2:checked~.s2,
#p3:checked~.s3,
#p4:checked~.s4 {
    visibility: visible;
    opacity: 1
}

.slide img {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: .5rem
}

.slide-text {
    text-align: center
}

.slide-text h2 {
    margin-bottom: 1rem
}

.slide-text p {
    max-width: 34rem;
    margin: 0 auto 1.5rem
}

.promo .btn {
    color: var(--ink)
}

.promo .btn:hover {
    background: #FFC93C;
    color: var(--ink2)
}

.dots {
    display: flex;
    justify-content: center;
    gap: .75rem;
    margin-top: 1.5rem;
    grid-area: 2 / 1;
}

.dots label {
    width: 1rem;
    height: 1rem;
    border: 2px solid var(--green);
    border-radius: 50%;
    cursor: pointer
}

#p1:checked~.dots [for=p1],
#p2:checked~.dots [for=p2],
#p3:checked~.dots [for=p3],
#p4:checked~.dots [for=p4] {
    background: var(--green)
}

#p1:focus-visible~.dots [for=p1],
#p2:focus-visible~.dots [for=p2],
#p3:focus-visible~.dots [for=p3],
#p4:focus-visible~.dots [for=p4] {
    outline: 3px solid var(--ink2);
    outline-offset: 3px
}

@keyframes fade {
    from {
        opacity: 0
    }

    to {
        opacity: 1
    }
}

@media (prefers-reduced-motion:reduce) {
    .slide {
        animation: none
    }
}


@media (max-width:700px) {
    body {
        background-attachment: scroll
    }

    .hero {
        grid-template-columns: 1fr
    }

    dl {
        grid-template-columns: 1fr
    }

    dd {
        margin-bottom: .5rem
    }

    .grid {
        grid-template-columns: repeat(2, 1fr);
        gap: .75rem
    }

    .grid img {
        height: 9rem
    }

    .visit .branches {
        grid-template-columns: 1fr
    }

    .slide {
        grid-template-columns: 1fr
    }

    .slide img {
        max-width: 100%;
        aspect-ratio: 4 / 3
    }

}

/* Tự hiện cỡ 500ml nếu cỡ đang chọn không có tại chi nhánh đó */
#b1:checked~:is(#sdrink, #sextra):checked~.panel.s500,
#b2:checked~:is(#s80, #s160, #s2l):checked~.panel.s500 {
    display: block
}

#b1:checked~:is(#sdrink, #sextra):checked~.tablist [for=s500],
#b2:checked~:is(#s80, #s160, #s2l):checked~.tablist [for=s500] {
    background: var(--green);
    color: var(--ink)
}

/* =====================================================================
   RESPONSIVE LAYER – tối ưu cho điện thoại, tablet, laptop, màn hình lớn
   ===================================================================== */

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%
}

body {
    overflow-x: clip
        /* chống tràn ngang, không làm hỏng sticky header */
}

img {
    max-width: 100%
}

/* ---- Header ---- */
.logo {
    min-width: 0;
    font-size: clamp(.95rem, 3.6vw, 1.6rem)
}

.logo img {
    height: clamp(36px, 9vw, 50px)
}

.top nav a {
    margin-left: 0
}

nav[aria-label="Chính"] {
    gap: clamp(1rem, 3vw, 2rem)
}

nav[aria-label="Chính"] a {
    font-size: clamp(1rem, 2.6vw, 1.25rem);
    display: inline-flex;
    align-items: center;
    min-height: 44px
        /* vùng chạm đủ lớn cho ngón tay */
}

/* ---- Tab chọn chi nhánh / cỡ: dễ bấm, hover đọc được ---- */
.tablist label {
    display: inline-flex;
    align-items: center;
    min-height: 44px
}

.tablist label:hover {
    color: var(--ink)
}

/* ---- Lưới món ---- */
.grid li {
    min-width: 0
}

.grid h3 {
    overflow-wrap: break-word
}

.grid b {
    color: #fff
}

/* ---- Slider: vùng chạm của chấm tròn lớn hơn (nhìn vẫn nhỏ) ---- */
.dots label {
    position: relative
}

.dots label::after {
    content: "";
    position: absolute;
    inset: -.9rem -.3rem
}

/* Ảnh slide không quá cao trên màn hình lớn */
.slide img {
    max-height: min(36rem, 75vh)
}

/* ---- Khối Cửa hàng: nền full-width nhưng nội dung gọn giữa ---- */
.visit {
    padding-inline: max(clamp(1rem, 5vw, 4rem), calc((100% - 68rem) / 2))
}

.visit .icon-link {
    min-height: 44px
}

dd {
    overflow-wrap: anywhere
}

/* ---- Màn hình rất lớn: phóng nhẹ toàn bộ giao diện ---- */
@media (min-width:1600px) {
    html {
        font-size: 112.5%
    }
}

/* ---- Tablet & nhỏ hơn ---- */
@media (max-width:800px) {
    .hero {
        grid-template-columns: 1fr
    }

    .hero-img {
        min-height: 0;
        height: auto;
        aspect-ratio: 4 / 3
    }

    .slide {
        grid-template-columns: 1fr
    }

    .slide img {
        aspect-ratio: 4 / 3;
        max-height: none
    }

    .visit .branches {
        grid-template-columns: 1fr
    }

    dl {
        grid-template-columns: 1fr;
        gap: .15rem
    }

    dt {
        margin-top: .6rem
    }

}

/* ---- Điện thoại ---- */
@media (max-width:600px) {
    html {
        scroll-padding-top: 7rem
            /* header có thể xuống 2 dòng */
    }

    .top {
        padding: .5rem 1rem;
        gap: .1rem 1rem
    }

    .hero-text {
        padding: 2rem 1.25rem 2.25rem
    }

    .hero p {
        font-size: 1rem
    }

    .tablist {
        gap: .5rem
    }

    .tablist label {
        padding: .45rem 1rem;
        font-size: .95rem
    }

    .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr))
    }
}

/* ---- Điện thoại rất nhỏ ---- */
@media (max-width:340px) {
    .grid {
        grid-template-columns: 1fr
    }
}

/* ---- Điện thoại xoay ngang: bỏ header dính để không chiếm màn hình ---- */
@media (max-height:480px) and (orientation:landscape) {
    .top {
        position: static
    }

    html {
        scroll-padding-top: 1rem
    }
}