:root {
    --primary: #ff5b16;
    --primary-dark: #e94a05;
    --primary-soft: #fff1e9;
    --text: #171717;
    --text-soft: #666666;
    --text-muted: #929292;
    --surface: #ffffff;
    --background: #f7f7f7;
    --border: #e7e7e7;
    --border-strong: #d8d8d8;
    --green: #176f43;
    --shadow-small: 0 5px 18px rgba(20, 20, 20, 0.06);
    --shadow-medium: 0 17px 45px rgba(20, 20, 20, 0.11);
    --radius-small: 12px;
    --radius-medium: 18px;
    --radius-large: 24px;
    --header-height: 72px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text);
    background: var(--surface);
    font-family: Inter, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

body.cart-open {
    overflow: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input {
    font: inherit;
}

button {
    cursor: pointer;
}

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

svg {
    width: 20px;
    height: 20px;
    stroke-width: 2;
}

[hidden] {
    display: none !important;
}

.page-container {
    width: min(100% - 48px, 1440px);
    margin-inline: auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 80;
    height: var(--header-height);
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(18px);
}

.header-inner {
    display: flex;
    height: 100%;
    align-items: center;
}

.brand {
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    gap: 10px;
}

.brand-mark {
    display: grid;
    width: 35px;
    height: 35px;
    place-items: center;
    border-radius: 11px;
    color: white;
    background: var(--primary);
    font-size: 19px;
    font-weight: 800;
}

.brand-name {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.8px;
}

.desktop-navigation {
    display: flex;
    margin-left: 65px;
    align-items: center;
    gap: 32px;
}

.desktop-navigation a {
    position: relative;
    color: #353535;
    font-size: 14px;
    font-weight: 600;
}

.desktop-navigation a.is-active {
    color: var(--primary);
}

.desktop-actions {
    display: flex;
    margin-left: auto;
    align-items: center;
    gap: 10px;
}

.button {
    display: inline-flex;
    min-height: 44px;
    padding: 0 17px;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
}

.button-secondary {
    border-color: var(--border);
    background: white;
}

.header-cart-button,
.mobile-header-cart {
    position: relative;
    display: inline-flex;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 12px;
    background: var(--background);
}

.header-cart-button span,
.mobile-header-cart span {
    position: absolute;
    top: 0;
    right: -1px;
    display: grid;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    place-items: center;
    border: 2px solid white;
    border-radius: 20px;
    color: white;
    background: var(--primary);
    font-size: 9px;
    font-weight: 800;
}

.mobile-back-button,
.mobile-header-cart {
    display: none;
}

.restaurant-hero {
    padding-top: 18px;
}

.restaurant-cover {
    position: relative;
    height: 330px;
    overflow: hidden;
    border-radius: var(--radius-large);
    background-position: center;
    background-size: cover;
}

.cover-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.06),
        rgba(0, 0, 0, 0.28)
    );
}

.cover-actions {
    position: absolute;
    top: 18px;
    right: 18px;
    display: flex;
    gap: 9px;
}

.cover-actions button {
    display: grid;
    width: 43px;
    height: 43px;
    padding: 0;
    place-items: center;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow-small);
}

.cover-actions button.is-active {
    color: white;
    background: var(--primary);
}

.cover-actions button.is-active svg {
    fill: currentColor;
}

.restaurant-summary {
    position: relative;
    display: grid;
    margin: -58px 28px 0;
    padding: 25px;
    grid-template-columns: 116px minmax(0, 1fr);
    gap: 22px;
    border: 1px solid var(--border);
    border-radius: var(--radius-large);
    background: white;
    box-shadow: var(--shadow-medium);
}

.restaurant-logo {
    width: 116px;
    height: 116px;
    overflow: hidden;
    border: 5px solid white;
    border-radius: 24px;
    box-shadow: var(--shadow-small);
}

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

.restaurant-title-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
}

.restaurant-status {
    display: inline-flex;
    min-height: 27px;
    padding: 0 9px;
    align-items: center;
    border-radius: 999px;
    color: var(--green);
    background: #eaf7ef;
    font-size: 9px;
    font-weight: 800;
}

.restaurant-title-row h1 {
    margin: 9px 0 5px;
    font-size: 34px;
    line-height: 1;
    letter-spacing: -1.4px;
}

.restaurant-title-row p {
    margin: 0;
    color: var(--text-soft);
    font-size: 12px;
}

.restaurant-rating {
    display: inline-flex;
    min-height: 34px;
    padding: 0 10px;
    flex-shrink: 0;
    align-items: center;
    gap: 5px;
    border-radius: 10px;
    background: var(--primary-soft);
    font-size: 12px;
    font-weight: 800;
}

.restaurant-rating svg {
    width: 15px;
    height: 15px;
    color: var(--primary);
    fill: var(--primary);
}

.restaurant-description {
    max-width: 820px;
    margin: 14px 0 0;
    color: var(--text-soft);
    font-size: 12px;
    line-height: 1.65;
}

.restaurant-information {
    display: flex;
    margin-top: 16px;
    flex-wrap: wrap;
    gap: 11px 20px;
    color: #535353;
    font-size: 10px;
    font-weight: 600;
}

.restaurant-information span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.restaurant-information svg {
    width: 15px;
    height: 15px;
}

.menu-navigation-section {
    position: sticky;
    top: var(--header-height);
    z-index: 60;
    margin-top: 28px;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(18px);
}

.menu-navigation {
    display: grid;
    min-height: 76px;
    grid-template-columns: 260px minmax(0, 1fr);
    align-items: center;
    gap: 24px;
}

.menu-search {
    display: flex;
    min-height: 44px;
    padding: 0 13px;
    align-items: center;
    gap: 9px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--background);
}

.menu-search svg {
    width: 17px;
    height: 17px;
    color: var(--text-soft);
}

.menu-search input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    font-size: 11px;
}

.category-navigation {
    display: flex;
    gap: 22px;
    overflow-x: auto;
    scrollbar-width: none;
}

.category-navigation::-webkit-scrollbar {
    display: none;
}

.category-navigation a {
    position: relative;
    min-height: 76px;
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    color: var(--text-soft);
    font-size: 11px;
    font-weight: 700;
}

.category-navigation a:hover,
.category-navigation a.is-active {
    color: var(--primary);
}

.category-navigation a.is-active::after {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 3px;
    border-radius: 4px 4px 0 0;
    background: var(--primary);
    content: "";
}

.menu-section {
    padding: 34px 0 70px;
    background: #fafafa;
}

.menu-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 350px;
    align-items: start;
    gap: 28px;
}

.menu-category {
    margin-bottom: 38px;
    scroll-margin-top: 170px;
}

.category-heading {
    display: flex;
    margin-bottom: 16px;
    align-items: flex-end;
    justify-content: space-between;
}

.category-heading h2 {
    margin: 0;
    font-size: 25px;
    letter-spacing: -0.8px;
}

.category-heading p {
    margin: 5px 0 0;
    color: var(--text-muted);
    font-size: 10px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
}

.product-card {
    display: grid;
    min-height: 190px;
    overflow: hidden;
    grid-template-columns: minmax(0, 1fr) 165px;
    border: 1px solid var(--border);
    border-radius: var(--radius-medium);
    background: white;
    box-shadow: var(--shadow-small);
    transition: 180ms ease;
}

.product-card:hover {
    border-color: #dadada;
    box-shadow: var(--shadow-medium);
    transform: translateY(-2px);
}

.product-content {
    display: flex;
    min-width: 0;
    padding: 17px;
    align-items: flex-start;
    flex-direction: column;
}

.popular-label {
    display: inline-flex;
    min-height: 24px;
    padding: 0 8px;
    align-items: center;
    border-radius: 999px;
    color: var(--primary);
    background: var(--primary-soft);
    font-size: 8px;
    font-weight: 800;
}

.product-content h3 {
    margin: 10px 0 7px;
    font-size: 16px;
    line-height: 1.25;
}

.product-content p {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--text-soft);
    font-size: 10px;
    line-height: 1.55;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.product-content > strong {
    margin-top: 12px;
    font-size: 14px;
}

.add-product-button {
    display: inline-flex;
    min-height: 35px;
    margin-top: auto;
    padding: 0 11px;
    align-items: center;
    gap: 5px;
    border: 0;
    border-radius: 10px;
    color: white;
    background: var(--primary);
    font-size: 9px;
    font-weight: 800;
}

.add-product-button:hover {
    background: var(--primary-dark);
}

.add-product-button svg {
    width: 14px;
    height: 14px;
}

.product-image {
    overflow: hidden;
}

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

.desktop-cart {
    position: sticky;
    top: 168px;
}

.cart-card {
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: var(--radius-large);
    background: white;
    box-shadow: var(--shadow-small);
}

.cart-header {
    display: flex;
    min-height: 74px;
    padding: 0 18px;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
}

.cart-header h2 {
    margin: 0;
    font-size: 18px;
}

.cart-header p {
    margin: 4px 0 0;
    color: var(--text-soft);
    font-size: 9px;
}

.cart-header > span {
    color: var(--text-muted);
    font-size: 9px;
    font-weight: 700;
}

.cart-empty {
    display: grid;
    min-height: 330px;
    padding: 30px;
    place-items: center;
    align-content: center;
    text-align: center;
}

.cart-empty > span {
    display: grid;
    width: 62px;
    height: 62px;
    place-items: center;
    border-radius: 50%;
    color: var(--primary);
    background: var(--primary-soft);
}

.cart-empty h3 {
    margin: 17px 0 7px;
    font-size: 16px;
}

.cart-empty p {
    max-width: 230px;
    margin: 0;
    color: var(--text-soft);
    font-size: 10px;
    line-height: 1.55;
}

.cart-content {
    padding: 16px;
}

.cart-items {
    display: grid;
    max-height: 330px;
    gap: 12px;
    overflow-y: auto;
}

.cart-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
}

.cart-item h4 {
    margin: 0;
    font-size: 11px;
}

.cart-item p {
    margin: 4px 0 0;
    color: var(--text-soft);
    font-size: 9px;
}

.quantity-control {
    display: inline-flex;
    margin-top: 8px;
    align-items: center;
    gap: 9px;
}

.quantity-control button {
    display: grid;
    width: 25px;
    height: 25px;
    padding: 0;
    place-items: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: white;
}

.quantity-control button svg {
    width: 13px;
    height: 13px;
}

.quantity-control span {
    min-width: 17px;
    text-align: center;
    font-size: 9px;
    font-weight: 800;
}

.cart-item > strong {
    font-size: 10px;
}

.cart-totals {
    display: grid;
    margin-top: 16px;
    padding-top: 14px;
    gap: 11px;
    border-top: 1px solid var(--border);
}

.cart-totals > div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--text-soft);
    font-size: 10px;
}

.cart-total-row {
    padding-top: 10px;
    border-top: 1px solid var(--border);
    color: var(--text) !important;
    font-size: 13px !important;
}

.minimum-warning {
    margin-top: 13px;
    padding: 10px;
    border-radius: 10px;
    color: #8a5319;
    background: #fff6e5;
    font-size: 9px;
    line-height: 1.5;
    text-align: center;
}

.minimum-warning.is-complete {
    color: var(--green);
    background: #eaf7ef;
}

.checkout-button {
    display: flex;
    width: 100%;
    min-height: 48px;
    margin-top: 13px;
    padding: 0 15px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 0;
    border-radius: 12px;
    color: white;
    background: var(--primary);
    font-size: 11px;
    font-weight: 800;
}

.checkout-button:disabled {
    cursor: not-allowed;
    opacity: 0.45;
}

.checkout-button svg {
    width: 16px;
    height: 16px;
}

.menu-empty {
    display: grid;
    min-height: 350px;
    place-items: center;
    align-content: center;
    text-align: center;
}

.menu-empty svg {
    width: 48px;
    height: 48px;
    color: var(--primary);
}

.menu-empty h3 {
    margin: 16px 0 6px;
}

.menu-empty p {
    margin: 0;
    color: var(--text-soft);
    font-size: 11px;
}

.mobile-cart-bar,
.mobile-cart-sheet {
    display: none;
}

@media (max-width: 1180px) {
    .desktop-navigation {
        margin-left: 35px;
        gap: 20px;
    }

    .menu-layout {
        grid-template-columns: minmax(0, 1fr) 320px;
    }

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

@media (max-width: 860px) {
    :root {
        --header-height: 61px;
    }

    body {
        padding-bottom: 80px;
    }

    .page-container {
        width: 100%;
    }

    .header-inner {
        position: relative;
        padding: 0 16px;
        justify-content: space-between;
    }

    .desktop-navigation,
    .desktop-actions {
        display: none;
    }

    .mobile-back-button,
    .mobile-header-cart {
        display: inline-flex;
    }

    .mobile-back-button {
        width: 40px;
        height: 40px;
        padding: 0;
        align-items: center;
        justify-content: flex-start;
        border: 0;
        background: transparent;
    }

    .header-inner > .brand {
        position: absolute;
        left: 50%;
        gap: 7px;
        transform: translateX(-50%);
    }

    .header-inner > .brand .brand-mark {
        width: 28px;
        height: 28px;
        border-radius: 8px;
        font-size: 15px;
    }

    .header-inner > .brand .brand-name {
        font-size: 19px;
    }

    .restaurant-hero {
        padding: 0;
    }

    .restaurant-cover {
        height: 220px;
        border-radius: 0;
    }

    .cover-actions {
        top: 13px;
        right: 13px;
    }

    .cover-actions button {
        width: 38px;
        height: 38px;
    }

    .restaurant-summary {
        margin: -42px 14px 0;
        padding: 16px;
        grid-template-columns: 78px minmax(0, 1fr);
        gap: 13px;
        border-radius: 20px;
    }

    .restaurant-logo {
        width: 78px;
        height: 78px;
        border-radius: 18px;
    }

    .restaurant-title-row h1 {
        margin-top: 7px;
        font-size: 23px;
        letter-spacing: -0.8px;
    }

    .restaurant-title-row p {
        font-size: 9px;
    }

    .restaurant-rating {
        min-height: 29px;
        padding: 0 8px;
        font-size: 9px;
    }

    .restaurant-description {
        grid-column: 1 / -1;
        margin-top: 12px;
        font-size: 10px;
    }

    .restaurant-information {
        grid-column: 1 / -1;
        margin-top: 12px;
        gap: 9px 13px;
        font-size: 8px;
    }

    .menu-navigation-section {
        margin-top: 20px;
    }

    .menu-navigation {
        min-height: auto;
        padding: 10px 0 0;
        grid-template-columns: 1fr;
        gap: 3px;
    }

    .menu-search {
        min-height: 45px;
        margin: 0 14px;
    }

    .category-navigation {
        padding: 0 14px;
        gap: 19px;
    }

    .category-navigation a {
        min-height: 52px;
        font-size: 9px;
    }

    .menu-section {
        padding: 24px 14px 35px;
    }

    .menu-layout {
        display: block;
    }

    .desktop-cart {
        display: none;
    }

    .menu-category {
        margin-bottom: 30px;
        scroll-margin-top: 150px;
    }

    .category-heading h2 {
        font-size: 20px;
    }

    .products-grid {
        gap: 11px;
    }

    .product-card {
        min-height: 142px;
        grid-template-columns: minmax(0, 1fr) 116px;
        border-radius: 15px;
    }

    .product-content {
        padding: 13px;
    }

    .popular-label {
        min-height: 21px;
        font-size: 7px;
    }

    .product-content h3 {
        margin: 8px 0 5px;
        font-size: 13px;
    }

    .product-content p {
        font-size: 8px;
        -webkit-line-clamp: 2;
    }

    .product-content > strong {
        margin-top: 8px;
        font-size: 11px;
    }

    .add-product-button {
        min-height: 31px;
        padding: 0 9px;
        font-size: 8px;
    }

    .mobile-cart-bar {
        position: fixed;
        right: 12px;
        bottom: calc(12px + env(safe-area-inset-bottom));
        left: 12px;
        z-index: 90;
        display: grid;
        min-height: 58px;
        padding: 0 16px;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        gap: 11px;
        border: 0;
        border-radius: 16px;
        color: white;
        background: var(--primary);
        box-shadow: var(--shadow-medium);
        font-size: 11px;
        font-weight: 800;
    }

    .mobile-cart-count {
        display: grid;
        min-width: 27px;
        height: 27px;
        padding: 0 6px;
        place-items: center;
        border-radius: 9px;
        color: var(--primary);
        background: white;
    }

    .mobile-cart-bar > span:nth-child(2) {
        text-align: left;
    }

    .mobile-cart-sheet {
        position: fixed;
        inset: 0;
        z-index: 150;
        display: block;
        pointer-events: none;
        visibility: hidden;
    }

    .mobile-cart-sheet.is-open {
        pointer-events: auto;
        visibility: visible;
    }

    .cart-sheet-overlay {
        position: absolute;
        inset: 0;
        padding: 0;
        border: 0;
        opacity: 0;
        background: rgba(0, 0, 0, 0.48);
        transition: opacity 220ms ease;
    }

    .mobile-cart-sheet.is-open .cart-sheet-overlay {
        opacity: 1;
    }

    .cart-sheet-panel {
        position: absolute;
        right: 0;
        bottom: 0;
        left: 0;
        display: flex;
        max-height: 88vh;
        padding-bottom: env(safe-area-inset-bottom);
        flex-direction: column;
        border-radius: 24px 24px 0 0;
        background: white;
        transform: translateY(105%);
        transition: transform 250ms ease;
    }

    .mobile-cart-sheet.is-open .cart-sheet-panel {
        transform: translateY(0);
    }

    .cart-sheet-handle {
        width: 42px;
        height: 4px;
        margin: 10px auto 5px;
        border-radius: 999px;
        background: #d9d9d9;
    }

    .cart-sheet-header {
        display: flex;
        padding: 12px 16px 15px;
        align-items: center;
        justify-content: space-between;
        border-bottom: 1px solid var(--border);
    }

    .cart-sheet-header h2 {
        margin: 0;
        font-size: 18px;
    }

    .cart-sheet-header p {
        margin: 4px 0 0;
        color: var(--text-soft);
        font-size: 9px;
    }

    .cart-sheet-header button {
        display: grid;
        width: 38px;
        height: 38px;
        padding: 0;
        place-items: center;
        border: 0;
        border-radius: 12px;
        background: var(--background);
    }

    .mobile-cart-items {
        display: grid;
        min-height: 120px;
        max-height: 42vh;
        padding: 16px;
        gap: 14px;
        overflow-y: auto;
    }

    .mobile-cart-summary {
        padding: 15px 16px;
        border-top: 1px solid var(--border);
        background: white;
    }

    .mobile-cart-summary > div {
        display: flex;
        margin-bottom: 10px;
        align-items: center;
        justify-content: space-between;
        color: var(--text-soft);
        font-size: 10px;
    }

    .mobile-total-row {
        padding-top: 11px;
        border-top: 1px solid var(--border);
        color: var(--text) !important;
        font-size: 13px !important;
    }

    .mobile-cart-summary p {
        margin: 11px 0;
        padding: 9px;
        border-radius: 10px;
        color: #8a5319;
        background: #fff6e5;
        font-size: 8px;
        text-align: center;
    }

    .mobile-cart-summary p.is-complete {
        color: var(--green);
        background: #eaf7ef;
    }

    .mobile-cart-summary > button {
        display: flex;
        width: 100%;
        min-height: 49px;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border: 0;
        border-radius: 13px;
        color: white;
        background: var(--primary);
        font-size: 11px;
        font-weight: 800;
    }

    .mobile-cart-summary > button:disabled {
        opacity: 0.45;
    }
}
