/* Base Styles and Variables */
:root {
    --primary-color: #6200ee;
    --primary-light: #bb86fc;
    --primary-dark: #4b01d0;
    --accent-color: #03dac6;
    --text-color: #333333;
    --light-text: #666666;
    --background-color: #f5f5f7;
    --card-background: #ffffff;
    --border-color: #dddddd;
    --success-color: #4caf50;
    --error-color: #f44336;
    --warning-color: #ff9800;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

/* Fix for hidden elements */
[hidden] {
    display: none !important;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

h1,
h2,
h3 {
    margin-bottom: 0.5rem;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Header */
header {
    background-color: var(--primary-color);
    color: white;
    padding: 1.5rem 0;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

header h1 {
    display: flex;
    align-items: center;
    gap: 10px;
}

header p {
    margin-top: 0.5rem;
}

/* Progress Indicator - ENHANCED */
.progress-steps {
    display: flex;
    justify-content: space-between;
    padding: 0 1rem;
    margin-bottom: 2rem;
    position: relative;
}

.progress-steps::before {
    content: "";
    position: absolute;
    top: 15px;
    left: 10%;
    width: 80%;
    height: 4px;
    background-color: var(--border-color);
    z-index: 0;
}

.progress-bar {
    position: absolute;
    top: 15px;
    left: 10%;
    height: 4px;
    background-color: var(--primary-color);
    z-index: 1;
    transition: width 0.5s ease;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 2;
}

.step-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: var(--card-background);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
    transition: var(--transition);
}

.step.active .step-circle {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.step.completed .step-circle {
    background-color: var(--success-color);
    border-color: var(--success-color);
    color: white;
}

.step-label {
    font-size: 0.875rem;
    color: var(--light-text);
    font-weight: 500;
    text-align: center;
    transition: var(--transition);
}

.step.active .step-label {
    color: var(--primary-color);
    font-weight: 600;
}

.step.completed .step-label {
    color: var(--success-color);
}

/* Main Layout */
.app-container {
    display: flex;
    gap: 20px;
    margin-bottom: 2rem;
    position: relative;
}

.panel {
    background: var(--card-background);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    margin-bottom: 1rem;
    transition: var(--transition);
    position: relative;
}

.panel::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: var(--border-radius);
    border: 2px solid transparent;
    transition: var(--transition);
    pointer-events: none;
}

.panel.active::after {
    border-color: var(--primary-color);
}

.panel-number {
    position: absolute;
    top: -12px;
    left: -12px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    z-index: 2;
}

.person-panel {
    flex: 6;
}

.clothing-panel {
    flex: 4;
}

/* Enhanced Initial State Styles */
.initial-state {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1rem;
}

.upload-illustration {
    position: relative;
    margin-bottom: 1.5rem;
}

.main-icon {
    font-size: 4rem;
    color: var(--border-color);
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.initial-state:hover .main-icon {
    color: var(--primary-light);
}

.upload-arrow {
    position: absolute;
    top: -15px;
    right: -15px;
    width: 30px;
    height: 30px;
    background-color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    animation: bounce 1.5s infinite;
}

@keyframes bounce {
    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.initial-state h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.drag-hint {
    font-size: 0.8rem;
    color: var(--light-text);
    margin-top: 0.5rem;
}

/* Enhanced Dropzone Styles */
.dropzone {
    border: 2px dashed var(--border-color);
    border-radius: var(--border-radius);
    padding: 2rem;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: var(--transition);
    overflow: hidden;
}

.dropzone.drag-over {
    border-color: var(--primary-color);
    background-color: rgba(98, 0, 238, 0.05);
}

.dropzone.active {
    border-color: var(--primary-light);
    animation: pulse 2s infinite;
}

/* Add can-receive state for dropzone */
.dropzone.can-receive {
    border: 2px dashed var(--primary-light);
    position: relative;
}

/* .dropzone.can-receive:after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100px;
    height: 100px;
    transform: translate(-50%, -50%);
    background-image: radial-gradient(
        circle,
        rgba(98, 0, 238, 0.05) 0%,
        rgba(98, 0, 238, 0.1) 30%,
        rgba(98, 0, 238, 0.15) 60%,
        rgba(98, 0, 238, 0) 100%
    );
    pointer-events: none;
    z-index: 5;
} */

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(98, 0, 238, 0.2);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(98, 0, 238, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(98, 0, 238, 0);
    }
}

/* Enhanced drop indicator */
.drop-here-indicator {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 0.75rem 1.5rem;
    background-color: rgba(98, 0, 238, 0.9);
    color: white;
    border-radius: var(--border-radius);
    pointer-events: none;
    opacity: 0.3; /* Slightly visible always when can-receive is active */
    transition: all 0.3s ease;
    z-index: 8;
    font-weight: 500;
}

.dropzone.drag-over .drop-here-indicator {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* NEW - Add animation to indicate draggability */
.draggable-hint {
    display: flex;
    align-items: center;
    margin-top: 0.5rem;
    color: var(--light-text);
    font-size: 0.9rem;
    background-color: rgba(98, 0, 238, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.draggable-hint i {
    font-size: 1rem;
    margin-right: 0.5rem;
    animation: moveLeftRight 1.5s infinite;
}

@keyframes moveLeftRight {
    0%,
    100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(5px);
    }
}

/* Buttons */
.upload-btn,
.btn {
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    margin-top: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.pulse-animation {
    animation: pulse 2s infinite;
}

.upload-btn:hover,
.btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.upload-btn:focus,
.btn:focus {
    outline: 2px solid var(--primary-light);
    outline-offset: 2px;
}

.replace-btn {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 0.5rem;
    border-radius: 20px;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: var(--transition);
    z-index: 5;
}

.replace-btn:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.clear-btn {
    color: var(--error-color);
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    transition: var(--transition);
}

.clear-btn:hover {
    background-color: rgba(244, 67, 54, 0.1);
}

/* Image Preview */
.image-preview {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.image-preview img,
.result-container img {
    max-width: 100%;
    max-height: 360px;
    border-radius: var(--border-radius);
    object-fit: contain;
}

/* Enhanced Processing Overlay */
.processing-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 10;
    border-radius: var(--border-radius);
    padding: 2rem;
}

.processing-steps {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 20px;
    width: 100%;
    max-width: 300px;
}

.processing-step {
    display: flex;
    align-items: center;
    gap: 12px;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.processing-step.active {
    opacity: 1;
}

.processing-step.completed .step-icon {
    background-color: var(--success-color);
}

.processing-step.completed .step-icon .spinner-small {
    display: none;
}

.processing-step.completed .step-icon:after {
    content: "\f00c";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    color: white;
}

.step-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background-color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

.spinner-small {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.processing-estimate {
    font-size: 0.9rem;
    color: var(--light-text);
    margin-bottom: 1rem;
}

.processing-progress {
    width: 100%;
    max-width: 300px;
    height: 8px;
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 10px;
}

.processing-progress .progress-bar {
    position: relative;
    height: 100%;
    background-color: var(--primary-color);
    width: 0;
    transition: width 0.5s ease;
    top: 0;
    left: 0;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Result Container */
.result-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.result-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

/* Enhanced Clothing Grid */
.clothing-container {
    margin-bottom: 1.5rem;
}

.clothing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

/* Enhanced draggable clothing items */
.clothing-item {
    height: 120px;
    border-radius: var(--border-radius);
    overflow: hidden;
    position: relative;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    background-color: #f9f9f9;
}

.clothing-item:not(.add-item) {
    cursor: grab;
    animation: gentle-float 3s ease-in-out infinite;
}

@keyframes gentle-float {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-3px);
    }
}

.clothing-item:not(.add-item):hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

/* Add "Drag me!" label to first item */
.clothing-item.first-item:not(.add-item):before {
    content: "Drag me!";
    position: absolute;
    top: -10px;
    right: -10px;
    background-color: var(--primary-color);
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    z-index: 10;
    animation: pulse 2s infinite;
}

/* Enhanced drag handle indicator */
.clothing-item::after {
    content: "\f256";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    position: absolute;
    bottom: 5px;
    left: 5px;
    font-size: 14px;
    color: rgba(0, 0, 0, 0.5);
    opacity: 0.7; /* Always visible */
    transition: opacity 0.3s ease;
}

.clothing-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.clothing-item .remove-btn {
    position: absolute;
    top: 5px;
    right: 5px;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    opacity: 0;
    transition: var(--transition);
    z-index: 3;
}

.clothing-item:hover .remove-btn {
    opacity: 1;
}

/* Default Clothing Items Styles */
.clothing-item.default-item {
    border: 2px solid var(--primary-light);
}

.default-badge {
    position: absolute;
    top: 5px;
    left: 5px;
    background-color: var(--primary-light);
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    z-index: 3;
}

.add-item {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background: white;
    transition: var(--transition);
}

.add-item:hover {
    background-color: #f0f0f0;
}

.add-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-light);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: var(--transition);
}

.add-item:hover .add-icon {
    transform: scale(1.1);
}

.clothing-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Dragging states */
.clothing-item.dragging {
    opacity: 0.5;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.dropzone.highlight {
    border: 2px dashed var(--primary-color);
    background-color: rgba(98, 0, 238, 0.05);
}

/* Contextual Hint Styles */
.contextual-hint {
    position: absolute;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    padding: 1rem;
    max-width: 250px;
    z-index: 100;
    animation: pop-in 0.3s ease-out;
}

@keyframes pop-in {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.hint-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.hint-icon {
    color: var(--primary-color);
    font-size: 1.5rem;
    flex-shrink: 0;
}

.hint-message {
    font-size: 0.9rem;
}

.hint-arrow {
    position: absolute;
    width: 12px;
    height: 12px;
    background-color: white;
    transform: rotate(45deg);
}

.hint-close {
    position: absolute;
    top: 5px;
    right: 5px;
    background: none;
    border: none;
    color: var(--light-text);
    font-size: 0.8rem;
    cursor: pointer;
    padding: 4px;
}

/* Toast Messages */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--card-background);
    color: var(--text-color);
    padding: 1rem;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 300px;
    max-width: 400px;
    z-index: 1000;
    animation: slideIn 0.3s forwards;
}

.toast.error .toast-icon {
    color: var(--error-color);
}

.toast.success .toast-icon {
    color: var(--success-color);
}

.toast.info .toast-icon {
    color: var(--primary-color);
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toast-icon {
    font-size: 1.25rem;
}

.toast-close {
    color: var(--light-text);
    padding: 5px;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Enhanced Tooltip */
.tooltip {
    position: relative;
}

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-size: 0.875rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 100;
}

.tooltip::after {
    content: "";
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%) translateY(100%);
    border-width: 5px;
    border-style: solid;
    border-color: rgba(0, 0, 0, 0.8) transparent transparent transparent;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 100;
}

.tooltip:hover::before,
.tooltip:hover::after {
    opacity: 1;
    visibility: visible;
}

/* Footer */
footer {
    background-color: var(--primary-dark);
    color: white;
    padding: 1.5rem 0;
    text-align: center;
    margin-top: 3rem;
}

/* Mobile Touch Controls - ENHANCED */
.mobile-controls {
    display: none;
}

@media (max-width: 768px) {
    .mobile-controls {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        margin-top: 1rem;
        background-color: rgba(98, 0, 238, 0.05);
        padding: 1rem;
        border-radius: var(--border-radius);
        border: 1px solid var(--primary-light);
    }

    .mobile-controls h4 {
        color: var(--primary-color);
        margin-bottom: 0.5rem;
        font-weight: 500;
    }

    .clothing-select-container {
        width: 100%;
    }

    .clothing-select {
        width: 100%;
        padding: 0.75rem;
        border-radius: var(--border-radius);
        border: 1px solid var(--border-color);
        background-color: white;
        appearance: none;
        cursor: pointer;
    }

    .try-on-mobile-btn {
        width: 100%;
        background-color: var(--primary-color);
        color: white;
        padding: 1rem;
        border-radius: var(--border-radius);
        text-align: center;
        font-weight: 500;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
    }

    .try-on-mobile-btn:disabled {
        background-color: var(--border-color);
        cursor: not-allowed;
    }
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .app-container {
        gap: 15px;
    }

    .progress-steps {
        padding: 0;
    }
}

@media (max-width: 768px) {
    .app-container {
        flex-direction: column;
    }

    .person-panel,
    .clothing-panel {
        flex: 1;
        width: 100%;
    }

    .dropzone {
        min-height: 300px;
    }

    .progress-steps::before,
    .progress-bar {
        left: 5%;
        width: 90%;
    }

    .step-label {
        font-size: 0.75rem;
    }

    .contextual-hint {
        max-width: 90%;
        left: 5% !important;
        right: 5% !important;
    }
}

@media (max-width: 576px) {
    header {
        padding: 1rem 0;
    }

    header h1 {
        font-size: 1.5rem;
    }

    .panel {
        padding: 1rem;
    }

    .clothing-grid {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    }

    .clothing-item {
        height: 100px;
    }

    .clothing-actions {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }

    .progress-steps {
        display: none;
    }

    .toast {
        min-width: auto;
        max-width: 90%;
        left: 50%;
        transform: translateX(-50%);
        right: auto;
        bottom: 10px;
    }

    @keyframes slideIn {
        from {
            transform: translateX(-50%) translateY(100%);
            opacity: 0;
        }
        to {
            transform: translateX(-50%) translateY(0);
            opacity: 1;
        }
    }

    @keyframes slideOut {
        from {
            transform: translateX(-50%) translateY(0);
            opacity: 1;
        }
        to {
            transform: translateX(-50%) translateY(100%);
            opacity: 0;
        }
    }
}

/* History Panel Styles */
.history-panel {
    margin-top: 20px;
}

.history-panel.hidden {
    display: none;
}

.history-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.history-item {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    background-color: var(--card-background);
    transition: var(--transition);
}

.history-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.history-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.history-actions {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0.5rem;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0) 100%);
    opacity: 0;
    transition: var(--transition);
}

.history-item:hover .history-actions {
    opacity: 1;
}

.history-btn {
    width: 32px;
    height: 32px;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    transition: var(--transition);
}

.history-btn:hover {
    background-color: white;
    transform: scale(1.1);
}

.history-timestamp {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 0.5rem;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    font-size: 0.8rem;
    text-align: center;
}

.history-toggle-btn {
    display: block;
    margin: 1.5rem auto;
    background-color: var(--primary-light);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.history-toggle-btn:hover {
    background-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

@media (max-width: 768px) {
    .history-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .history-image {
        height: 150px;
    }
}
