﻿:root {
    --green-dark: #2c4a17;
    --green-line: #2c4a17;
    --mint: #eaf6e6;
    --mint-2: #d8efd3;
    --cream: #f4f7e8;
    --yellow: #f6d860;
    --white: #ffffff;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

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

html, body {
    margin: 0;
    padding: 0;
}

body {
    min-height: 100vh;
    min-height: 100svh;
    -webkit-font-smoothing: antialiased;
    font-family: "Be Vietnam Pro", "Segoe UI", Arial, sans-serif;
    color: var(--white);
    background:
        linear-gradient(135deg, transparent 0 55%, rgba(255,255,255,.55) 55% 70%, transparent 70%),
        linear-gradient(160deg, var(--mint) 0%, #f5fbf3 45%, var(--mint-2) 100%);
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

a {
    color: inherit;
}

/* ---------- Khung ngoài ---------- */
.page {
    position: relative;
    width: min(1320px, calc(100% - 64px));
    margin: 40px auto;
    padding: 40px;
    border: 1.5px solid var(--green-line);
    border-radius: 48px;
}

.spark {
    position: absolute;
    width: 48px;
    height: 48px;
    fill: var(--green-dark);
}

.spark--right {
    right: -25px;
    top: 16%;
}

.spark--left {
    left: -25px;
    bottom: 13%;
}

/* ---------- Thẻ xanh ---------- */
.card {
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    background: var(--green-dark);
    border-radius: 48px;
    overflow: hidden;
}

.card__content {
    padding: 40px 36px 40px 52px;
}

.card__photo {
    margin: 0;
    border-radius: 56px;
    overflow: hidden;
}

.card__photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ---------- Ảnh nhỏ ---------- */
.thumbs {
    display: grid;
    grid-template-columns: 1fr 1.8fr 0.88fr;
    gap: 14px;
    align-items: stretch;
}

.thumb {
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: auto;
    height: 158px;
    overflow: hidden;
}

.thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.thumb--qr img {
    padding: 6px;
}

.thumb--qr {
    transition: transform .2s ease, box-shadow .2s ease;
}

.thumb--qr:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,.3);
}

.thumb--logo img {
    object-fit: cover;
}

/* ---------- Tiêu đề ---------- */
.headline {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 22px 0 26px;
}

.call {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 24px;
    background: var(--cream);
    color: var(--green-dark);
    border-radius: 999px;
    text-decoration: none;
    font-size: 17px;
    line-height: 1.45;
    transition: transform .2s ease, background .2s ease;
}

.call:hover {
    background: var(--yellow);
    transform: scale(1.04);
}

.call__number {
    font-weight: 500;
    white-space: nowrap;
}

.title {
    margin: 0;
    font-size: clamp(32px, 3.7vw, 50px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -.5px;
}

/* ---------- Nội dung ---------- */
.desc p,
.note {
    margin: 0;
    font-size: 18px;
    line-height: 1.55;
}

mark {
    background: none;
    color: var(--yellow);
    font-weight: 700;
}

.desc__last {
    position: relative;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255,255,255,.75);
}

.leaf {
    width: 30px;
    height: 30px;
    fill: var(--white);
    vertical-align: middle;
    margin-left: 12%;
}

.note {
    margin-top: 12px;
}

/* ---------- Nút liên hệ (chỉ hiện trên điện thoại) ---------- */
.contact-bar {
    display: none;
}

.btn {
    flex: 1;
    padding: 14px 10px;
    border-radius: 999px;
    text-align: center;
    font-weight: 700;
    font-size: 16px;
    text-decoration: none;
}

.btn--call {
    background: var(--yellow);
    color: var(--green-dark);
}

.btn--zalo {
    background: #0068ff;
    color: var(--white);
}

/* ---------- Trải nghiệm cảm ứng ---------- */
a {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.call:active,
.btn:active,
.thumb--qr:active {
    transform: scale(.96);
}

.btn {
    transition: transform .15s ease, filter .15s ease;
}

/* Hiệu ứng hover chỉ dành cho thiết bị có chuột */
@media (hover: none) {
    .call:hover {
        background: var(--cream);
        transform: none;
    }

    .thumb--qr:hover {
        transform: none;
        box-shadow: none;
    }
}

/* ---------- Máy tính bảng ---------- */
@media (max-width: 1100px) {
    body {
        display: block;
        background-attachment: scroll;
    }

    .page {
        width: calc(100% - 48px);
        margin: 24px auto;
        padding: 24px;
        border-radius: 40px;
    }

    .card {
        grid-template-columns: 1fr;
        border-radius: 36px;
    }

    .card__photo {
        aspect-ratio: 16 / 9;
        border-radius: 36px;
    }

    .thumb {
        height: clamp(90px, 18vw, 158px);
    }
}

/* ---------- Điện thoại ---------- */
@media (max-width: 640px) {
    body {
        overflow-x: hidden;
    }

    .page {
        width: calc(100% - 20px);
        margin: 10px auto calc(86px + env(safe-area-inset-bottom));
        padding: 10px;
        border-radius: 26px;
    }

    .spark {
        width: 26px;
        height: 26px;
    }

    .spark--right { right: -13px; top: 38%; }
    .spark--left { left: -13px; bottom: 22%; }

    .card {
        border-radius: 20px;
    }

    .card__content {
        padding: 16px 16px 22px;
    }

    .card__photo {
        aspect-ratio: 3 / 2;
        border-radius: 20px;
    }

    .thumbs {
        grid-template-columns: 1fr 1.9fr 0.9fr;
        gap: 8px;
    }

    .thumb {
        height: clamp(68px, 23vw, 110px);
        border-radius: 4px;
    }

    .thumb--qr img {
        padding: 3px;
    }

    .headline {
        flex-direction: column-reverse;
        align-items: flex-start;
        gap: 12px;
        margin: 18px 0 16px;
    }

    .title {
        font-size: clamp(28px, 8.6vw, 40px);
    }

    .call {
        flex-direction: row;
        gap: 6px;
        padding: 9px 18px;
        font-size: 16px;
    }

    .desc p,
    .note {
        font-size: 16px;
        line-height: 1.6;
    }

    .desc p + p {
        margin-top: 2px;
    }

    .desc__last {
        display: flex;
        align-items: flex-end;
        justify-content: space-between;
        gap: 12px;
    }

    .leaf {
        flex: 0 0 auto;
        width: 26px;
        height: 26px;
        margin-left: 0;
    }

    .note {
        margin-top: 14px;
    }

    /* Thanh gọi / Zalo cố định dưới màn hình */
    .contact-bar {
        display: flex;
        gap: 10px;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 10;
        padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
        background: rgba(44, 74, 23, .92);
        -webkit-backdrop-filter: blur(10px);
        backdrop-filter: blur(10px);
        box-shadow: 0 -6px 20px rgba(0, 0, 0, .15);
        animation: bar-in .35s ease-out both;
    }

    .btn {
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 48px;
        padding: 10px;
        font-size: 15px;
        white-space: nowrap;
    }
}

/* Màn hình rất nhỏ (≤ 360px) */
@media (max-width: 360px) {
    .card__content {
        padding: 14px 12px 20px;
    }

    .desc p,
    .note {
        font-size: 15px;
    }

    .btn {
        font-size: 14px;
    }
}

@keyframes bar-in {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

@media (min-width: 1200px) {
    .title {
        white-space: nowrap;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }
}

.nowrap {
    white-space: nowrap;
}
