@import url('https://fonts.googleapis.com/css2?family=Momo+Signature&display=swap');

:root {
    --accent: #d9480f;
    --muted: #6b7280;
    --bg: #f7efe5;
    /* теплий бежовий фон сторінки */
    --card: #fff9f2;
    /* трохи світліший фон карток */
    --radius: 14px;
    --maxw: 1100px;
    font-family: "Titillium Web", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #111827;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    height: 100%;
    background: none;
}

/* відео у варіанті "по всьому екрану" – хай лежить, якщо десь залишився .video-bg */
.video-bg {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 300px;
    max-height: 500px;
    object-fit: cover;
    filter: brightness(0.7);
}

body {
    position: relative;
    transition: none;
    font-family: "Titillium Web", system-ui, -apple-system, BlinkMacSystemFont,
        "Segoe UI", sans-serif;
}

/* бежевий фон під усім контентом */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    background: linear-gradient(180deg,
            #f7eee3 0%,
            #fff7ec 55%,
            #ffffff 100%);
    z-index: -2;
}

/* шапка */
header {
    background: #fffaf4;
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.08);
    position: sticky;
    top: 0;
    z-index: 60;
}

/* загальний контейнер */
.wrap {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 24px;
}

/* ПРИБИРАЄМО ВІДСТУП ВІД ШАПКИ ДО HERO */
main.wrap {
    padding: 0 24px 24px;
}

header nav a {
    color: #d9480f;
}

header nav a:hover {
    color: #b93908;
}

nav {
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
}

.brand {
    display: flex;
    gap: 14px;
    align-items: center;
    background: transparent;
}

.logo {
    border-radius: 50%;
    width: 64px;
    height: 64px;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--accent);
    box-shadow: 0 6px 18px rgba(217, 72, 15, 0.08);
}

.logo img {
    width: 64px;
    height: 64px;
    object-fit: cover;
}

/* Desktop nav */
.navlinks {
    display: flex;
    gap: 12px;
}

.navlinks a {
    color: var(--accent);
    text-decoration: none;
    padding: 8px 6px;
    display: inline-block;
}

/* Hamburger (hidden on desktop) */
.hamburger {
    display: none;
    flex-direction: column;
    width: 44px;
    height: 36px;
    background: transparent;
    border: 0;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.hamburger span {
    display: block;
    width: 26px;
    height: 3px;
    background: #333;
    border-radius: 3px;
    transition: transform .25s, opacity .2s;
}

/* Mobile full-screen menu */
.mobile-menu {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(6px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translateY(-10px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .28s ease, transform .28s ease;
}

.mobile-menu.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.mobile-menu-inner {
    display: flex;
    flex-direction: column;
    gap: 16px;
    text-align: center;
    padding: 28px;
}

.mobile-link {
    font-size: 22px;
    font-weight: 600;
    color: #333;
    text-decoration: none;
    padding: 12px 20px;
    border-radius: 10px;
}

.mobile-link:hover {
    background: #f7f7f7;
    color: var(--accent);
}

.mobile-close {
    position: absolute;
    top: 18px;
    right: 18px;
    background: transparent;
    border: 0;
    font-size: 26px;
    cursor: pointer;
}

/* ================= HERO + ВІДЕО ================= */

.hero {
    margin-top: 0;
    position: relative;
    height: 430px;
    /* висота на мобільних/стандарт */
    overflow: hidden;
    margin-top: 0 !important;
    padding-top: 0 !important;

    /* full-width hero – виходимо за межі .wrap */
    width: 100vw;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

@media (min-width: 900px) {
    .hero {
        height: 480px;
    }
}

header+main.wrap {
    padding-top: 0 !important;
}

header+main.wrap .hero {
    margin-top: -1px !important;
    padding-top: 0 !important;
}

.hero-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.7);
    z-index: -1;
}

.hero-content {
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 32px 16px 28px !important;
    color: #fff;
    text-align: center;
}

@media (min-width: 900px) {
    .hero-content {
        max-width: 540px;
        margin: 0 auto;
    }
}

.hero-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
}

.hero h1 {
    font-family: "Momo Signature", cursive;
    font-weight: 200;
    font-style: normal;
    font-size: 32px;
    color: white;
    margin: 0 0 12px;
}

.hero p {
    margin: 0 0 18px;
    color: white;
}

.hero-link {
    color: #7b4b2a !important;
    font-weight: 600;
}

.hero-link:hover {
    color: #5a341d !important;
}

/* ================= КАРТКИ / ТЕКСТ ================= */

.card {
    text-align: center;
    background: var(--card);
    border-radius: var(--radius);
    padding: 18px;
    box-shadow: 0 8px 30px rgba(15, 23, 42, 0.06);
    white-space: normal;
}

.category-card {
    background: #fff7ec !important;
    border-radius: 24px !important;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12) !important;
}

.category-card h3 {
    color: #4b2b40 !important;
}

.category-card p {
    color: #6b7280 !important;
}

.card,
.category-card {
    background: #fff7ec;
    border-radius: 24px;
}

.categories-wrap {
    background: #fff5eb;
}

.btn {
    background: var(--accent);
    color: white;
    padding: 10px 14px;
    border-radius: 10px;
    border: 0;
    cursor: pointer;
}

section {
    padding: 28px 0;
}

h2 {
    margin: 0 0 12px;
    text-align: center;
}

.grid {
    display: grid;
    gap: 20px;
}

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

.three {
    grid-template-columns: repeat(3, 1fr);
}

.about p {
    color: var(--muted);
    line-height: 1.6;
}

ul {
    margin: 0;
    padding-left: 20px;
}

.price {
    font-weight: 600;
}

/* ================= ГАЛЕРЕЯ / КОНТАКТ ================= */

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
}

.gallery img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 10px;
}

.contact-grid {
    display: flex;
    flex-basis: 100%;
}

.map {
    height: 220px;
    width: 50%;
    padding: 20px;
    border-radius: 30px;
    overflow: hidden;
}

.map iframe {
    border-radius: 10px;
}

.maps {
    display: flex;
    justify-content: space-around;
}

/* footer */

footer {
    text-align: center;
    padding: 24px 0;
    color: var(--muted);
}

/* ================= RESPONSIVE NAV / HERO ================= */

@media (max-width: 900px) {
    .navlinks {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .hero {
        padding: 36px 16px;
    }

    .wrap {
        padding: 16px;
    }
}

/* ================= КАТЕГОРІЇ (Ciasta / Torty / Słodki stół) ================= */

.categories-wrap {
    padding: 28px 0 10px;
    margin-top: 18px !important;
    padding-top: 6px !important;
}

.categories {
    display: flex;
    gap: 26px;
    align-items: flex-start;
    justify-content: center;
    position: relative;
}

.category-card {
    width: 300px;
    min-height: 420px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.08);
    padding: 22px 20px 28px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transform-origin: center;
    transition: transform .36s cubic-bezier(.2, .9, .3, 1), box-shadow .36s, opacity .36s;
    position: relative;
    overflow: visible;
}

/* center card slightly higher */
.card-center {
    margin-top: -8px !important;
    transform: scale(1.02) !important;
    z-index: 30 !important;
}

.card-left,
.card-right {
    margin-top: 0 !important;
    transform: scale(.995) !important;
}

/* hero image у картці */
.category-card .hero-img {
    top: -84px !important;
    height: 150px !important;
    transition: top .25s ease, transform .30s ease !important;
    position: absolute;
    left: 20px;
    right: 20px;
    top: -120px;
    height: 160px;
    border-radius: 12px;
    background-size: cover;
    background-position: center;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.12);
    transition: transform .45s;
}

/* badges */
.badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 10px;
    background: #d6e8d0;
    color: #2f5a12;
    font-weight: 700;
    margin-bottom: 12px;
    font-size: 13px;
}

.badge-pink {
    background: #f6dcdf;
    color: #792235;
}

.badge-rose {
    background: #f3e2e6;
    color: #7b2340;
}

.badge-green {
    background: #d6e8d0;
    color: #436b1a;
}

.category-card h3 {
    font-size: 20px;
    margin: 6px 0 8px;
    color: #4b2b40;
}

.category-card p {
    color: #6b7280;
    line-height: 1.45;
    font-size: 14px;
    padding: 0 6px;
    margin-bottom: 16px;
}

.cat-btn {
    background-color: #7aa84a !important;
    color: #ffffff !important;
    border: none !important;
    padding: 10px 18px;
    border-radius: 28px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 22px rgba(107, 138, 58, 0.12);
    width: 86%;
}

.cat-btn:active {
    transform: translateY(1px);
}

.cat-btn:hover {
    background-color: #6a943f !important;
    color: #f5f5f5 !important;
}

/* hover */
.category-card:hover {
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 30px 90px rgba(15, 23, 42, 0.16);
}

.category-card:hover .hero-img {
    transform: translateY(0) scale(1.02);
}

/* stack categories on mobile */
@media (max-width: 980px) {
    .categories {
        flex-direction: column;
        align-items: center;
    }

    .category-card,
    .card-left,
    .card-center,
    .card-right {
        width: 94%;
        margin-top: 0;
        transform: none;
        z-index: unset;
    }

    .category-card .hero-img {
        top: -90px;
        height: 300px;
        left: 18px;
        right: 18px;
    }

    .category-card {
        padding-top: 36px;
    }

    .cat-btn {
        width: 100%;
        max-width: 420px;
    }
}

/* ================= ДРІБНІ МОБІЛЬНІ ФІКСИ ================= */

/* менші відступи секцій, менше пустоти */
section {
    padding: 18px 0;
}

/* карта / карти */
.map {
    height: 220px;
    border-radius: 12px;
    overflow: hidden;
}

.map iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* трохи менше падінгів у футері */
footer {
    padding: 18px 0;
}

/* Щоб не було відступу між hero і картками на мобільних */
@media (max-width: 980px) {

    .card-center,
    .card-left,
    .card-right {
        margin-top: 0 !important;
        transform: none !important;
    }

    .category-card {
        padding-top: 76px !important;
    }

    .category-card .hero-img {
        top: -72px !important;
        height: 120px !important;
    }

    .hero {
        padding-bottom: 28px !important;
    }
}

/* адаптація картинок всередині карток – останній варіант */
.category-card {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    overflow: hidden !important;
    position: relative !important;
    padding: 22px 20px 28px !important;
    border-radius: 16px !important;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08) !important;
}

.category-card .hero-img {
    position: relative !important;
    order: -1 !important;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    transform: none !important;
    width: calc(100% - 40px) !important;
    height: 160px !important;
    margin: 0 20px 16px !important;
    border-radius: 12px !important;
    background-size: cover !important;
    background-position: center center !important;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08) !important;
}

.category-card h3 {
    margin-top: 6px !important;
    margin-bottom: 8px !important;
}

@media (max-width: 980px) {
    .category-card {
        width: 100% !important;
        padding-top: 16px !important;
    }

    .category-card .hero-img {
        height: 300px !important;
        width: 100% !important;
        margin-bottom: 12px !important;
    }

    .maps {
        flex-direction: column;
    }

    .maps .map {
        width: 100%;
    }
}

/* ========== МОБІЛЬНІ: < 480px ========== */

@media (max-width: 480px) {

    .wrap {
        padding-left: 12px !important;
        padding-right: 12px !important;
        padding-bottom: 12px !important;
    }

    section {
        padding: 12px 0 !important;
    }

    /* HERO – БЕЗ margin-top, щоб не було просвіту */
    .hero {
        padding: 28px 12px 24px !important;
        gap: 8px;
        margin-top: 0 !important;
    }

    .hero p {
        font-size: 14px;
        margin: 0 0 12px !important;
    }

    .card {
        padding: 12px !important;
    }

    .card p {
        font-size: 14px;
        line-height: 1.4;
    }

    h2 {
        font-size: 20px !important;
        margin-bottom: 8px !important;
    }

    .category-card {
        width: 100% !important;
        min-height: auto !important;
        padding: 12px 12px 16px !important;
        margin: 6px 0 !important;
    }

    .category-card h3 {
        font-size: 18px !important;
        margin-top: 4px !important;
        margin-bottom: 4px !important;
    }

    .category-card p {
        font-size: 13px;
        margin-bottom: 10px !important;
    }

    .category-card .hero-img {
        height: 230px !important;
        margin: 0 0 10px 0 !important;
    }

    .cat-btn {
        width: 100% !important;
        padding: 8px 12px !important;
        font-size: 12px;
    }

    .two {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    ul {
        padding-left: 18px;
        margin: 6px 0;
    }

    ul li {
        font-size: 14px;
        line-height: 1.3;
    }

    .map {
        height: 160px !important;
        padding: 0 !important;
        margin-bottom: 8px !important;
    }

    .maps {
        flex-direction: column;
        gap: 8px;
    }

    .maps .map {
        width: 100% !important;
    }

    footer {
        padding: 12px 0 !important;
    }

    footer .small {
        font-size: 12px;
    }

    header {
        padding: 0;
    }

    nav {
        padding: 12px;
    }

    .brand {
        gap: 8px;
    }

    .logo {
        width: 48px !important;
        height: 48px !important;
    }

    .logo img {
        width: 48px !important;
        height: 48px !important;
    }

    .brand>div {
        font-size: 13px;
    }

    .btn {
        padding: 8px 12px;
        font-size: 13px;
    }

    a {
        word-break: break-word;
    }

    #address1,
    #address2 {
        margin: 4px 0;
    }

    p {
        margin: 4px 0;
    }

    .price {
        font-size: 14px;
    }

    .muted.small {
        font-size: 12px;
    }
}

/* Дуже малі екрани (< 380px) */
@media (max-width: 380px) {
    .hero h1 {
        font-size: 20px !important;
    }

    .category-card h3 {
        font-size: 16px !important;
    }

    h2 {
        font-size: 18px !important;
    }

    .logo {
        width: 40px !important;
        height: 40px !important;
    }

    .logo img {
        width: 40px !important;
        height: 40px !important;
    }
}