/* FootFinder ---------------------------------------------------- */
.footfinder-header { display: flex; align-items: baseline; gap: 20px; flex-wrap: wrap; margin-bottom: 4px; }
.footfinder-header .footfinder-title { margin-bottom: 0; }
.footfinder-link { display: inline-block; font-size: 13px; color: #40462c; margin-bottom: 10px; text-decoration: none; cursor: pointer; width: 200px; line-height: 1.5em; }
.footfinder-outer { position: relative; }
.footfinder-close { position: absolute; top: 10px; right: 20px; background: none; border: none; font-size: 18px; color: #999; cursor: pointer; line-height: 1; padding: 4px 6px; z-index: 1; }
.footfinder-close:hover { color: #333; }
.footfinder-outer { background: rgba(114,124,83,0.2); border-top: none; border-bottom: 1px solid #e0e0e0; width: 100%; }
.cms-index-index .footfinder-outer { margin-bottom: 30px; }
.footfinder-wrap { padding: 14px 0; font-family: 'Montserrat', sans-serif; }

/* Form row */
.footfinder-title { font-size: 22px; font-weight: 600; color: #727c53; margin-bottom: 4px; width: 200px; }
.footfinder-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; }
.footfinder-fields { display: flex; flex-wrap: wrap; gap: 12px; flex: 1; align-items: flex-end; }
.footfinder-field { display: flex; flex-direction: column; gap: 5px; }
.footfinder-field label { font-size: 12px; font-weight: 400; color: #40462c; }
.footfinder-field input[type="number"] { border: 1px solid #ddd; border-radius: 6px; padding: 8px 12px; font-size: 14px; font-family: 'Montserrat', sans-serif; font-weight: 600; width: 140px; background: #fafafa; color: #171717; outline: none; -moz-appearance: textfield; transition: border-color 0.18s, box-shadow 0.18s, background 0.18s; }
.footfinder-field input[type="number"]::-webkit-outer-spin-button,
.footfinder-field input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; }
.footfinder-field input[type="number"]:focus { border-color: #727c53; background: #fff; box-shadow: 0 0 0 3px rgba(0,113,192,0.10); }
.footfinder-field input.ff-error { border-color: #CE0E2D; }
.footfinder-field-btn { justify-content: flex-end; }
.footfinder-btn { border: 1px solid #727c53; background: #727c53; color: #fff; font-family: 'Montserrat', sans-serif; font-size: 13px; font-weight: 600; padding: 9px 24px; border-radius: 6px; cursor: pointer; transition: background 0.18s, box-shadow 0.18s; white-space: nowrap; letter-spacing: 0.01em; }
.footfinder-btn:disabled { background: #bbb; cursor: not-allowed; box-shadow: none; }

/* Loading */
.footfinder-loading { display: flex; align-items: center; gap: 10px; padding: 16px 0; color: #999; font-size: 13px; }
.ff-spinner { width: 20px; height: 20px; border: 2px solid #e8e8e8; border-top-color: #727c53; border-radius: 50%; animation: ff-spin 0.7s linear infinite; flex-shrink: 0; }
@keyframes ff-spin { to { transform: rotate(360deg); } }

/* Empty */
.footfinder-empty { padding: 16px 0; font-size: 13px; color: #999; }

/* Results */
.footfinder-results { margin-top: 20px; }
.ff-results-header { display: flex; gap: 12px; align-items: baseline; margin-bottom: 16px; font-size: 13px; color: #777; }
#ff-results-count { font-weight: 700; color: #171717; }

/* Product grid */
.ff-products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }

/* Responsive: medium — keep inputs+button on one row, form stacks vertically */
@media (max-width: 900px) {
    .footfinder-form { flex-direction: column; align-items: stretch; }
    .footfinder-header { width: 100%; }
    .footfinder-link { width: 100%; }
    .footfinder-fields { width: 100%; flex-wrap: nowrap; }
    .footfinder-field input[type="number"] { width: 120px; min-width: 0; }
    .footfinder-btn { white-space: nowrap; }
}

/* Responsive: narrow — stack inputs + button vertically */
@media (max-width: 520px) {
    .footfinder-fields { flex-wrap: wrap; flex-direction: column; }
    .footfinder-field { width: 100%; }
    .footfinder-field input[type="number"] { width: 100%; box-sizing: border-box; }
    .footfinder-field-btn { width: 100%; }
    .footfinder-btn { width: 100%; }
    .ff-products-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

/* Product card */
.ff-product-card { border: 1px solid #e8e8e8; border-radius: 8px; overflow: hidden; background: #fff; display: flex; flex-direction: column; transition: box-shadow 0.2s, border-color 0.2s; }
.ff-product-card:hover { box-shadow: 0 4px 18px rgba(0,0,0,0.09); border-color: #c8c8c8; }
.ff-product-img-wrap { display: block; background: #f9f9f9; aspect-ratio: 1/1; overflow: hidden; }
.ff-product-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.ff-product-card:hover .ff-product-img-wrap img { transform: scale(1.04); }

.ff-product-info { padding: 10px 12px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.ff-size-badges { display: flex; flex-wrap: wrap; gap: 4px; min-height: 24px; }
.ff-badge-size { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 4px; border: 1px solid #727c53; color: #3f452e; background: #ffffff; }
.ff-product-name { font-size: 12px; font-weight: 600; color: #222; text-decoration: none; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ff-product-name:hover { color: #000; }
.ff-product-price { display: flex; gap: 6px; align-items: baseline; flex-wrap: wrap; margin-top: auto; }
.ff-price { font-size: 14px; font-weight: 700; color: #171717; }
.ff-price-special { color: #CE0E2D; }
.ff-price-old { font-size: 11px; color: #bbb; text-decoration: line-through; }
