* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: #ececec;
    color: #1f2937;
}

.container {
    width: 100%;
    max-width: none;
    padding-left: 14px;
    padding-right: 14px;
    margin: 0 auto;
}

.top-contact {
    background: #f3f3f3;
    border-bottom: 1px solid #d7d7d7;
    font-size: 12px;
}

.top-contact-inner {
    display: flex;
    justify-content: flex-end;
    gap: 24px;
    padding: 6px 0;
}

.contact-lines {
    display: flex;
    gap: 10px;
    color: #333;
}

.contact-note {
    color: #777;
}

.header {
    background: #fff;
    border-bottom: 1px solid #d6d6d6;
    padding: 10px 0;
}

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

.brand {
    color: #7c2d12;
    text-decoration: none;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.brand-mark {
    color: #d97706;
    font-size: 20px;
    line-height: 1;
}

.brand-text {
    color: #7c2d12;
    letter-spacing: 0.3px;
}

.header-search {
    flex: 1;
    max-width: 640px;
    display: flex;
}

.header-search input {
    width: 100%;
    border-right: 0;
    border-radius: 0;
}

.search-btn {
    border-radius: 0;
    background: #2f2f2f;
    min-width: 90px;
}

.menu a {
    color: #1f2937;
    text-decoration: none;
    margin-left: 16px;
    font-weight: 600;
}

.lang-switch {
    margin-left: 12px;
    color: #475569;
    font-size: 12px;
}

.lang-switch a {
    margin-left: 4px;
    color: #1d4ed8;
    text-decoration: none;
}

.cart-link {
    position: relative;
}

.cart-badge {
    position: absolute;
    top: -8px;
    right: -12px;
    background: #e11d48;
    color: #fff;
    border-radius: 999px;
    font-size: 11px;
    padding: 1px 6px;
}

.main {
    padding: 14px 10px 36px;
}

.alert {
    padding: 10px 12px;
    border-radius: 8px;
    margin-bottom: 16px;
}

.alert.success {
    background: #dcfce7;
    color: #166534;
}

.alert.error {
    background: #fee2e2;
    color: #991b1b;
}

.filters {
    display: flex;
    gap: 10px;
    margin-bottom: 18px;
}

.filters input,
.filters select,
button,
.checkout-form input,
.checkout-form textarea {
    padding: 9px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
}

button,
.button {
    background: #2563eb;
    color: #fff;
    border: 0;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

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

.card {
    background: #fff;
    border-radius: 10px;
    padding: 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.price {
    font-weight: 700;
    margin: 8px 0;
}

.old-price {
    margin: 2px 0;
    color: #dc2626;
    text-decoration: line-through;
    font-size: 13px;
    font-weight: 600;
}

.muted {
    color: #64748b;
}

.table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
}

.table th,
.table td {
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
    padding: 10px;
}

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

.checkout-form {
    display: grid;
    gap: 12px;
    max-width: 580px;
}

.checkout-form label {
    display: grid;
    gap: 6px;
}

.checkout-page {
    max-width: 1080px;
    margin: 0 auto;
}

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

.checkout-title {
    margin: 0 0 8px;
    font-size: 28px;
    font-weight: 700;
    color: #0f172a;
    letter-spacing: -0.02em;
}

.checkout-lead {
    margin: 0 0 24px;
    color: #64748b;
    font-size: 15px;
    line-height: 1.55;
}

.checkout-form-modern {
    max-width: none;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 24px 22px 22px;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
}

.checkout-label-text {
    font-size: 13px;
    font-weight: 600;
    color: #334155;
}

.checkout-form-modern input,
.checkout-form-modern textarea {
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    padding: 12px 14px;
    font-size: 15px;
    width: 100%;
}

.checkout-form-modern input:focus,
.checkout-form-modern textarea:focus {
    outline: none;
    border-color: #22c55e;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.18);
}

.checkout-actions {
    margin-top: 12px;
    padding-top: 4px;
}

.btn-checkout-success {
    display: block;
    width: 100%;
    box-sizing: border-box;
    background: linear-gradient(180deg, #4ade80 0%, #22c55e 45%, #16a34a 100%);
    color: #fff;
    border: none;
    border-radius: 9999px;
    padding: 16px 28px;
    font-size: 17px;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 0.02em;
    box-shadow: 0 4px 18px rgba(22, 163, 74, 0.42);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-checkout-success:hover {
    box-shadow: 0 8px 26px rgba(22, 163, 74, 0.48);
    transform: translateY(-2px);
}

.btn-checkout-success:active {
    transform: translateY(0);
    box-shadow: 0 2px 12px rgba(22, 163, 74, 0.4);
}

a.btn-checkout-success--link {
    text-align: center;
    text-decoration: none;
    max-width: 360px;
}

.cart-checkout-wrap {
    margin-top: 16px;
}

.checkout-summary {
    position: sticky;
    top: 16px;
    background: linear-gradient(145deg, #f0fdf4 0%, #ecfdf5 50%, #d1fae5 100%);
    border: 1px solid #bbf7d0;
    border-radius: 16px;
    padding: 0;
    box-shadow: 0 4px 20px rgba(22, 163, 74, 0.12);
}

.checkout-summary-inner {
    padding: 22px 20px;
}

.checkout-summary-label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #166534;
    margin-bottom: 8px;
}

.checkout-summary-amount {
    margin: 0 0 12px;
    font-size: 26px;
    font-weight: 800;
    color: #14532d;
    line-height: 1.2;
}

.checkout-summary-currency {
    font-size: 15px;
    font-weight: 700;
    color: #15803d;
}

.checkout-summary-hint {
    margin: 0;
    font-size: 13px;
    color: #166534;
    line-height: 1.45;
    opacity: 0.9;
}

.market-layout {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    gap: 12px;
    width: 100%;
}

.sidebar {
    background: #fff;
    border: 1px solid #d9d9d9;
}

.sidebar-title {
    background: #f6c505;
    color: #111;
    font-weight: 700;
    font-size: 13px;
    padding: 12px 10px;
}

.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-list li a {
    display: block;
    padding: 10px;
    border-top: 1px solid #ececec;
    text-decoration: none;
    color: #333;
    font-size: 12px;
    letter-spacing: 0.2px;
}

.category-list li a.active {
    background: #eff6ff;
    color: #1d4ed8;
    font-weight: 700;
}

.catalog-content {
    min-width: 0;
    width: 100%;
}

.hero-banner {
    background: linear-gradient(110deg, #f5d695 0%, #e9a541 58%, #d77a21 100%);
    border: 1px solid #d9d9d9;
    height: 250px;
    position: relative;
    overflow: hidden;
}

.hero-banner::after {
    content: "";
    position: absolute;
    right: -20px;
    bottom: -20px;
    width: 260px;
    height: 160px;
    border-radius: 18px;
    transform: rotate(-8deg);
    background: rgba(255, 255, 255, 0.22);
}

.hero-overlay {
    position: absolute;
    left: 26px;
    top: 28px;
    color: #6a2a00;
}

.hero-overlay h1 {
    margin: 0 0 8px;
    font-size: 40px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hero-overlay p {
    margin: 0;
    font-weight: 600;
}

.tabs-row {
    margin-top: 8px;
    background: #fff;
    border: 1px solid #d9d9d9;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
}

.tab {
    text-align: center;
    padding: 10px 8px;
    border-right: 1px solid #e7e7e7;
    font-size: 13px;
    font-weight: 700;
    color: #555;
    text-decoration: none;
}

.tab:last-child {
    border-right: 0;
}

.tab.active {
    background: #20b14f;
    color: #fff;
}

.market-grid {
    margin-top: 10px;
    grid-template-columns: repeat(auto-fill, minmax(195px, 1fr));
    align-items: stretch;
}

.product-card {
    border: 1px solid #dfdfdf;
    box-shadow: none;
    border-radius: 2px;
    padding: 10px;
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-card-top {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.product-card-footer {
    flex: 0 0 auto;
}

.product-card-footer .price {
    margin-top: 0;
}

.promo-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #ef4444;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 6px;
    border-radius: 4px;
    z-index: 1;
}

.product-card h3 {
    margin: 0 0 8px;
    font-size: 14px;
    min-height: 34px;
    line-height: 1.3;
    position: static;
}

.product-card h3 a {
    color: #1f2937;
    text-decoration: none;
    display: block;
}

.product-image {
    height: 140px;
    border: 1px solid #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    background: #fff;
    overflow: hidden;
    margin-bottom: 12px;
    padding: 8px;
    border-radius: 4px;
}

.product-image-img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    object-position: center center;
    display: block;
    image-rendering: -webkit-optimize-contrast;
}

.product-image span {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: #d97706;
    color: #fff;
    font-size: 24px;
    font-weight: 700;
}

.buy-row {
    display: flex;
    gap: 6px;
    margin-top: 8px;
}

.buy-row input {
    width: 64px;
}

.buy-row button {
    flex: 1;
    background: #0ea5e9;
}

.breadcrumbs {
    background: #fff;
    border: 1px solid #d9d9d9;
    padding: 8px 10px;
    font-size: 12px;
    margin-bottom: 10px;
    color: #666;
}

.breadcrumbs a {
    color: #334155;
    text-decoration: none;
}

.product-title {
    margin: 8px 0 12px;
    font-size: 38px;
    font-weight: 500;
}

.product-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 0.6fr;
    gap: 10px;
}

.product-photo-block,
.product-buy-block,
.adv-box,
.product-sections {
    background: #fff;
    border: 1px solid #d9d9d9;
}

.product-photo-block {
    padding: 10px;
}

.product-photo {
    min-height: 360px;
    border: 1px solid #e7e7e7;
    background: #f1f3f5;
    display: grid;
    place-items: center;
}

.product-photo span {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: #f59e0b;
    color: #fff;
    font-size: 42px;
    font-weight: 700;
    display: grid;
    place-items: center;
}

.product-photo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
    display: block;
}

.product-buy-block {
    padding: 10px;
}

.detail-price {
    font-size: 24px;
    margin-bottom: 14px;
}

.detail-price strong {
    font-size: 30px;
    margin-left: 8px;
}

.detail-price small {
    font-size: 14px;
    color: #777;
}

.detail-meta p {
    margin: 7px 0;
    font-size: 15px;
}

.in-stock {
    color: #16a34a;
    font-weight: 700;
}

.out-stock {
    color: #dc2626;
    font-weight: 700;
}

.detail-buy-row {
    margin-top: 12px;
    display: flex;
    gap: 8px;
}

.detail-buy-row input {
    width: 76px;
}

.btn-green,
.btn-gray {
    padding: 10px 12px;
    border-radius: 0;
    text-decoration: none;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
}

.btn-green {
    background: #22c55e;
}

.btn-gray {
    background: #6b7280;
}

.adv-box {
    padding: 10px;
}

.adv-box h3 {
    margin: 0 0 10px;
    text-transform: uppercase;
}

.adv-item {
    border: 1px solid #e5e7eb;
    padding: 10px;
    margin-bottom: 8px;
    display: grid;
    gap: 4px;
}

.adv-item span {
    color: #6b7280;
    font-size: 13px;
}

.product-sections {
    margin-top: 12px;
    padding: 12px;
}

.product-sections h2 {
    margin: 0 0 10px;
    text-transform: uppercase;
}

.product-sections p {
    line-height: 1.6;
}

.product-table th {
    width: 280px;
    background: #fafafa;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

.panel {
    background: #fff;
    border: 1px solid #d9d9d9;
    padding: 12px;
    margin-bottom: 12px;
}

.panel h2 {
    margin-top: 0;
}

.internal-fieldset {
    border: 1px dashed #94a3b8;
    border-radius: 8px;
    padding: 10px 12px;
    margin: 0;
    background: #f8fafc;
}

.internal-fieldset legend {
    padding: 0 6px;
    font-weight: 700;
    font-size: 13px;
    color: #475569;
}

.internal-hint {
    margin: 0 0 10px;
    font-size: 12px;
    color: #64748b;
}

.table th.internal-col,
.table td.internal-col {
    background: #f1f5f9;
    font-size: 12px;
}

.dashboard-form {
    display: grid;
    gap: 10px;
}

.dashboard-form input,
.dashboard-form textarea,
.dashboard-form select {
    width: 100%;
    padding: 9px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
}

.two-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.checkbox-line {
    display: flex;
    align-items: center;
    gap: 8px;
}

.checkbox-line input {
    width: auto;
}

.simple-list {
    margin: 0;
    padding-left: 20px;
}

.dashboard-thumb {
    width: 54px;
    height: 54px;
    object-fit: cover;
    border: 1px solid #d1d5db;
    border-radius: 4px;
}

.status-toggle {
    margin: 0;
}

.btn-status-active,
.btn-status-hidden {
    padding: 6px 10px;
    border-radius: 6px;
    color: #fff;
    border: 0;
    cursor: pointer;
}

.btn-status-active {
    background: #16a34a;
}

.btn-status-hidden {
    background: #6b7280;
}

.edit-link {
    color: #1d4ed8;
    text-decoration: underline;
    font-weight: 600;
}

.current-image {
    display: flex;
    align-items: center;
    gap: 12px;
}

.form-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.button-secondary {
    background: #64748b;
    color: #fff;
    text-decoration: none;
    padding: 9px 12px;
    border-radius: 6px;
}

.inline-logout {
    display: inline;
}

.inline-logout button {
    margin-left: 12px;
    background: #374151;
    padding: 7px 10px;
}

.admin-login-box {
    max-width: 420px;
    margin: 10px auto;
}

.dashboard-shell {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 16px;
    align-items: start;
    width: 100%;
}

.dashboard-sidebar {
    background: #fff;
    border: 1px solid #d9d9d9;
    padding: 0;
    position: sticky;
    top: 12px;
}

.dashboard-sidebar-title {
    background: #1e3a5f;
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    padding: 12px 14px;
    letter-spacing: 0.3px;
}

.dashboard-nav {
    display: flex;
    flex-direction: column;
    padding: 8px 0;
}

.dashboard-nav-link {
    display: block;
    padding: 10px 14px;
    color: #334155;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    border-left: 3px solid transparent;
}

.dashboard-nav-link:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.dashboard-nav-link.is-active {
    background: #eff6ff;
    color: #1d4ed8;
    border-left-color: #2563eb;
}

.dashboard-page {
    min-width: 0;
}

.dashboard-page > h1 {
    margin: 0 0 14px;
    font-size: 22px;
}

.overview-lead {
    margin: 0 0 12px;
    color: #475569;
    font-size: 15px;
}

.overview-stats {
    margin: 0;
    padding-left: 20px;
    line-height: 1.8;
    color: #334155;
}

.report-filter-form {
    margin-bottom: 0;
}

.report-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.report-stat-card {
    background: #fff;
    border: 1px solid #d9d9d9;
    padding: 14px 12px;
    border-radius: 8px;
}

.report-stat-card.report-stat-internal {
    background: #f8fafc;
    border-style: dashed;
}

.report-stat-label {
    display: block;
    font-size: 12px;
    color: #64748b;
    font-weight: 600;
    margin-bottom: 6px;
}

.report-stat-value {
    font-size: 18px;
    color: #0f172a;
}

.report-disclaimer {
    margin: 0 0 12px;
    max-width: 720px;
}

@media (max-width: 980px) {
    .market-layout {
        grid-template-columns: 1fr;
    }

    .header-search {
        max-width: none;
    }

    .nav {
        flex-wrap: wrap;
    }

    .container {
        padding-left: 8px;
        padding-right: 8px;
    }

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

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

    .dashboard-shell {
        grid-template-columns: 1fr;
    }

    .dashboard-sidebar {
        position: static;
    }

    .dashboard-nav {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 4px;
        padding: 8px;
    }

    .dashboard-nav-link {
        border-left: 0;
        border-radius: 6px;
        padding: 8px 12px;
    }

    .dashboard-nav-link.is-active {
        border-left: 0;
    }

    .checkout-layout {
        grid-template-columns: 1fr;
    }

    .checkout-summary {
        position: static;
        order: -1;
    }

    .checkout-title {
        font-size: 24px;
    }
}
