/* ==========================================
   MINA'S SAVEUR - STYLE (logo.jpg)
========================================== */

:root {
    --cream:   #F7E8B5;
    --peach:   #FAD9A0;
    --orange:  #C2602A;
    --orange2: #E07A3A;
    --green:   #7A9A3A;
    --gold:    #D9A441;
    --brown:   #3B2415;
    --muted:   #8A6A4A;
    --white:   #FFFFFF;

    --radius-sm: 12px;
    --radius:    20px;
    --radius-lg: 24px;
    --pill:      999px;

    --shadow:    0 8px 22px rgba(59, 36, 21, .12);
    --shadow-lg: 0 15px 30px rgba(194, 96, 42, .25);

    --ease: .35s cubic-bezier(0.25, 0.8, 0.25, 1);
}

*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 85px;
}

body {
    margin: 0;
    font-family: 'Cairo', sans-serif;
    color: var(--brown);
    background: var(--cream);
    overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
h1, h2, h3, p { margin: 0; }

:focus-visible {
    outline: 3px solid var(--orange);
    outline-offset: 3px;
}

/* ================= BACKGROUND ================= */

.page-bg {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    background: var(--cream);
}

.page-bg::before {
    content: "";
    position: absolute;
    inset: -15%;
    background: url("logo.jpg") center / 320px repeat;
    opacity: 0.14;
    animation: bgFloat 25s linear infinite;
}

.page-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top, rgba(247, 232, 181, .45), rgba(250, 217, 160, .75));
}

@keyframes bgFloat {
    0%   { transform: translate(0, 0) rotate(0deg); }
    50%  { transform: translate(-30px, -20px) rotate(2deg); }
    100% { transform: translate(0, 0) rotate(0deg); }
}

/* ================= NAVBAR ================= */

.nav {
    position: sticky;
    top: 0;
    z-index: 90;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 10px 24px;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 15px rgba(59, 36, 21, .08);
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 800;
}

.nav-logo-box {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--orange);
    display: inline-block;
    transition: transform var(--ease);
}

.nav-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.65);
    display: block;
}

.brand:hover .nav-logo-box {
    transform: rotate(12deg) scale(1.08);
}

.brand b { color: var(--orange); }

.nav-links {
    display: none;
    gap: 24px;
    font-weight: 700;
}

.nav-links a {
    position: relative;
    transition: color var(--ease);
}

.nav-links a::after {
    content: "";
    position: absolute;
    bottom: -4px;
    right: 0;
    width: 0;
    height: 3px;
    border-radius: var(--pill);
    background: var(--orange);
    transition: width var(--ease);
}

.nav-links a:hover { color: var(--orange); }
.nav-links a:hover::after { width: 100%; }

/* ================= HERO & LOGO ANIMATION ================= */

.hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 78vh;
    padding: 50px 16px;
    text-align: center;
}

.hero-logo-wrap {
    position: relative;
    margin-bottom: 18px;
    animation: floatLogo 4s ease-in-out infinite;
}

.hero-logo-wrap::before {
    content: "";
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    background: conic-gradient(from 0deg, var(--orange), var(--gold), var(--green), var(--orange));
    z-index: -1;
    animation: spinRing 8s linear infinite;
}

.hero-logo-box {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--cream);
    box-shadow: 0 12px 30px rgba(194, 96, 42, .35);
}

.hero-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.65);
    display: block;
}

@keyframes floatLogo {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-12px); }
}

@keyframes spinRing {
    to { transform: rotate(360deg); }
}

.hero-top {
    color: var(--orange);
    font-size: 19px;
    font-weight: 800;
    background: rgba(255, 255, 255, .85);
    padding: 6px 18px;
    border-radius: var(--pill);
    box-shadow: 0 4px 12px rgba(59, 36, 21, .08);
}

.hero-text {
    color: var(--brown);
    font-size: 22px;
    font-weight: 800;
    margin: 14px 0 24px;
}

.hero-title {
    margin: 8px 0;
    font-size: clamp(44px, 8.5vw, 90px);
    font-weight: 900;
    line-height: 1.25;
    background: linear-gradient(90deg, var(--brown), var(--orange), var(--gold), var(--green), var(--brown));
    background-size: 300% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: titleShine 6s linear infinite;
}

@keyframes titleShine {
    to { background-position: 300% center; }
}

.title-line {
    width: 180px;
    height: 5px;
    border-radius: var(--pill);
    background: linear-gradient(90deg, var(--orange), var(--gold), var(--green));
}

.hero-btns {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
}

/* ================= SCROLL REVEAL ANIMATION ================= */

.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity .7s ease, transform .7s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ================= PANELS / SECTIONS ================= */

.section {
    max-width: 1100px;
    margin: 0 auto 36px;
    padding: 40px 20px;
}

.panel {
    background: rgba(255, 255, 255, .88);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    border: 1px solid rgba(255, 255, 255, .6);
}

.section h2 {
    text-align: center;
    font-size: 32px;
    color: var(--brown);
}

.sub {
    text-align: center;
    color: var(--muted);
    margin-top: 4px;
}

/* ================= BUTTONS ================= */

.btn {
    display: inline-block;
    padding: 12px 22px;
    border: 2px solid var(--orange);
    border-radius: var(--pill);
    background: var(--orange);
    color: var(--white);
    font-family: inherit;
    font-weight: 800;
    cursor: pointer;
    transition: all var(--ease);
}

.btn:hover {
    background: var(--orange2);
    border-color: var(--orange2);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(194, 96, 42, .3);
}

.btn:active { transform: scale(.96); }

.btn.ghost {
    background: var(--white);
    color: var(--orange);
}

.btn.ghost:hover {
    background: var(--orange);
    color: var(--white);
}

.btn.big  { padding: 14px 28px; font-size: 18px; }
.btn.full { width: 100%; font-size: 18px; }

/* ================= PRODUCTS ================= */

.filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin: 22px 0;
}

.filter {
    padding: 9px 22px;
    border: 2px solid var(--orange);
    border-radius: var(--pill);
    background: var(--white);
    color: var(--brown);
    font-family: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--ease);
}

.filter:hover,
.filter.active {
    background: var(--orange);
    color: var(--white);
    transform: translateY(-2px);
}

.grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.card {
    padding-bottom: 16px;
    overflow: hidden;
    text-align: center;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    transition: transform var(--ease), box-shadow var(--ease);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.card-img-wrap {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.card img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform .5s ease;
}

.card-img-wrap:hover img {
    transform: scale(1.08);
}

.gallery-badge {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: rgba(59, 36, 21, .82);
    color: var(--cream);
    font-size: 12px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: var(--pill);
    backdrop-filter: blur(4px);
    transition: background var(--ease);
}

.card-img-wrap:hover .gallery-badge {
    background: var(--orange);
    color: var(--white);
}

.card h3 {
    margin: 12px 10px 4px;
    font-size: 18px;
}

.desc {
    margin: 0 12px;
    color: var(--muted);
    font-size: 14px;
}

.price-row {
    margin: 8px 0;
    color: var(--orange);
    font-size: 20px;
    font-weight: 900;
}

.qty {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 14px;
    margin: 8px 0 12px;
}

.qty button {
    width: 32px;
    height: 32px;
    border: 1px solid #EAD9B8;
    border-radius: 50%;
    background: var(--cream);
    color: var(--brown);
    font-size: 18px;
    font-weight: 800;
    cursor: pointer;
    transition: all var(--ease);
}

.qty button:hover {
    background: var(--orange);
    color: var(--white);
}

.q { min-width: 20px; font-weight: 700; }

/* ================= MODAL GALLERY ================= */

.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease, visibility .3s ease;
}

.modal.open {
    opacity: 1;
    visibility: visible;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(59, 36, 21, .75);
    backdrop-filter: blur(6px);
}

.modal-content {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 560px;
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, .35);
    transform: scale(.9);
    transition: transform .35s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.modal.open .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 10;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(59, 36, 21, .8);
    color: var(--white);
    font-size: 18px;
    cursor: pointer;
    transition: background var(--ease);
}

.modal-close:hover { background: var(--orange); }

.modal-slider {
    position: relative;
    background: var(--cream);
    height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-slider img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity .25s ease;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, .9);
    color: var(--brown);
    font-size: 18px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
    transition: all var(--ease);
}

.slider-btn:hover { background: var(--orange); color: var(--white); }
.slider-btn.prev { right: 12px; }
.slider-btn.next { left: 12px; }

.modal-thumbs {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 12px;
    background: #FFF9EB;
}

.modal-thumbs img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 10px;
    cursor: pointer;
    opacity: .6;
    border: 2px solid transparent;
    transition: all var(--ease);
}

.modal-thumbs img.active,
.modal-thumbs img:hover {
    opacity: 1;
    border-color: var(--orange);
    transform: scale(1.06);
}

.modal-info {
    padding: 18px 22px 22px;
}

.modal-info h3 { font-size: 22px; margin-bottom: 6px; }
.modal-info p  { color: var(--muted); font-size: 15px; margin-bottom: 14px; }

.modal-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ================= CART & FORM ================= */

.cart-box {
    margin: 18px 0;
    padding: 16px;
    background: #FFF6DE;
    border: 2px dashed var(--orange);
    border-radius: var(--radius);
}

.cart-box ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(194, 96, 42, .15);
}

.cart-item:last-child { border-bottom: none; }
.cart-name { font-weight: 700; flex: 1; }

.cart-qty {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cart-qty button,
.cart-remove {
    width: 28px;
    height: 28px;
    border: 1px solid var(--orange);
    border-radius: 50%;
    background: var(--white);
    color: var(--orange);
    font-weight: 800;
    cursor: pointer;
}

.cart-remove {
    border-color: #d9534f;
    color: #d9534f;
}

.total {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 2px solid rgba(194, 96, 42, .25);
    color: var(--orange);
    font-size: 20px;
    font-weight: 900;
}

form label {
    display: block;
    margin: 12px 0 6px;
    font-weight: 800;
}

form input,
form textarea {
    width: 100%;
    padding: 13px;
    border: 2px solid #EAD9B8;
    border-radius: var(--radius-sm);
    background: var(--white);
    font-family: inherit;
    font-size: 16px;
    transition: border-color var(--ease), box-shadow var(--ease);
}

form input:focus,
form textarea:focus {
    outline: none;
    border-color: var(--orange);
    box-shadow: 0 0 10px rgba(194, 96, 42, .18);
}

form textarea { resize: vertical; }
form .btn { margin-top: 18px; }

.form-msg {
    margin-top: 12px;
    text-align: center;
    font-weight: 800;
    font-size: 16px;
}

.form-msg.ok    { color: var(--green); }
.form-msg.error { color: #d9534f; }

/* ================= FOOTER ================= */

footer {
    padding: 30px 16px;
    text-align: center;
    line-height: 1.8;
    background: var(--brown);
    color: var(--cream);
}

.footer-logo-box {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--gold);
    margin: 0 auto 10px;
}

.footer-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.65);
    display: block;
}

/* ================= RESPONSIVE ================= */

@media (min-width: 700px) {
    .nav-links { display: flex; }
}

@media (max-width: 900px) {
    .grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
    .grid { grid-template-columns: 1fr; }
    .hero-logo-box { width: 130px; height: 130px; }
    .modal-slider { height: 240px; }
}