/* ============================================
   Shoe Locker – Dashboard Panel
   ============================================ */

/* --- Header --- */
.shoe-locker-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding-top: 32px;
    margin-bottom: 32px;
    text-align: center;
}

.shoe-locker-header .dashboard-section-heading {
    margin-bottom: 4px;
}

.shoe-locker-coming-soon-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 13px;
    color: #6b7280;
    margin: 0;
}

.shoe-locker-coming-soon-note svg {
    flex-shrink: 0;
    color: #f59e0b;
}

.btn-add-shoe-review {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #96ff94;
    color: #04132D;
    border: none;
    border-radius: 8px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.2s, transform 0.15s;
    flex-shrink: 0;
}

.btn-add-shoe-review:hover {
    background: #7de87b;
    transform: translateY(-1px);
}

/* --- Empty State --- */
.shoe-locker-empty {
    text-align: center;
    padding: 60px 20px;
    color: #9ca3af;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.shoe-locker-empty svg {
    margin-bottom: 16px;
}

.shoe-locker-empty p {
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 15px;
    color: #6b7280;
    margin: 0;
}

/* ============================================
   Shoe Cards Grid
   ============================================ */
.shoe-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
}

.shoe-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.2s;
}

.shoe-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

/* --- Card Main (Always Visible) --- */
.shoe-card-main {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
    position: relative;
}

.shoe-card-image {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    background: #f3f4f6;
}

.shoe-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.shoe-card-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
}

.shoe-card-info {
    flex: 1;
    min-width: 0;
}

.shoe-card-brand {
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #6b7280;
    margin-bottom: 2px;
}

.shoe-card-model {
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #04132D;
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.shoe-card-stars {
    display: flex;
    gap: 2px;
    margin-bottom: 8px;
}

.shoe-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.shoe-tag {
    display: inline-block;
    padding: 2px 8px;
    background: #f3f4f6;
    color: #374151;
    border-radius: 4px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 11px;
    font-weight: 500;
}

.shoe-tag-terrain {
    background: #e0ffe0;
    color: #166534;
}

.shoe-card-toggle {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    color: #9ca3af;
    transition: transform 0.2s, color 0.2s;
}

.shoe-card-toggle:hover {
    color: #04132D;
}

.shoe-card-toggle.expanded {
    transform: rotate(180deg);
}

/* --- Card Details (Expandable) --- */
.shoe-card-details {
    border-top: 1px solid #f3f4f6;
    padding: 16px;
}

.shoe-detail-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 16px;
}

.shoe-detail-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.shoe-detail-label {
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    color: #9ca3af;
}

.shoe-detail-value {
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #04132D;
}

/* Sub Ratings */
.shoe-sub-ratings {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 16px;
    margin-bottom: 16px;
}

.shoe-sub-rating {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.shoe-sub-rating-label {
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 12px;
    color: #6b7280;
    white-space: nowrap;
}

.shoe-sub-rating-stars {
    display: flex;
    gap: 1px;
}

/* Linked Events */
.shoe-linked-events {
    margin-bottom: 16px;
}

.shoe-linked-events .shoe-detail-label {
    margin-bottom: 6px;
    display: block;
}

.shoe-event-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.shoe-event-tag {
    display: inline-block;
    padding: 4px 10px;
    background: #eff6ff;
    color: #1d4ed8;
    border-radius: 6px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 12px;
    text-decoration: none;
    transition: background 0.2s;
}

.shoe-event-tag:hover {
    background: #dbeafe;
    text-decoration: none;
    color: #1d4ed8;
}

/* Review Text */
.shoe-review-text {
    margin-bottom: 16px;
}

.shoe-review-text .shoe-detail-label {
    margin-bottom: 6px;
    display: block;
}

.shoe-review-text p {
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 13px;
    color: #374151;
    line-height: 1.6;
    margin: 0;
}

/* Card Actions */
.shoe-card-actions {
    display: flex;
    gap: 12px;
    padding-top: 12px;
    border-top: 1px solid #f3f4f6;
}

.btn-edit-shoe,
.btn-delete-shoe {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 6px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid #e5e7eb;
    background: #fff;
    color: #374151;
    transition: all 0.15s;
}

.btn-edit-shoe:hover {
    background: #f9fafb;
    border-color: #04132D;
    color: #04132D;
}

.btn-delete-shoe {
    color: #ef4444;
    border-color: #fecaca;
}

.btn-delete-shoe:hover {
    background: #fef2f2;
    border-color: #ef4444;
}

/* ============================================
   Modal: body lock
   ============================================ */
body.modal-open,
html.modal-open {
    overflow: hidden !important;
    height: 100% !important;
}

/* ============================================
   Shoe Modal
   ============================================ */
.shoe-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    overflow-y: scroll;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: auto;
    scrollbar-color: rgba(255,255,255,0.6) rgba(0,0,0,0.3);
}

.shoe-modal::-webkit-scrollbar {
    width: 14px;
}

.shoe-modal::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
}

.shoe-modal::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.6);
    border-radius: 7px;
    border: 3px solid rgba(0, 0, 0, 0.3);
}

.shoe-modal::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.8);
}

.shoe-modal-scroll-wrapper {
    padding: 100px 20px 40px;
    box-sizing: border-box;
}

.shoe-modal-content {
    background: #fff;
    border-radius: 16px;
    max-width: 1100px;
    margin: 0 auto;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

@media (min-width: 1024px) {
    .shoe-modal-scroll-wrapper {
        padding: 80px 20px 30px;
    }

    .shoe-modal-content .modal-columns {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }

    .shoe-modal-content .modal-col-left,
    .shoe-modal-content .modal-col-right {
        min-width: 0;
    }
}

.shoe-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid #e5e7eb;
}

.shoe-modal-header h3 {
    font-family: "Inter", "Manrope", sans-serif !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    font-stretch: normal !important;
    letter-spacing: 1px !important;
    color: #04132D;
    margin: 0;
    text-transform: uppercase;
}

.shoe-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #9ca3af;
    cursor: pointer;
    line-height: 1;
    padding: 0;
}

.shoe-modal-close:hover {
    color: #04132D;
}

/* --- Form --- */
#shoe-review-form {
    padding: 24px;
}

.shoe-form-group {
    margin-bottom: 20px;
}

.shoe-form-group label {
    display: block;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

.shoe-form-group label .required {
    color: #ef4444;
}

.shoe-form-group input[type="text"],
.shoe-form-group input[type="number"],
.shoe-form-group select,
.shoe-form-group textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 14px;
    color: #04132D;
    background: #fff;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.shoe-form-group input:focus,
.shoe-form-group select:focus,
.shoe-form-group textarea:focus {
    outline: none;
    border-color: #04132D;
}

.shoe-form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.shoe-form-row {
    display: grid;
    gap: 16px;
    margin-bottom: 20px;
}

.shoe-form-row-2col {
    grid-template-columns: 1fr 1fr;
}

.shoe-form-row-3col {
    grid-template-columns: 1fr 1fr 1fr;
}

.shoe-form-row .shoe-form-group {
    margin-bottom: 0;
}

/* Mileage wrapper */
.shoe-mileage-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.shoe-mileage-wrapper input[type="number"] {
    flex: 1;
}

.shoe-still-in-use {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px !important;
    font-weight: 500 !important;
    color: #6b7280 !important;
    cursor: pointer;
    white-space: nowrap;
    margin-bottom: 0 !important;
    padding: 6px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    background: #fff;
    transition: all 0.15s;
}

.shoe-still-in-use input[type="checkbox"] {
    width: auto;
}

.shoe-still-in-use.active {
    background: #e0ffe0;
    border-color: #96ff94;
    color: #04132D !important;
    font-weight: 600 !important;
}

/* Use type chips */
.shoe-use-type-options {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.shoe-chip {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    margin-bottom: 0 !important;
}

.shoe-chip input[type="checkbox"] {
    display: none;
}

.shoe-chip span {
    display: inline-block;
    padding: 8px 18px;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    background: #fff;
    transition: all 0.15s;
}

.shoe-chip input[type="checkbox"]:checked + span {
    background: #e0ffe0;
    border-color: #96ff94;
    color: #04132D;
    font-weight: 600;
}

/* Photo upload */
.shoe-photo-upload {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-upload-shoe-photo {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: 1px dashed #d1d5db;
    border-radius: 8px;
    background: #f9fafb;
    color: #6b7280;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
}

.btn-upload-shoe-photo:hover {
    border-color: #04132D;
    color: #04132D;
    background: #fff;
}

.shoe-photo-preview {
    position: relative;
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
}

.shoe-photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.shoe-photo-remove {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 20px;
    height: 20px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Events search */
.shoe-events-search-wrapper {
    position: relative;
}

.shoe-events-search-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 14px;
    color: #04132D;
    box-sizing: border-box;
}

.shoe-events-search-input:focus {
    outline: none;
    border-color: #04132D;
}

.shoe-events-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    margin-top: 4px;
}

.shoe-events-dropdown-loading,
.shoe-events-dropdown-empty {
    padding: 12px 16px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 13px;
    color: #9ca3af;
}

.shoe-event-option {
    padding: 10px 16px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 13px;
    color: #04132D;
    cursor: pointer;
    transition: background 0.1s;
}

.shoe-event-option:hover {
    background: #f3f4f6;
}

.shoe-events-selected {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.shoe-event-tag-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: #eff6ff;
    color: #1d4ed8;
    border-radius: 6px;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 12px;
    font-weight: 500;
}

.shoe-event-tag-remove {
    background: none;
    border: none;
    color: #1d4ed8;
    font-size: 16px;
    cursor: pointer;
    padding: 0 2px;
    line-height: 1;
}

.shoe-event-tag-remove:hover {
    color: #dc2626;
}

/* Star ratings in form */
.shoe-star-rating {
    display: flex;
    gap: 4px;
}

.shoe-star-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    transition: transform 0.1s;
}

.shoe-star-btn:hover {
    transform: scale(1.15);
}

/* Sub ratings form */
.shoe-sub-ratings-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px 24px;
    margin-bottom: 20px;
}

.shoe-sub-rating-group {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0 !important;
}

.shoe-sub-rating-group label {
    margin-bottom: 0 !important;
    white-space: nowrap;
}

.shoe-star-rating-sm {
    gap: 2px;
}

/* Field hints and word count */
.shoe-field-hint {
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 12px;
    color: #9ca3af;
    margin: 0 0 6px 0;
}

.shoe-word-count {
    text-align: right;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 12px;
    color: #9ca3af;
    margin-top: 4px;
}

.shoe-word-count .over-limit {
    color: #ef4444;
    font-weight: 600;
}

/* Form actions */
.shoe-form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

.btn-shoe-cancel {
    padding: 10px 24px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #fff;
    color: #6b7280;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
}

.btn-shoe-cancel:hover {
    border-color: #04132D;
    color: #04132D;
}

.btn-shoe-submit {
    padding: 10px 24px;
    border: none;
    border-radius: 8px;
    background: #96ff94;
    color: #04132D;
    font-family: "Inter", "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
}

.btn-shoe-submit:hover {
    background: #7de87b;
}

.btn-shoe-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ============================================
   Responsive
   ============================================ */

/* Narrow desktop */
@media (max-width: 991px) {
    .shoe-cards-grid {
        grid-template-columns: 1fr;
    }

    .shoe-form-row-3col {
        grid-template-columns: 1fr 1fr;
    }

    .shoe-sub-ratings-form {
        grid-template-columns: 1fr;
    }
}

/* Mobile */
@media (max-width: 600px) {
    .shoe-locker-header {
        flex-direction: column;
        align-items: center;
    }

    .btn-add-shoe-review {
        width: 100%;
        justify-content: center;
    }

    .shoe-card-main {
        gap: 10px;
        padding: 12px;
    }

    .shoe-card-image {
        width: 64px;
        height: 64px;
    }

    .shoe-card-model {
        font-size: 14px;
    }

    .shoe-card-details {
        padding: 12px;
    }

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

    .shoe-sub-ratings {
        grid-template-columns: 1fr;
    }

    .shoe-modal-content .modal-columns {
        display: block;
    }

    .shoe-modal-content {
        max-width: 100%;
    }

    .shoe-form-row-2col,
    .shoe-form-row-3col {
        grid-template-columns: 1fr;
    }

    .shoe-sub-ratings-form {
        grid-template-columns: 1fr;
    }

    .shoe-sub-rating-group {
        flex-direction: row;
    }

    .shoe-modal-scroll-wrapper {
        padding: 80px 10px 40px;
    }

    #shoe-review-form {
        padding: 16px;
    }

    .shoe-form-actions {
        flex-direction: column;
    }

    .btn-shoe-cancel,
    .btn-shoe-submit {
        width: 100%;
        text-align: center;
    }

    .shoe-mileage-wrapper {
        flex-direction: column;
        align-items: flex-start;
    }
}
