    :root {
      --bg: #ffffff;
      --surface: #f5f5f5;
      --fg: #333333;
      --muted: #666666;
      --border: #D9D9D9;
      --accent: #D32F2F;
      --font-display: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
      --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    }
    * { box-sizing: border-box; margin: 0; padding: 0; }
    html, body {
      width: 100%;
      overflow-x: hidden;
      background: var(--bg);
      color: var(--fg);
      font: 16px/1.5 var(--font-body);
      -webkit-font-smoothing: antialiased;
    }
    .container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

    /* HEADER */
    .header {
      background: var(--bg);
      border-bottom: 2px solid var(--border);
      padding: 20px 0;
    }
    .header-inner {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 40px;
    }
    .header-logo {
      width: 50%;
      flex-shrink: 0;
    }
    .header-logo img {
      width: 100%;
      height: auto;
      display: block;
    }
    .header-contact {
      display: flex;
      flex-direction: column;
      align-items: flex-end;
      gap: 8px;
      flex: 1;
    }
    .header-phone {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      font-size: 34px;
      font-weight: 600;
      color: var(--fg);
      text-decoration: none;
    }
    .header-phone:hover { color: var(--accent); }
    .header-phone-icon {
      flex-shrink: 0;
    }
    .header-address {
      font-size: 16px;
      color: var(--muted);
    }

    /* HERO */
    .hero {
      background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
      color: var(--bg);
      padding: 40px 0;
      position: relative;
      overflow: hidden;
    }
    .hero::before {
      content: '';
      position: absolute;
      top: -50%;
      right: -20%;
      width: 600px;
      height: 600px;
      border: 8px solid rgba(255, 255, 255, 0.05);
      border-radius: 50%;
    }
    .hero-inner {
      position: relative;
      z-index: 1;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 60px;
    }
    .hero-content {
      flex: 1;
    }
    .hero-badge {
      display: inline-block;
      background: var(--accent);
      color: var(--bg);
      padding: 6px 16px;
      border-radius: 4px;
      font-size: 14px;
      font-weight: 600;
      margin-bottom: 20px;
      letter-spacing: 0.06em;
      text-transform: uppercase;
    }
    .hero-title {
      font-size: clamp(2rem, 5vw, 3.5rem);
      font-weight: 600;
      line-height: 1.1;
      margin-bottom: 20px;
      letter-spacing: -0.02em;
    }
    .hero-desc {
      font-size: 18px;
      color: rgba(255, 255, 255, 0.8);
      margin-bottom: 30px;
      max-width: 500px;
    }
    .hero-cta {
      display: inline-block;
      background: var(--accent);
      color: var(--bg);
      padding: 16px 32px;
      border-radius: 6px;
      font-size: 16px;
      font-weight: 600;
      text-decoration: none;
      transition: background 0.2s;
    }
    .hero-cta:hover { background: #b71c1c; }

    /* SEARCH BLOCK */
    .search {
      background: var(--surface);
      padding: 24px 0;
    }
.search-grid {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 0;
    padding: 0;
}
    .search-column {
      padding: 0;
    }
    .search-column-left {
      width: 340px;
      flex-shrink: 0;
      display: flex;
      flex-direction: column;
    }
.category-tabs {
    display: flex;
    flex-direction: column;
    gap: 0;
        margin-top: 59px;
}
   .category-tab {
        padding: 8px 15px;
        background: transparent;
        border: none;
        text-align: center;
        cursor: pointer;
        transition: all 0.15s;
        width: 100%;
        font-size: 14px;
        font-weight: 500;
        color: var(--fg);
        /* text-transform: uppercase; */
        letter-spacing: 0.06em;
        font-family: var(--font-body);
            padding: 15px;
                border-radius: 4px;
                margin-bottom:40px;
                border:1px solid #d32f2f;
                
      }
    .category-tab:hover {
      color: #ffffff;
      background: #282828;
      border-color: #000000;
    }
    .category-tab:first-child {

    }
    .category-tab.active {
      background: var(--accent);
      color: #ffffff;
      font-weight: 600;
    }
.search-column-right {
    display: flex;
    flex-direction: column;
    padding: 0 0 0 49px;

}
.search-column-right h3{
      font-size: 20px;
    font-weight: 600;
    margin-bottom: 30px;
    letter-spacing: -0.01em;
    text-align: center;
}
    .tab-panel {
      display: none;
    }
    .tab-panel.active {
      display: flex;
      flex-direction: column;
      /* padding-top: 12px; */
    }
    .search-param-row {
      display: flex;
      align-items: center;
      padding-bottom: 6px;
      margin-bottom: 30px;
    }
    .search-param-row label {
      flex-basis: 140px;
      flex-shrink: 0;
      font-size: 14px;
      color: var(--muted);
      font-family: var(--font-body);
      border-bottom: 1px solid var(--border);
      padding-bottom: 4px;
      line-height: 45px;
      height: 50px;
    }
    #disks-form .search-param-row label {
      flex-basis: 220px;
    }
    .search-param-row select,
    .search-param-row input {
      flex: 1;
      padding: 6px 12px;
      border: 1px solid var(--border);
      border-radius: 4px;
      font-size: 14px;
      background: var(--bg);
      color: var(--fg);
      font-family: var(--font-body);
      min-width: 80px;
      height: 50px;
      box-sizing: border-box;
    }
    .search-param-row select.search-act,
    .search-param-row input.search-act {
      border: 2px solid #000000 !important;
    }
    .search-param-row select {
      cursor: pointer;
      appearance: none;
      background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L5 5L9 1' stroke='%23666666' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
      background-repeat: no-repeat;
      background-position: right 12px center;
    }
    .search-btn {
      display: block;
      width: 100%;
      padding: 12px 0;
      background: var(--accent);
      color: #ffffff;
      border: none;
      border-radius: 4px;
      font-size: 14px;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      cursor: pointer;
      transition: background 0.15s;
      margin-top: 12px;
      font-family: var(--font-body);
      text-align: center;
    }
    .search-btn:hover {
      background: #c62828;
    }

    /* CATALOG */
    .catalog {
      background: var(--bg);
      padding: 40px 0;
    }
    .section-title {
      font-size: 32px;
      font-weight: 600;
      margin-bottom: 30px;
      letter-spacing: -0.01em;
    }
    .catalog-grid {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      gap: 16px;
    }
    .product-card {
      background: var(--bg);
      border: 1px solid var(--border);
      border-radius: 8px;
      padding: 20px;
      transition: box-shadow 0.2s;
      text-decoration: none;
      color: inherit;
      display: block;
      min-width: 0;
    }
    .product-card:hover {
      box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    }
    .product-image {
      width: 100%;
      height: 180px;
      background: none;
      border-radius: 6px;
      margin-bottom: 16px;
      display: flex;
      align-items: center;
      justify-content: center;
      color: var(--muted);
      font-size: 14px;
      overflow: hidden;
    }
    .product-image img {
      max-width: 100%;
      max-height: 100%;
      object-fit: contain;
    }
    .product-brand {
      font-size: 12px;
      color: var(--muted);
      margin-bottom: 4px;
      text-transform: uppercase;
      letter-spacing: 0.06em;
    }
    .product-name {
      font-size: 16px;
      font-weight: 600;
      color: var(--fg);
      margin-bottom: 8px;
      line-height: 1.4;
      display: -webkit-box;
      -webkit-line-clamp: 2;
      -webkit-box-orient: vertical;
      overflow: hidden;
    }
    .product-size {
      font-size: 14px;
      color: var(--muted);
      margin-bottom: 12px;
    }
    .product-price {
      display: flex;
      align-items: center;
      gap: 12px;
    }
    .price-current {
      font-size: 20px;
      font-weight: 700;
      color: var(--fg);
    }
    .price-old {
      font-size: 14px;
      color: var(--muted);
      text-decoration: line-through;
    }
    .price-discount {
      background: #ff4444;
      color: var(--bg);
      padding: 2px 8px;
      border-radius: 4px;
      font-size: 12px;
      font-weight: 600;
    }
    .product-rating {
      display: flex;
      align-items: center;
      gap: 4px;
      margin-top: 12px;
      font-size: 13px;
      color: var(--muted);
    }
    .product-rating .stars {
      color: #ffc107;
    }

    /* BENEFITS */
    .benefits {
      background: var(--surface);
      padding: 40px 0;
    }
    .benefits-grid {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      gap: 20px;
    }
    .benefit-card {
      text-align: center;
    }
    .benefit-icon {
      width: 64px;
      height: 64px;
      margin: 0 auto 16px;
      background: var(--accent);
      border-radius: 50%;
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .benefit-icon svg {
      width: 32px;
      height: 32px;
      stroke: var(--bg);
    }
    .benefit-title {
      font-size: 18px;
      font-weight: 600;
      margin-bottom: 8px;
    }
    .benefit-desc {
      font-size: 14px;
      color: var(--muted);
      line-height: 1.6;
    }

    /* FOOTER */
    .footer {
      background: #1a1a1a;
      color: var(--bg);
      padding: 40px;
    }
    .footer-inner {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 40px;
    }
    .footer-section h4 {
      font-size: 16px;
      font-weight: 600;
      margin-bottom: 16px;
      color: var(--bg);
    }
    .footer-section p, .footer-section a {
      font-size: 14px;
      color: rgba(255, 255, 255, 0.7);
      line-height: 1.8;
      text-decoration: none;
      display: block;
    }
    .footer-section a:hover { color: var(--bg); }

    /* TYRES CATALOG */
    .breadcrumbs {
        margin-bottom: 20px;
        font-size: 14px;
        color: var(--muted);
    }
    .breadcrumbs a {
        color: var(--accent);
        text-decoration: none;
        cursor: pointer;
    }
    .breadcrumbs a:hover {
        text-decoration: underline;
    }
    .catalog-spinner {
        display: none;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 60px 0;
        grid-column: 1 / -1;
    }
    .spinner {
        width: 40px;
        height: 40px;
        border: 4px solid var(--border);
        border-top-color: var(--accent);
        border-radius: 50%;
        animation: spin 0.8s linear infinite;
        margin-bottom: 12px;
    }
    @keyframes spin {
        to { transform: rotate(360deg); }
    }
    .disk-alert {
        padding: 15px 20px;
        border-radius: 5px;
        margin-bottom: 20px;
    }
    .disk-alert-error {
        background: #f8d7da;
        border: 1px solid #f5c6cb;
        color: #721c24;
    }
    .disk-alert-info {
        background: #d1ecf1;
        border: 1px solid #bee5eb;
        color: #0c5460;
    }
    .product-rest {
        margin-top: 10px;
        font-size: 13px;
    }
    .product-rest.instock {
        color: #28a745;
    }
    .product-rest.outofstock {
        color: #dc3545;
    }
    .catalog-spinner p {
        color: var(--muted);
        font-size: 14px;
    }
    .tyre-card {
        display: flex;
        align-items: center;
        background: var(--bg);
        border: 1px solid var(--border);
        border-radius: 8px;
        padding: 16px;
        transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
        cursor: pointer;
        text-decoration: none;
        color: inherit;
    }
    .tyre-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
        border-color: var(--accent);
    }
    .tyre-card img {
        width: 80px;
        height: 80px;
        object-fit: contain;
        margin-right: 16px;
        flex-shrink: 0;
    }
    .tyre-info {
        flex-grow: 1;
        min-width: 0;
    }
    .tyre-info h3 {
        margin: 0 0 4px 0;
        font-size: 15px;
        font-weight: 600;
        color: var(--fg);
        line-height: 1.3;
    }
    .tyre-card:hover .tyre-info h3 {
        color: var(--accent);
    }
    .tyre-meta {
        font-size: 12px;
        color: var(--muted);
        margin-bottom: 6px;
    }
    .tyre-price-block {
        display: flex;
        gap: 16px;
        align-items: baseline;
        margin-bottom: 4px;
    }
    .price-b2b {
        font-size: 18px;
        color: #28a745;
        font-weight: bold;
    }
    .price-rozn {
        font-size: 13px;
        color: var(--muted);
    }
    .tyre-rest {
        font-size: 12px;
        color: var(--muted);
        background: var(--surface);
        padding: 2px 8px;
        border-radius: 12px;
        display: inline-block;
    }
    .detail-wrapper {
        display: grid;
        grid-template-columns: 250px 1fr;
        gap: 30px;
        background: var(--bg);
        border-radius: 8px;
        padding: 30px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
        border: 1px solid var(--border);
        margin: 0 auto;
    }
    @media(max-width: 768px) {
        .detail-wrapper {
            grid-template-columns: 1fr;
        }
    }
    .image-section {
        text-align: center;
    }
    .image-section img {
        max-width: 100%;
        height: auto;
        object-fit: contain;
        border: 1px solid var(--border);
        border-radius: 4px;
        padding: 10px;
    }
    .info-section h1 {
        margin: 0 0 15px 0;
        font-size: 22px;
        font-weight: 600;
        color: var(--fg);
    }
    .info-table {
        width: 100%;
        border-collapse: collapse;
        margin-bottom: 25px;
    }
    .info-table td {
        padding: 8px 0;
        border-bottom: 1px solid var(--border);
        font-size: 14px;
    }
    .info-table td:first-child {
        color: var(--muted);
        width: 180px;
        flex-shrink: 0;
    }
    .info-table td:last-child {
        font-weight: 600;
    }
    .info-section h3 {
        margin-top: 0;
        border-bottom: 2px solid var(--accent);
        padding-bottom: 5px;
        color: var(--accent);
        font-size: 18px;
    }
    .warehouses-table {
        width: 100%;
        border-collapse: collapse;
        margin-top: 15px;
        font-size: 14px;
    }
    .warehouses-table th, .warehouses-table td {
        border: 1px solid var(--border);
        padding: 10px;
        text-align: left;
    }
    .warehouses-table th {
        background-color: var(--surface);
        font-weight: 600;
    }
    .warehouses-table tr:hover {
        background-color: var(--surface);
    }
    .rest-badge {
        font-weight: 600;
        color: var(--bg);
        padding: 3px 8px;
        border-radius: 10px;
        display: inline-block;
        font-size: 12px;
    }
    .rest-green { background-color: #28a745; }
    .rest-orange { background-color: #fd7e14; }

    /* DETAIL PAGE SHARED */
    .detail-page-section {
        min-height: 400px;
        padding: 40px 0;
    }
    .detail-back-link {
        display: inline-block;
        margin-top: 25px;
        padding: 12px 25px;
        background: #007bff;
        color: #fff;
        text-decoration: none;
        border-radius: 5px;
        font-weight: 600;
    }
    .detail-back-link:hover {
        background: #0056b3;
    }
    .error-box {
        background: #fff3cd;
        border: 1px solid #ffeeba;
        padding: 30px;
        border-radius: 5px;
        color: #856404;
        text-align: center;
    }
    .error-box h2 {
        margin-bottom: 10px;
    }
    .error-box a {
        display: inline-block;
        margin-top: 15px;
        padding: 10px 20px;
        background: #007bff;
        color: #fff;
        text-decoration: none;
        border-radius: 5px;
    }
    .price-block {
        display: flex;
        align-items: center;
        gap: 20px;
        margin-bottom: 20px;
        padding: 20px;
        background: #f8f9fa;
        border-radius: 8px;
    }
    .price-rozn-detail {
        font-size: 28px;
        font-weight: 700;
        color: var(--fg);
    }
    .price-b2b-detail {
        font-size: 18px;
        color: var(--muted);
    }
    .price-label {
        font-size: 14px;
        color: var(--muted);
    }
    .rest-block {
        padding: 15px 20px;
        background: #e8f5e9;
        border-radius: 8px;
        font-size: 16px;
        color: #2e7d32;
    }
    .rest-block.low {
        background: #ffebee;
        color: #c62828;
    }
    .wh-list {
        margin-top: 20px;
    }
    .wh-list h3 {
        margin: 20px 0 10px 0;
        font-size: 16px;
        color: var(--fg);
    }
    .wh-item {
        display: flex;
        justify-content: space-between;
        padding: 12px;
        border-bottom: 1px solid var(--border);
    }
    .wh-item:last-child {
        border-bottom: none;
    }

    /* TYRE DETAIL */
    .detail-wrapper {
        display: grid;
        grid-template-columns: 300px 1fr;
        gap: 40px;
        background: var(--bg);
        border-radius: 8px;
        padding: 30px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
        border: 1px solid var(--border);
        margin: 0 auto;
    }
    .image-section {
        text-align: center;
    }
    .image-section img {
        max-width: 100%;
        height: auto;
        object-fit: contain;
        border: 1px solid #f0f0f0;
        border-radius: 4px;
        padding: 20px;
    }
    .info-table {
        width: 100%;
        border-collapse: collapse;
        margin-bottom: 25px;
    }
    .info-table td {
        padding: 10px 0;
        border-bottom: 1px solid #f0f0f0;
        font-size: 14px;
    }
    .info-table td:first-child {
        color: #666;
        width: 200px;
    }
    .info-table td:last-child {
        font-weight: 600;
        color: #111;
    }
    .price-block {
        display: flex;
        align-items: center;
        gap: 20px;
        margin-bottom: 20px;
        padding: 20px;
        background: #f8f9fa;
        border-radius: 8px;
    }
    .price-b2b {
        font-size: 18px;
        color: #666;
    }
    .price-rozn {
        font-size: 28px;
        font-weight: 700;
        color: #111;
    }
    .rest-block {
        padding: 15px 20px;
        background: #e8f5e9;
        border-radius: 8px;
        font-size: 16px;
        color: #2e7d32;
    }
    .rest-block.low {
        background: #ffebee;
        color: #c62828;
    }
    .wh-list {
        margin-top: 20px;
    }
    .search-select-wrapper {
        flex: 1;
        min-width: 0;
        display: flex;
        align-items: center;
        gap: 6px;
    }
    .search-input-wrapper {
        flex: 1;
        min-width: 0;
        display: none;
        align-items: center;
        gap: 6px;
    }
    .search-width-input {
        padding: 6px 12px;
        border: 1px solid var(--border);
        border-radius: 4px;
        font-size: 14px;
        background: var(--bg);
        color: var(--fg);
        font-family: var(--font-body);
        height: 50px;
        box-sizing: border-box;
        -moz-appearance: textfield;
    }
    #width-manual::-webkit-outer-spin-button,
    #width-manual::-webkit-inner-spin-button,
    #profile-manual::-webkit-outer-spin-button,
    #profile-manual::-webkit-inner-spin-button,
    #diameter-manual::-webkit-outer-spin-button,
    #diameter-manual::-webkit-inner-spin-button {
        -webkit-appearance: none;
        margin: 0;
    }
    .width-toggle-link,
    .width-toggle-back {
        font-family: var(--font-body);
        color: #20abff;
        border-bottom: 1px dashed #20abff;
        font-size: 15px;
        margin-top: 4px;
        margin-left: 4px;
        cursor: pointer;
        flex-shrink: 0;
        white-space: nowrap;
    }

    @media (max-width: 768px) {
        .detail-wrapper {
            grid-template-columns: 1fr;
        }
    }

    .no-results-message {
        padding: 100px 20px;
        text-align: center;
    }
    .no-results-message p {
        color: #D32F2F;
        font-size: 32px;
        font-weight: 400;
        line-height: 1.3;
    }

