@import url("https://fonts.googleapis.com/css2?family=Gowun+Batang:wght@400;700&family=IBM+Plex+Sans+KR:wght@300;400;500;600;700&display=swap");

:root {
    --bg: #f5f8fb;
    --surface: rgba(255, 255, 255, 0.86);
    --surface-strong: #ffffff;
    --text: #1f2a37;
    --text-muted: #64748b;
    --line: rgba(15, 23, 42, 0.12);
    --primary: #0f766e;
    --primary-strong: #0d9488;
    --accent: #f97316;
    --accent-strong: #ea580c;
    --danger: #dc2626;
    --danger-strong: #b91c1c;
    --success: #16a34a;
    --control-height: 42px;
    --control-padding-x: 16px;
    --radius-lg: 22px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --shadow-lg: 0 24px 40px rgba(15, 23, 42, 0.12);
    --shadow-md: 0 12px 24px rgba(15, 23, 42, 0.08);
    --shadow-sm: 0 4px 12px rgba(15, 23, 42, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    font-family: "IBM Plex Sans KR", sans-serif;
    line-height: 1.65;
    color: var(--text);
    background: radial-gradient(circle at 15% 20%, rgba(14, 165, 164, 0.18), transparent 35%),
        radial-gradient(circle at 88% 12%, rgba(249, 115, 22, 0.16), transparent 32%),
        radial-gradient(circle at 70% 80%, rgba(59, 130, 246, 0.12), transparent 30%),
        var(--bg);
    display: flex;
    flex-direction: column;
}

a {
    color: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.72);
    border-bottom: 1px solid rgba(255, 255, 255, 0.5);
}

.header-inner {
    width: min(1200px, 94vw);
    margin: 0 auto;
    padding: 16px 0;
    display: flex;
    align-items: center;
    gap: 18px;
}

.brand {
    font-family: "Gowun Batang", serif;
    font-size: 1.45rem;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.brand a {
    text-decoration: none;
    color: var(--text);
}

.brand-page {
    font-size: 0.95rem;
    color: var(--text-muted);
    font-family: "IBM Plex Sans KR", sans-serif;
    font-weight: 500;
    margin-left: 8px;
}

.nav-toggle {
    margin-left: auto;
    display: none;
    border: 1px solid var(--line);
    background: var(--surface-strong);
    border-radius: 999px;
    padding: 7px 16px;
    font-size: 0.88rem;
    cursor: pointer;
}

.site-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.site-nav > a,
.site-nav > details,
.site-nav > form {
    animation: fade-up 0.32s ease both;
}

.site-nav a,
.site-nav summary,
.nav-link-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 38px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid transparent;
    color: #0f172a;
    text-decoration: none;
    font-size: 0.92rem;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.58);
    transition: all 0.24s ease;
}

.site-nav a:hover,
.site-nav summary:hover,
.nav-link-button:hover {
    transform: translateY(-1px);
    background: #ffffff;
    border-color: rgba(15, 118, 110, 0.28);
    box-shadow: var(--shadow-sm);
}

.site-nav a.active-link {
    color: #0f766e;
    border-color: rgba(15, 118, 110, 0.35);
    background: rgba(15, 118, 110, 0.1);
    font-weight: 700;
}

.nav-link-button {
    border: none;
    font: inherit;
}

.site-nav form {
    display: inline-flex;
}

.nav-dropdown {
    position: relative;
}

.nav-dropdown summary {
    list-style: none;
}

.nav-dropdown summary::-webkit-details-marker {
    display: none;
}

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 200px;
    padding: 10px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: var(--shadow-md);
    display: none;
}

.nav-dropdown[open] .nav-dropdown-menu {
    display: grid;
    gap: 4px;
}

.nav-dropdown-menu a {
    justify-content: flex-start;
    background: transparent;
    border-radius: 10px;
    height: 36px;
}

main {
    width: min(1200px, 94vw);
    margin: 24px auto 34px;
    padding: 28px;
    border-radius: var(--radius-lg);
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.72);
    box-shadow: var(--shadow-lg);
    flex: 1;
    animation: fade-up 0.36s ease both;
}

h1, h2, h3 {
    font-family: "Gowun Batang", serif;
    color: #0f172a;
}

h2 {
    font-size: clamp(1.42rem, 2vw, 2rem);
    margin-bottom: 14px;
}

h3 {
    font-size: clamp(1.1rem, 1.6vw, 1.35rem);
}

p {
    color: var(--text);
}

.catalog-main {
    display: grid;
    gap: 20px;
}

.page-hero {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 24px;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(15, 118, 110, 0.18);
    background: linear-gradient(126deg, rgba(15, 118, 110, 0.1), rgba(249, 115, 22, 0.1));
}

.hero-eyebrow {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: #0f766e;
    margin-bottom: 6px;
}

.hero-description {
    color: #0f172a;
    opacity: 0.78;
}

.hero-stats {
    min-width: 240px;
    display: grid;
    gap: 12px;
}

.hero-stat {
    padding: 14px 16px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(15, 23, 42, 0.08);
}

.hero-stat span {
    display: block;
    color: var(--text-muted);
    font-size: 0.84rem;
}

.hero-stat strong {
    font-size: 1.25rem;
    color: #0f172a;
}

.catalog-controls {
    display: grid;
    gap: 12px;
}

.search-form,
.filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 14px;
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.9);
}

input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
textarea,
select {
    min-height: 42px;
    border: 1px solid rgba(15, 23, 42, 0.14);
    border-radius: 10px;
    padding: 9px 12px;
    background: #fff;
    color: var(--text);
    font: inherit;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

textarea {
    min-height: 140px;
    resize: vertical;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: rgba(15, 118, 110, 0.55);
    box-shadow: 0 0 0 4px rgba(15, 118, 110, 0.12);
}

.search-form input[type="text"] {
    flex: 1;
    min-width: 240px;
}

.filter-form select {
    min-width: 140px;
    flex: 1;
}

.button-link,
button[type="submit"],
.secondary-button,
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    text-align: center;
    line-height: 1.2;
    font-family: inherit;
    white-space: nowrap;
    appearance: none;
    -webkit-appearance: none;
}

.button-link,
button[type="submit"] {
    min-height: var(--control-height);
    padding: 0 var(--control-padding-x);
    border: none;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.93rem;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--primary-strong));
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
    box-shadow: 0 8px 16px rgba(13, 148, 136, 0.22);
}

.button-link:hover,
button[type="submit"]:hover {
    transform: translateY(-1px);
    filter: saturate(1.06);
}

.secondary-button {
    min-height: var(--control-height);
    padding: 0 var(--control-padding-x);
    border: 1px solid rgba(15, 23, 42, 0.15);
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.92rem;
    background: #fff;
    color: #0f172a;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.secondary-button:hover {
    border-color: rgba(15, 118, 110, 0.35);
    box-shadow: var(--shadow-sm);
    transform: translateY(-1px);
}

.delete-button,
.remove-button,
.clear-cart-button {
    background: linear-gradient(135deg, var(--danger), var(--danger-strong));
    box-shadow: 0 8px 16px rgba(220, 38, 38, 0.24);
}

.checkout-button {
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    box-shadow: 0 8px 16px rgba(234, 88, 12, 0.22);
}

.catalog-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
}

.form-actions,
.actions,
.admin-actions,
.qna-actions,
.cart-summary,
.table .action-links {
    align-items: center;
}

.form-actions form,
.actions form,
.admin-actions form,
.qna-actions form,
.cart-summary form,
.table .action-links form,
.inline-button-form {
    display: inline-flex;
    align-items: center;
    margin: 0;
}

.actions > span,
.qna-actions > span {
    display: inline-flex;
    align-items: center;
}

.product-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}

.recent-products-panel {
    display: grid;
    gap: 12px;
    padding: 16px;
    border: 1px solid rgba(15, 23, 42, 0.1);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.86);
}

.recent-products-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
}

.recent-product-item {
    text-decoration: none;
    color: inherit;
    border: 1px solid rgba(15, 23, 42, 0.1);
    border-radius: 12px;
    background: #fff;
    display: grid;
    gap: 8px;
    padding: 10px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.recent-product-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.recent-product-thumb {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid rgba(15, 23, 42, 0.08);
}

.recent-product-name {
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.35;
}

.recent-product-price {
    color: var(--accent-strong);
    font-size: 0.9rem;
    font-weight: 700;
}

.product-item {
    display: flex;
    flex-direction: column;
    border-radius: var(--radius-md);
    overflow: hidden;
    text-decoration: none;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: #fff;
    box-shadow: var(--shadow-sm);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
    animation: fade-up 0.4s ease both;
}

.product-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.product-image-container {
    position: relative;
    width: 100%;
    padding-top: 100%;
    background: linear-gradient(145deg, #f3f7fb, #ffffff);
}

.product-thumbnail {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 14px;
}

.product-info {
    padding: 14px;
    display: grid;
    gap: 4px;
}

.product-name {
    font-weight: 700;
}

.supplier-name {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.product-price {
    margin-top: 4px;
    color: var(--accent-strong);
    font-weight: 700;
}

.empty-state,
.empty-cart-message,
.empty-order-message,
.empty-qna-message {
    margin-top: 10px;
    padding: 16px;
    border-radius: var(--radius-md);
    border: 1px dashed rgba(15, 23, 42, 0.18);
    background: rgba(255, 255, 255, 0.75);
    color: var(--text-muted);
}

.pagination {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

.pagination a {
    min-width: 40px;
    height: 40px;
    border-radius: 10px;
    border: 1px solid var(--line);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    background: #fff;
    color: var(--text);
}

.pagination a.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-strong));
    color: #fff;
    border-color: transparent;
}

.form-container {
    max-width: 760px;
    margin: 0 auto;
    padding: 22px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.9);
    display: grid;
    gap: 14px;
}

.form-group {
    display: grid;
    gap: 8px;
}

.form-group label {
    color: #334155;
    font-size: 0.92rem;
    font-weight: 600;
}

.field-help {
    color: var(--text-muted);
    font-size: 0.86rem;
}

.image-preview-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
}

.image-preview-item {
    position: relative;
    display: grid;
    gap: 8px;
    padding: 10px;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: #fff;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.image-preview-item:hover {
    border-color: rgba(15, 118, 110, 0.35);
}

.image-preview-item.drag-enabled {
    cursor: grab;
}

.image-preview-item.drag-enabled:active {
    cursor: grabbing;
}

.image-preview-item.dragging {
    opacity: 0.65;
    transform: scale(0.98);
    box-shadow: none;
}

.image-preview-thumb {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: #fff;
}

.image-order-label {
    font-size: 0.84rem;
    color: var(--text-muted);
}

.image-order-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 24px;
    padding: 0 8px;
    border-radius: 999px;
    font-size: 0.74rem;
    font-weight: 700;
    border: 1px solid rgba(15, 23, 42, 0.15);
    color: #475569;
    background: rgba(255, 255, 255, 0.92);
}

.image-order-badge.active {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(135deg, var(--primary), var(--primary-strong));
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.product-details-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.product-images-gallery {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.product-image-card {
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    background: #fff;
    overflow: hidden;
}

.product-image-card img {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
}

.product-details-info {
    display: grid;
    gap: 12px;
    align-content: start;
}

.price {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--accent-strong);
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.admin-actions,
.qna-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.inline-action-form {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.inline-action-form input[type="number"] {
    width: 78px;
}

.cart-item,
.order-summary-item,
.order-item,
.qna-item {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: #fff;
    box-shadow: var(--shadow-sm);
    padding: 14px;
    margin-bottom: 12px;
}

.cart-item,
.order-item {
    display: flex;
    gap: 14px;
    align-items: center;
}

.item-image img {
    width: 92px;
    height: 92px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid var(--line);
}

.item-details {
    flex: 1;
    display: grid;
    gap: 6px;
}

.cart-summary {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}

.qna-item a {
    display: grid;
    gap: 5px;
    text-decoration: none;
}

.answer-status.answered {
    color: var(--success);
    font-weight: 700;
}

.answer-status.pending {
    color: #b45309;
    font-weight: 700;
}

.success-message,
.error-message {
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid transparent;
    margin-bottom: 10px;
}

.success-message {
    background: rgba(22, 163, 74, 0.1);
    color: #166534;
    border-color: rgba(22, 163, 74, 0.22);
}

.error-message {
    background: rgba(220, 38, 38, 0.1);
    color: #991b1b;
    border-color: rgba(220, 38, 38, 0.22);
}

.table {
    width: 100%;
    border-collapse: collapse;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--line);
    background: #fff;
}

.table th,
.table td {
    padding: 10px 12px;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.table th {
    background: rgba(15, 118, 110, 0.08);
    color: #0f172a;
    text-align: left;
}

.text-right {
    text-align: right;
}

.mb-3 {
    margin-bottom: 12px;
}

.btn {
    min-height: var(--control-height);
    padding: 0 var(--control-padding-x);
    border-radius: 12px;
    border: 1px solid rgba(15, 23, 42, 0.15);
    text-decoration: none;
    font-size: 0.93rem;
    font-weight: 600;
    color: #0f172a;
    background: #fff;
    transition: all 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.btn-sm {
    min-height: 38px;
    padding: 0 12px;
    border-radius: 10px;
    font-size: 0.88rem;
}

.btn-primary {
    color: #fff;
    border: none;
    background: linear-gradient(135deg, var(--primary), var(--primary-strong));
    box-shadow: 0 8px 16px rgba(13, 148, 136, 0.22);
}

.btn-secondary {
    border-color: rgba(15, 23, 42, 0.15);
    color: #0f172a;
    background: #fff;
}

.btn-outline-primary {
    border-color: rgba(15, 118, 110, 0.35);
    color: #0f766e;
    background: rgba(15, 118, 110, 0.08);
}

.btn-outline-danger {
    border-color: rgba(220, 38, 38, 0.35);
    color: #b91c1c;
    background: rgba(220, 38, 38, 0.08);
}

.btn-outline-primary:hover {
    background: rgba(15, 148, 136, 0.16);
    border-color: rgba(15, 148, 136, 0.36);
}

.btn-outline-danger:hover {
    background: rgba(220, 38, 38, 0.14);
    border-color: rgba(220, 38, 38, 0.32);
}

footer {
    width: min(1200px, 94vw);
    margin: 0 auto 24px;
    padding: 14px 18px;
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.76);
    color: var(--text-muted);
    text-align: center;
    font-size: 0.88rem;
}

.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.62);
    z-index: 1200;
    padding: 20px;
    justify-content: center;
    align-items: center;
}

.modal-content {
    width: min(860px, 95vw);
    max-height: 92vh;
    overflow: auto;
    border-radius: var(--radius-lg);
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.14);
    box-shadow: var(--shadow-lg);
    padding: 18px;
    position: relative;
}

#modalProductDetails {
    display: grid;
    gap: 10px;
}

.close-button,
.close-slider-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.9);
    color: #0f172a;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    cursor: pointer;
    z-index: 5;
}

.modal-product-images-gallery {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
}

.modal-product-images-gallery img {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid var(--line);
}

.modal-add-form {
    margin-top: 10px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.modal-add-form input[type="number"] {
    width: 72px;
}

.image-slider-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(2, 6, 23, 0.92);
    z-index: 1300;
    justify-content: center;
    align-items: center;
}

.slider-image-container {
    width: min(95vw, 1200px);
    height: min(90vh, 820px);
    display: flex;
    justify-content: center;
    align-items: center;
}

.slider-image-container img {
    max-width: 95%;
    max-height: 95%;
    border-radius: 14px;
    background: #fff;
    box-shadow: var(--shadow-lg);
}

.slider-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.35);
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    display: inline-flex;
    justify-content: center;
    align-items: center;
    font-size: 1.6rem;
    cursor: pointer;
}

.slider-nav-btn.prev {
    left: 18px;
}

.slider-nav-btn.next {
    right: 18px;
}

.slider-pagination {
    position: absolute;
    bottom: 22px;
    left: 50%;
    transform: translateX(-50%);
    color: #fff;
    background: rgba(2, 6, 23, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 0.9rem;
}

.back-to-top {
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, var(--primary), var(--primary-strong));
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 18px rgba(15, 118, 110, 0.35);
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 1400;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

@keyframes fade-up {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 1024px) {
    .page-hero {
        flex-direction: column;
    }
    .hero-stats {
        min-width: 0;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .product-details-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 860px) {
    .nav-toggle {
        display: inline-flex;
    }

    .site-nav {
        display: none;
        position: absolute;
        top: calc(100% + 8px);
        left: 3vw;
        right: 3vw;
        padding: 12px;
        border-radius: var(--radius-md);
        border: 1px solid var(--line);
        background: rgba(255, 255, 255, 0.98);
        box-shadow: var(--shadow-md);
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .site-nav.open {
        display: flex;
    }

    .site-nav a,
    .site-nav summary,
    .nav-link-button {
        justify-content: flex-start;
        width: 100%;
    }

    .nav-dropdown-menu {
        position: static;
        border: none;
        box-shadow: none;
        padding: 4px 0 0;
    }

    main {
        padding: 18px;
    }

    .catalog-header-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .cart-item,
    .order-item {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 560px) {
    .hero-stats {
        grid-template-columns: 1fr;
    }

    .product-list {
        grid-template-columns: 1fr 1fr;
    }

    .search-form,
    .filter-form {
        padding: 10px;
    }

    .filter-form select,
    .search-form input[type="text"] {
        width: 100%;
        flex: 1 1 100%;
    }

    .button-link,
    button[type="submit"],
    .secondary-button,
    .btn {
        width: 100%;
    }

    .inline-action-form {
        width: 100%;
        flex-wrap: wrap;
    }

    .inline-action-form input[type="number"] {
        width: 100%;
    }
}
