* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    background-color: #f4f6f9;
    color: #333;
    padding: 8px;
}

.search-container {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    background: #fff;
    padding: 12px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.search-layout {
    display: flex;
    gap: 8px;
    align-items: stretch;
    width: 100%;
}

.inputs-zone {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.search-row {
    display: flex;
    gap: 6px;
    width: 100%;
}

/* Твоя настройка инпутов с width: 55px */
.input-kod, .input-gin, .input-text {
    flex: 1;
    width: 55px; 
    height: 46px;
    padding: 0 10px;
    font-size: 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    background-color: #f8fafc;
    outline: none;
    transition: all 0.2s ease;
}

input:focus {
    border-color: #1e90ff;
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(30, 144, 255, 0.15);
}

.button-zone {
    display: flex;
}

/* Главная кнопка OK */
button[type="button"] {
    height: 100%;
    padding: 0 24px;
    font-size: 18px;
    font-weight: bold;
    color: #fff;
    background: linear-gradient(135deg, #1e90ff, #0066cc);
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

.status-bar {
    margin: 10px 0;
    padding: 8px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    background-color: #e2e8f0;
    color: #4a5568;
}

.status-bar.loading { background-color: #feebc8; color: #c05621; }
.status-bar.success { background-color: #c6f6d5; color: #22543d; }

.table-responsive {
    width: 100%;
    overflow-x: auto;
    margin-top: 5px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

th {
    background-color: #1e90ff;
    color: white;
    padding: 10px 8px;
    font-weight: 600;
    position: sticky;
    top: 0;
    text-align: left;
}

td {
    padding: 10px 8px;
    border-bottom: 1px solid #e2e8f0;
    color: #2d3748;
    vertical-align: middle;
    word-break: break-all;
}

tr:nth-child(even) { background-color: #f8fafc; }

/* ФИКСИРОВАННАЯ ШИРИНА ДЛЯ СТОЛБЦА ЦЕНЫ */
.col-price {
    width: 65px !important;
    max-width: 65px !important;
    min-width: 65px !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: right;
}

/* Оформление названия и блока картинок */
.product-name-text {
    font-weight: 500;
    margin-bottom: 4px;
}

.product-img-block {
    margin-top: 4px;
}

.product-thumb {
    width: 93px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #cbd5e1;
    cursor: pointer;
}

/* СТАБИЛЬНАЯ И КРАСИВАЯ ЗЕЛЕНАЯ КНОПКА ПЛЮС */
.btn-add-img {
    display: block !important;
    width: 40px !important;
    height: 40px !important;
    line-height: 36px !important;
    padding: 0 !important;
    font-size: 24px !important;
    font-weight: bold !important;
    color: #fff !important;
    background: #28a745 !important;
    border: none !important;
    border-radius: 6px !important;
    cursor: pointer;
    margin: 0 auto !important;
}

.btn-add-img:active {
    background: #218838 !important;
    transform: scale(0.95);
}

/* Модальное окно увеличения картинок */
.image-viewer {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    justify-content: center;
    align-items: center;
}

.viewer-content {
    max-width: 90%;
    max-height: 85%;
    border-radius: 12px;
    box-shadow: 0 5px 25px rgba(255,255,255,0.1);
}

.close-viewer {
    position: absolute;
    top: 15px;
    right: 25px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
}