* {
    box-sizing: border-box;
}

html,
body {
    scroll-behavior: smooth;
}

html {
    font-size: 62.5%;
}

body {
    font-size: 1.6rem;
    font-family: "Sen", sans-serif;
    /* background: #fffbf0; */
    background: linear-gradient(90deg, #fffbf0 0%, #d7cdba 100%);
}
/*---------- Common ----------*/

a {
    text-decoration: none;
}

input,
textarea,
select,
button {
    font-size: inherit;
    font-family: inherit;
}

.section-heading {
    font-weight: 700;
    font-size: 5.2rem;
    line-height: 1.19;
    color: #000;
}

.section-desc {
    margin-top: 24px;
    font-size: 1.6rem;
    line-height: 1.88;
    color: #656689;
}

.container {
    width: 1170px;
    max-width: calc(100% - 48px);
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
}

.logo a {
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo span {
    font-family: "sen", Tahoma, Geneva, Verdana, sans-serif;
    font-weight: 700;
    font-size: 1.8rem;
    margin-left: 5px;
    color: #fff;
}

/*---------- Header ----------*/
.header {
    padding: 12px 0 8px 0;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999;
    background: rgba(0, 0, 0, 0.5); /* nền mờ */
    backdrop-filter: blur(10px); /* hiệu ứng kính mờ */
    -webkit-backdrop-filter: blur(10px);
}

.header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar__list {
    display: flex;
}

.navbar__link,
.header-action__link {
    padding: 8px 18px;
    font-weight: 500;
    font-size: 1.4rem;
    line-height: 1;
    color: #fff;
}

.navbar__link:hover {
    color: #fff;
    text-shadow: 1px 0 0 currentColor;
}

/* ------Search - form -------*/
.search-form {
    position: relative;
    display: flex;
    padding-left: 20px;
    border-radius: 99px;
    background: #1618230f;
}

.search-form__input,
.search-form__btn {
    background: transparent;
    outline: none;
    border: none;
}

.search-form__input {
    width: 240px;
    padding: 14px 0;
    margin-right: 32px;
}

.search-form__input:not(:placeholder-shown) ~ .search-form__btn {
    color: #333;
}

.search-form__input:not(:placeholder-shown) ~ .search-form__clear {
    display: block;
}

.search-form__btn {
    width: 50px;
    border-radius: 0 99px 99px 0;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
}

.search-form__btn:hover {
    background: #16182308;
}

.search-form__clear {
    position: absolute;
    right: 50px;
    top: 50%;
    transform: translateY(-50%);
    outline: none;
    border: none;
    color: #666;
    background: transparent;
    display: none;
}

.navbar__item--dropdown {
    position: relative;
}

.navbar__dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 140px;
    padding: 8px 0;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition:
        opacity 0.25s ease,
        visibility 0.25s ease,
        transform 0.25s ease;
    z-index: 99;
}

/* Hiện dropdown khi hover */
.navbar__item--dropdown:hover .navbar__dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.navbar__dropdown-link {
    display: block;
    padding: 10px 18px;
    font-size: 1.4rem;
    font-weight: 500;
    color: #5e6085;
    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.navbar__dropdown-link:hover {
    background: #f1f8e9;
    color: #fff;
}

/*---------- Hero ----------*/
.hero__background {
    position: relative;
    background-image: url(../assets/img-home/animora-bg.png);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    height: 100vh;
    width: 100vw;
}

.hero__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
}

.hero__content {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 20px;
    z-index: 1;
}

.hero__title {
    font-size: 6rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

.hero__desc {
    font-family: "beyond", sans-serif;
    margin-top: 16px;
    font-size: 2rem;
    color: rgba(255, 255, 255, 0.85);
}

.hero__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 32px;
    height: 56px;
    min-width: 160px;
    font-size: 1.6rem;
    color: #fff;
    background: transparent;
    border: 1px solid #fff;
    border-radius: 5px;
    transition:
        background 0.3s ease,
        color 0.3s ease,
        border-color 0.3s ease;
}

.hero__btn a {
    font-weight: 600;
    padding: 30px 41px;
    color: #fff;
    transition: color 0.3s ease;
}

.hero__btn:hover {
    background: #fff;
    border-color: #fff;
    color: #fff;
}

.hero__btn a:hover {
    color: #000;
}

.hero__btn:hover .btn__icon {
    background: #fff;
}

.hero__btn .btn__icon path {
    stroke: #4caf50;
}

/* ── Gallery Hero ── */
.gallery-hero {
    margin-top: 80px;
    padding: 80px 0;
}

.gallery-hero__top {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 60px;
}

.gallery-hero__label {
    font-family: "sen", sans-serif;
    font-weight: 600;
    font-size: 1.6rem;
    color: #5e6085;
    margin-bottom: 15px;
}

.gallery-hero__desc {
    margin-top: 16px;
}

/* Masonry Grid */
.gallery-hero__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(4, 200px);
    grid-auto-flow: dense;
    gap: 8px;
}

.gallery-hero__item {
    /* position: relative; */
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition:
        box-shadow 0.3s ease,
        transform 0.3s ease;
}

/* tall — chiếm 2 hàng */
.gallery-hero__item--tall {
    grid-row: span 2;
}

/* wide — chiếm 2 cột */
.gallery-hero__item--wide {
    grid-column: span 2;
}

.gallery-hero__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-hero__item:hover .gallery-hero__img {
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
    transform: scale(1.08) translateY(-4px);
}

.gallery-hero__item {
    position: relative;
}

.gallery-hero__item::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: 0.4s;
}

.gallery-hero__item:hover::after {
    opacity: 1;
}

/* ── Animals ── */
.animals {
    margin-top: 100px;
    padding-bottom: 50px;
}

.animals__top {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 60px;
}

.animals__label {
    font-family: "sen", sans-serif;
    font-weight: 600;
    font-size: 1.6rem;
    color: #5e6085;
    margin-bottom: 15px;
}

/* Grid 2x2 */
.animals__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

/* Card */
.animals-card {
    position: relative;
    height: 420px;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
}

.animals-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.animals-card:hover .animals-card__img {
    transform: scale(1.08);
}

/* Overlay mặc định — gradient từ dưới lên */
.animals-card__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.75) 0%,
        rgba(0, 0, 0, 0.2) 50%,
        transparent 100%
    );
    display: flex;
    align-items: flex-end;
    padding: 32px;
    transition: background 0.4s ease;
}

.animals-card:hover .animals-card__overlay {
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.85) 0%,
        rgba(0, 0, 0, 0.4) 60%,
        transparent 100%
    );
}

/* Body */
.animals-card__body {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.animals-card__label {
    font-size: 1.2rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.animals-card__name {
    font-family: "sen", sans-serif;
    font-size: 2.8rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}

.animals-card__desc {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
    opacity: 0;
    transform: translateY(8px);
    transition:
        opacity 0.3s ease,
        transform 0.3s ease;
}

.animals-card:hover .animals-card__desc {
    opacity: 1;
    transform: translateY(0);
}

/* Nút xem chi tiết */
.animals-card__btn {
    margin-top: 8px;
    padding: 10px 24px;
    border-radius: 99px;
    border: 2px solid #fff;
    font-size: 1.4rem;
    font-weight: 600;
    color: #fff;
    width: fit-content;
    opacity: 0;
    transform: translateY(8px);
    transition:
        opacity 0.3s ease 0.05s,
        transform 0.3s ease 0.05s,
        background 0.2s ease,
        color 0.2s ease;
}

.animals-card:hover .animals-card__btn {
    opacity: 1;
    transform: translateY(0);
}

.animals-card__btn:hover {
    background: #fff;
    color: #000;
}

/* ── Testimonial ── */
.testimonial {
    margin-top: 100px;
    padding: 80px 0;
    /* background: #f1f8e9; */
    background: linear-gradient(180deg, #faf3e0 0%, #efe1c6 100%);
}

.testimonial__top {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 60px;
}

.testimonial__label {
    font-family: "sen", sans-serif;
    font-weight: 600;
    font-size: 1.6rem;
    color: #5e6085;
    margin-bottom: 15px;
}

.testimonial__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    align-items: start;
}

/* Card */
.testimonial-item {
    padding: 36px 32px;
    background: #fff;
    border-radius: 20px;
    border: 1px solid rgba(0, 0, 0, 0.15);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
    /* position: relative; */
}

.testimonial-item.visible:hover {
    transform: translateY(-10px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.1);
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

/* Card giữa nổi bật hơn */
.testimonial-item.testimonial-item--highlight.visible {
    background: linear-gradient(135deg, #8d6e63 0%, #6d4c41 100%);
    border-color: transparent;
    transform: translateY(-12px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

.testimonial-item--highlight.visible:hover {
    transform: translateY(-18px);
    box-shadow: 0 28px 60px rgba(0, 0, 0, 0.4);
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

.testimonial-item--highlight .testimonial-item__quote,
.testimonial-item--highlight .testimonial-item__content,
.testimonial-item--highlight .testimonial-item__name {
    color: #fff;
}

.testimonial-item--highlight .testimonial-item__role {
    color: rgba(255, 255, 255, 0.75);
}

/* Quote mark */
.testimonial-item__quote {
    display: block;
    font-family: "poppins", sans-serif;
    font-size: 8rem;
    font-weight: 700;
    color: #af9b4c;
    line-height: 0.8;
    margin-bottom: 20px;
    opacity: 0.4;
}

/* Content */
.testimonial-item__content {
    font-size: 1.5rem;
    line-height: 1.8;
    color: #656689;
    font-style: italic;
    margin-bottom: 28px;
}

/* Author */
.testimonial-item__author {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-top: 20px;
    border-top: 1px solid rgba(76, 175, 80, 0.15);
}

.testimonial-item--highlight .testimonial-item__author {
    border-top-color: rgba(255, 255, 255, 0.25);
}

.testimonial-item__name {
    font-family: "sen", sans-serif;
    font-weight: 600;
    font-size: 1.5rem;
    color: #2d2d2d;
}

.testimonial-item__role {
    font-size: 1.3rem;
    color: #656689;
}

/*---------- Footer ----------*/
.footer {
    margin-top: 102px;
    background: linear-gradient(to right, #faf3e0 42%, transparent 42%);
}

.footer__inner {
    display: flex;
}

.footer__left {
    padding: 114px 0 148px;
    width: 42%;
}

.footer__left .logo span {
    color: #000;
}

.footer__right {
    flex: 1;
    padding: 52px 0 48px 0;
}

.subscribe-form {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 34px 0 68px;
    width: 268px;
    height: 46px;
    border: 1px solid rgba(0, 0, 0, 0.4);
    border-radius: 99px;
    background: #fff;
}

.subscribe-form__input {
    width: 100%;
    height: 100%;
    padding: 0 22px;
    border: none;
    outline: none;
    border-radius: inherit;
    font-size: 1.4rem;
}

.subscribe-form__input::placeholder {
    font-weight: 300;
    font-size: 1.2rem;
    line-height: 1.17;
    color: #656689;
    opacity: 0.8;
}

.subscribe-form__submit {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-right: -1px;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: #000;
    box-shadow: 0px 13px 26px -8px rgba(0, 0, 0, 0.42);
    outline: none;
    border: none;
}

.subscribe-form__submit:hover {
    opacity: 0.9;
    cursor: pointer;
}

.footer__heading {
    font-weight: 600;
    font-size: 1.8rem;
    line-height: 1.11;
    color: #000;
}

.social-list {
    display: flex;
    column-gap: 16px;
    margin-top: 16px;
}

.social-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #fff;
}

.footer__row {
    display: grid;
    grid-template-columns: auto auto;
    gap: 58px 137px;
    margin-left: 129px;
}

.footer__list {
    margin-top: 14px;
}

.footer__link {
    font-size: 1.4rem;
    line-height: 2;
    color: #656689;
}

.footer__link:hover {
    text-decoration: underline;
}

.footer__copyright {
    margin: 52px 0 0 22px;
    font-weight: 400;
    font-size: 1.2rem;
    line-height: 1.17;
    color: #656689;
    opacity: 0.5;
}
/* ── Hero fade-in sáng lên ── */
@keyframes heroReveal {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

@keyframes overlayFade {
    0% {
        background: rgba(0, 0, 0, 0);
    }
    40% {
        background: rgba(255, 255, 255, 0.15);
    } /* sáng lên */
    100% {
        background: rgba(0, 0, 0, 0.3);
    } /* về bình thường */
}

.hero__background {
    animation: heroReveal 1.2s ease forwards;
}

.hero__overlay {
    animation: overlayFade 2.5s ease forwards;
}

/* ── Hero content xuất hiện từ dưới lên ── */
@keyframes slideUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero__title {
    animation: slideUp 0.8s ease 0.8s both;
}

.hero__desc {
    animation: slideUp 0.8s ease 1.1s both;
}

.hero__btn {
    animation: slideUp 0.8s ease 1.4s both;
}

/* ── Scroll animation ── */
.gallery-hero,
.gallery-hero__item,
.animals-card,
.testimonial-item {
    opacity: 0;
    transform: translateY(40px);
    transition:
        opacity 0.7s ease,
        transform 0.7s ease;
}

.gallery-hero__item:nth-child(2) {
    transition-delay: 0.05s;
}
.gallery-hero__item:nth-child(3) {
    transition-delay: 0.1s;
}
.gallery-hero__item:nth-child(4) {
    transition-delay: 0.15s;
}
.gallery-hero__item:nth-child(5) {
    transition-delay: 0.2s;
}
.gallery-hero__item:nth-child(6) {
    transition-delay: 0.25s;
}

.animals-card:nth-child(2) {
    transition-delay: 0.1s;
}
.animals-card:nth-child(3) {
    transition-delay: 0.2s;
}
.animals-card:nth-child(4) {
    transition-delay: 0.3s;
}

.testimonial-item:nth-child(1) {
    transform: translateX(-40px);
}

.testimonial-item:nth-child(3) {
    transform: translateX(40px);
}

.testimonial-item:nth-child(2) {
    transition-delay: 0.1s;
}

.gallery-hero.visible,
.gallery-hero__item.visible,
.animals-card.visible,
.testimonial-item.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Hover gallery item ── */
.gallery-hero__item {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.gallery-hero__item.visible:hover {
    transform: translateY(-4px);
}
/* ==================== MOBILE RESPONSIVE ==================== */

@media (max-width: 768px) {
    html {
        font-size: 60%;
    }

    .container {
        max-width: calc(100% - 32px);
    }

    /* Header */
    .navbar__list {
        display: none; /* Sẽ hiện khi có hamburger */
    }

    .search-form__input {
        width: 160px;
    }

    /* Hero */
    .hero__title {
        font-size: 4.2rem;
        line-height: 1.1;
    }

    .hero__desc {
        font-size: 1.7rem;
    }

    .hero__btn a {
        padding: 16px 32px;
    }

    /* Gallery */
    .gallery-hero {
        padding: 60px 0;
        margin-top: 60px;
    }

    .gallery-hero__grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(auto-fit, 180px);
        gap: 12px;
    }

    .gallery-hero__item--wide,
    .gallery-hero__item--tall {
        grid-column: span 2;
        grid-row: span 1;
    }

    /* Animals Section */
    .animals {
        margin-top: 60px;
    }

    .animals__grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .animals-card {
        height: 360px;
    }

    .animals-card__name {
        font-size: 2.6rem;
    }

    /* Testimonial */
    .testimonial {
        padding: 60px 0;
    }

    .testimonial__grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    /* Footer */
    .footer__inner {
        flex-direction: column;
    }

    .footer__left {
        width: 100%;
        padding: 60px 0 40px 0;
        text-align: center;
    }

    .footer__row {
        grid-template-columns: 1fr 1fr;
        gap: 40px 20px;
        margin-left: 0;
        justify-items: center;
        text-align: center;
    }

    .footer__copyright {
        margin-top: 30px;
    }
}

@media (max-width: 480px) {
    .gallery-hero__grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .gallery-hero__item--wide,
    .gallery-hero__item--tall {
        grid-column: span 1;
    }

    .hero__title {
        font-size: 3.6rem;
    }

    .search-form__input {
        width: 130px;
    }

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