/* ============================================
   GLOBAL STYLES & RESET
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Color Palette */
    --bg-primary: #0a0e1a;
    --bg-secondary: #1a1f35;
    --bg-card: #252b42;
    --text-primary: #ffffff;
    --text-secondary: #b8c1ec;
    --accent-primary: #6366f1;
    --accent-hover: #818cf8;
    --border-color: #374151;
    --grey-circle: #4b5563;
    
    /* Spacing */
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    
    /* Typography */
    --font-primary: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    
    /* Animation */
    --transition-speed: 0.15s;
}

body {
    font-family: var(--font-primary);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* ============================================
   ANIMATED STARRY BACKGROUND
   ============================================ */

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, white, transparent),
        radial-gradient(2px 2px at 60px 70px, white, transparent),
        radial-gradient(1px 1px at 50px 50px, white, transparent),
        radial-gradient(1px 1px at 130px 80px, white, transparent),
        radial-gradient(2px 2px at 90px 10px, white, transparent),
        radial-gradient(1px 1px at 150px 150px, white, transparent),
        radial-gradient(1px 1px at 200px 100px, white, transparent),
        radial-gradient(2px 2px at 170px 30px, white, transparent);
    background-repeat: repeat;
    background-size: 200px 200px;
    animation: twinkle 5s ease-in-out infinite;
    opacity: 0.6;
    z-index: 0;
    pointer-events: none;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 0.3; }
}

/* Custom background image (when enabled) */
body.bg-custom::before {
    animation: none;
    background-image: var(--custom-bg-image);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.6;
}

body.bg-custom::after {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, transparent 0%, rgba(10, 14, 26, 0.8) 100%);
    z-index: 0;
    pointer-events: none;
}

/* Ensure content appears above the starry background */
header, main, footer {
    position: relative;
    z-index: 1;
}

/* ============================================
   HEADER
   ============================================ */

header {
    text-align: center;
    padding: var(--spacing-xl) var(--spacing-md);
    background: linear-gradient(180deg, rgba(26, 31, 53, 0.8) 0%, transparent 100%);
}

/* Header title container with logo */
.header-title-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: var(--spacing-sm);
    flex-wrap: nowrap;
}

/* Header logo styling */
.header-logo {
    width: clamp(60px, 8vw, 200px);
    height: clamp(60px, 8vw, 200px);
    object-fit: contain;
    flex-shrink: 0;
    filter: drop-shadow(0 2px 8px rgba(99, 102, 241, 0.3));
    transition: all var(--transition-speed) ease;
}

.header-logo:hover {
    transform: scale(1.05) rotate(5deg);
    filter: drop-shadow(0 8px 16px rgba(99, 102, 241, 0.5));
}

.main-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 0;
    line-height: 1.2;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--text-secondary);
    font-weight: 300;
    margin-bottom: 0.5rem;
}

.tagline {
    font-size: clamp(0.85rem, 1.5vw, 1rem);
    color: var(--text-secondary);
    font-weight: 300;
    font-style: italic;
    opacity: 0.8;
}

/* ============================================
   CONTROLS (SEARCH & FILTER)
   ============================================ */

.controls {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-md);
    justify-content: center;
    align-items: center;
    padding: var(--spacing-lg) var(--spacing-md);
    max-width: 1000px;
    margin: 0 auto;
}

#searchInput,
#filterType {
    padding: 0.75rem 1rem;
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--transition-speed) ease;
}

#searchInput {
    flex: 1;
    min-width: 250px;
}

#searchInput:focus,
#filterType:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

#filterType {
    min-width: 150px;
    cursor: pointer;
}

/* ============================================
   TOGGLE SWITCH FOR UNPHOTOGRAPHED OBJECTS
   ============================================ */

.toggle-container {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: 0.5rem;
}

.toggle-label {
    color: var(--text-secondary);
    font-size: 0.95rem;
    user-select: none;
    white-space: nowrap;
}

/* Toggle switch styling */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 26px;
    cursor: pointer;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--grey-circle);
    transition: var(--transition-speed);
    border-radius: 26px;
    border: 2px solid var(--border-color);
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 2px;
    bottom: 2px;
    background-color: var(--text-primary);
    transition: var(--transition-speed);
    border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.toggle-switch input:focus + .toggle-slider {
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

.toggle-switch:hover .toggle-slider {
    border-color: var(--accent-hover);
}

/* Responsive toggle on mobile */
@media (max-width: 768px) {
    .toggle-container {
        width: 100%;
        justify-content: center;
    }
}

/* ============================================
   CATALOGS CONTAINER & SECTIONS
   ============================================ */

.catalogs-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: var(--spacing-lg);
}

.catalog-section {
    margin-bottom: var(--spacing-xl);
    background-color: rgba(37, 43, 66, 0.3);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: all var(--transition-speed) ease;
}

.catalog-section:hover {
    border-color: var(--accent-primary);
}

/* Catalog header (clickable to expand/collapse) */
.catalog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-lg);
    cursor: pointer;
    background-color: var(--bg-card);
    transition: background-color var(--transition-speed) ease;
    user-select: none;
}

.catalog-header:hover {
    background-color: rgba(99, 102, 241, 0.1);
}

.catalog-header-left {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    flex: 1;
}

.catalog-toggle-icon {
    font-size: 1.5rem;
    color: var(--accent-primary);
    transition: transform var(--transition-speed) ease;
    width: 30px;
    text-align: center;
}

.catalog-section.collapsed .catalog-toggle-icon {
    transform: rotate(-90deg);
}

.catalog-info {
    flex: 1;
}

.catalog-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: 0.25rem;
}

.catalog-description {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
}

.catalog-stats {
    display: flex;
    gap: var(--spacing-lg);
    align-items: center;
}

.catalog-stat {
    text-align: center;
    padding: 0.5rem 1rem;
    background-color: rgba(99, 102, 241, 0.1);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.catalog-stat-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.catalog-stat-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Catalog content (collapsible) */
.catalog-content {
    max-height: 10000px;
    overflow: hidden;
    transition: max-height 0.5s ease;
}

.catalog-section.collapsed .catalog-content {
    max-height: 0;
}

/* Gallery grid within each catalog */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: var(--spacing-lg);
    padding: var(--spacing-lg);
}

/* Empty catalog message */
.empty-catalog {
    padding: var(--spacing-xl);
    text-align: center;
    color: var(--text-secondary);
    font-style: italic;
}

.empty-catalog-icon {
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
    opacity: 0.5;
}

/* Responsive grid adjustments */
@media (min-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
}

/* Mobile responsive for catalog headers */
@media (max-width: 768px) {
    .catalog-header {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--spacing-md);
    }
    
    .catalog-header-left {
        width: 100%;
    }
    
    .catalog-stats {
        width: 100%;
        justify-content: space-around;
    }
    
    .catalog-title {
        font-size: 1.25rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: var(--spacing-md);
    }
}

/* ============================================
   GALLERY ITEM (CIRCLE)
   ============================================ */

.gallery-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: 50%;
    overflow: hidden;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    background-color: var(--bg-card);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-item:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.3);
}

/* Greyed out placeholder circles */
.gallery-item.placeholder {
    background-color: var(--grey-circle);
    cursor: default;
    opacity: 0.6;
}

.gallery-item.placeholder:hover {
    transform: scale(1);
    box-shadow: none;
}

/* Gallery item with actual image */
.gallery-item.has-image {
    border-color: var(--accent-primary);
}

.gallery-item.has-image:hover {
    border-color: var(--accent-hover);
}

/* Object image */
.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    border-radius: 50%;
}

/* Type icon for unphotographed objects */
.gallery-item .type-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 104%;
    height: 104%;
    object-fit: cover;
    object-position: center center;
    border-radius: 50%;
    opacity: 0.5;
    filter: grayscale(30%);
    transition: all var(--transition-speed) ease;
}

.gallery-item.placeholder:hover .type-icon {
    opacity: 0.7;
    filter: grayscale(10%);
}

/* Object label */
.object-label {
    position: absolute;
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.875rem;
    font-weight: 600;
    white-space: nowrap;
    pointer-events: none;
    z-index: 10;
}

/* For placeholder circles without images (no type icon) */
.gallery-item.placeholder .object-label {
    position: static;
    transform: none;
    background-color: transparent;
    font-size: 1rem;
    color: var(--text-secondary);
    z-index: 10;
}

/* For placeholder circles with type icons, keep label positioned absolutely */
.gallery-item.placeholder:has(.type-icon) .object-label {
    position: absolute;
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    font-size: 0.875rem;
    color: var(--text-primary);
    z-index: 10;
}

/* ============================================
   FULLSCREEN MODAL WITH COLLAPSIBLE DETAILS
   ============================================ */

.fullscreen-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.98);
    z-index: 2000;
    animation: fadeIn 0.3s ease;
}

.fullscreen-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

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

/* Fullscreen image */
.fullscreen-modal-image {
    max-width: 95vw;
    max-height: 95vh;
    width: auto;
    height: auto;
    object-fit: contain;
    position: relative;
    z-index: 1;
}

/* Close button */
.fullscreen-modal-close {
    position: absolute;
    top: 2rem;
    right: 2rem;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid white;
    color: white;
    font-size: 2rem;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    backdrop-filter: blur(10px);
    z-index: 3;
}

.fullscreen-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

/* Details tab */
.details-tab {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2;
    transition: transform 0.3s ease;
}

/* Details tab handle (always visible) */
.details-tab-handle {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    cursor: pointer;
    border-top: 2px solid rgba(99, 102, 241, 0.5);
    transition: all 0.3s ease;
    user-select: none;
}

.details-tab-handle:hover {
    background: rgba(0, 0, 0, 0.8);
    border-top-color: var(--accent-primary);
}

.details-tab-icon {
    font-size: 1.5rem;
}

.details-tab-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.details-tab-arrow {
    font-size: 1.2rem;
    color: var(--accent-primary);
    transition: transform 0.3s ease;
}

/* Collapsed state */
.details-tab:not(.expanded) .details-tab-arrow {
    transform: rotate(180deg);
}

/* Details tab content (collapsible) */
.details-tab-content {
    background: rgba(10, 14, 26, 0.95);
    backdrop-filter: blur(20px);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.details-tab.expanded .details-tab-content {
    max-height: 80vh;
    overflow-y: auto;
    padding: 2rem;
}

/* Smooth scrolling for details content */
.details-tab-content {
    scrollbar-width: thin;
    scrollbar-color: var(--accent-primary) rgba(255, 255, 255, 0.1);
}

.details-tab-content::-webkit-scrollbar {
    width: 8px;
}

.details-tab-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.details-tab-content::-webkit-scrollbar-thumb {
    background: var(--accent-primary);
    border-radius: 4px;
}

.details-tab-content::-webkit-scrollbar-thumb:hover {
    background: var(--accent-hover);
}

.modal-details {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
}

@media (min-width: 768px) {
    .modal-details {
        grid-template-columns: 1fr 1fr;
    }
}

@media (min-width: 1200px) {
    .modal-details {
        grid-template-columns: repeat(3, 1fr);
    }
}

.modal-info,
.modal-description,
.modal-technical {
    grid-column: span 1;
}

@media (min-width: 1200px) {
    .modal-description {
        grid-column: span 2;
    }
}

.modal-title {
    font-size: 2rem;
    color: var(--accent-primary);
    margin-bottom: var(--spacing-sm);
}

.modal-info {
    background-color: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: 8px;
    border-left: 4px solid var(--accent-primary);
}

.modal-info p {
    margin-bottom: var(--spacing-sm);
}

.modal-info strong {
    color: var(--accent-primary);
}

.modal-description,
.modal-technical {
    background-color: var(--bg-card);
    padding: var(--spacing-md);
    border-radius: 8px;
}

.modal-description h3,
.modal-technical h3 {
    color: var(--accent-primary);
    margin-bottom: var(--spacing-sm);
    font-size: 1.25rem;
}

.modal-technical ul {
    list-style: none;
    padding-left: 0;
}

.modal-technical li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.modal-technical li:last-child {
    border-bottom: none;
}

/* ============================================
   IMAGE HISTORY GALLERY (in modal)
   ============================================ */

.image-history-gallery {
    background-color: var(--bg-card);
    border-radius: 12px;
    padding: var(--spacing-md);
    border: 1px solid var(--border-color);
}

/* Position gallery in grid - spans 2 columns on large screens */
@media (min-width: 1200px) {
    .image-history-gallery {
        grid-column: 2 / 4;
    }
}

.gallery-section-title {
    font-size: 1.1rem;
    color: var(--accent-primary);
    margin-bottom: var(--spacing-md);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.gallery-thumbnails {
    display: flex;
    gap: var(--spacing-md);
    overflow-x: auto;
    padding-bottom: var(--spacing-sm);
    scrollbar-width: thin;
    scrollbar-color: var(--accent-primary) rgba(255, 255, 255, 0.1);
}

.gallery-thumbnails::-webkit-scrollbar {
    height: 6px;
}

.gallery-thumbnails::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.gallery-thumbnails::-webkit-scrollbar-thumb {
    background: var(--accent-primary);
    border-radius: 3px;
}

.gallery-thumbnail {
    flex-shrink: 0;
    width: 120px;
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid var(--border-color);
    transition: all var(--transition-speed) ease;
    background-color: var(--bg-secondary);
}

.gallery-thumbnail:hover {
    border-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.gallery-thumbnail.active {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.3);
}

.gallery-thumbnail img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    display: block;
}

.thumbnail-label {
    display: block;
    padding: 0.5rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    background-color: var(--bg-primary);
}

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

/* Responsive adjustments for image gallery */
@media (max-width: 768px) {
    .gallery-thumbnail {
        width: 100px;
    }
    
    .gallery-thumbnail img {
        height: 65px;
    }
    
    .thumbnail-label {
        padding: 0.375rem;
        font-size: 0.7rem;
    }
}

@media (max-width: 480px) {
    .gallery-thumbnail {
        width: 85px;
    }
    
    .gallery-thumbnail img {
        height: 55px;
    }
    
    .thumbnail-label {
        padding: 0.25rem;
        font-size: 0.65rem;
    }
    
    .gallery-section-title {
        font-size: 1rem;
    }
}

/* ============================================
   FOOTER
   ============================================ */

footer {
    text-align: center;
    padding: var(--spacing-lg);
    color: var(--text-secondary);
    background: linear-gradient(0deg, rgba(26, 31, 53, 0.8) 0%, transparent 100%);
    margin-top: var(--spacing-xl);
}

footer a {
    color: var(--accent-primary);
    text-decoration: none;
    transition: color var(--transition-speed) ease;
}

footer a:hover {
    color: var(--accent-hover);
    text-decoration: underline;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 768px) {
    /* Header responsive adjustments */
    .header-title-container {
        flex-direction: column;
        gap: var(--spacing-sm);
    }
    
    .header-logo {
        width: clamp(50px, 15vw, 140px);
        height: clamp(50px, 15vw, 140px);
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: var(--spacing-md);
    }
    
    .modal-title {
        font-size: 1.5rem;
    }
    
    /* Mobile-specific fullscreen modal adjustments */
    .fullscreen-modal-image {
        max-width: 100vw;
        max-height: 80vh;
    }
    
    .fullscreen-modal-close {
        top: 1rem;
        right: 1rem;
        width: 48px;
        height: 48px;
        font-size: 1.5rem;
    }
    
    /* Details tab adjustments for mobile */
    .details-tab-handle {
        padding: 0.875rem 1rem;
    }
    
    .details-tab-icon {
        font-size: 1.25rem;
    }
    
    .details-tab-text {
        font-size: 0.95rem;
    }
    
    .details-tab-arrow {
        font-size: 1rem;
    }
    
    .details-tab.expanded .details-tab-content {
        max-height: 70vh;
        padding: 1.25rem;
    }
    
    /* Make details grid single column on mobile */
    .details-tab-content .modal-details {
        grid-template-columns: 1fr;
    }
}

/* Extra small phones */
@media (max-width: 480px) {
    .fullscreen-modal-image {
        max-height: 75vh;
    }
    
    .fullscreen-modal-close {
        top: 0.75rem;
        right: 0.75rem;
        width: 44px;
        height: 44px;
        font-size: 1.25rem;
    }
    
    .details-tab-handle {
        padding: 0.75rem 0.875rem;
        gap: 0.5rem;
    }
    
    .details-tab-text {
        font-size: 0.875rem;
    }
    
    .details-tab.expanded .details-tab-content {
        max-height: 65vh;
        padding: 1rem;
    }
    
    .modal-title {
        font-size: 1.25rem;
    }
}

/* ============================================
   INFO MODALS (ABOUT & CONTACT)
   ============================================ */

/* Base modal overlay (hidden by default) */
.modal {
    display: none;                       /* hide until .active is added */
    position: fixed;                     /* overlay over the whole viewport */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);/* dark backdrop */
    z-index: 1500;                       /* above header/main/footer, below fullscreen image modal */
    align-items: center;                 /* center contents vertically */
    justify-content: center;             /* center contents horizontally */
}

/* When JS adds .active, show as flex overlay */
.modal.active {
    display: flex;
}

/* Inner modal box */
.modal-content {
    background-color: var(--bg-secondary);
    border-radius: 12px;
    max-width: 900px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    border: 1px solid var(--border-color);
}

/* Close button inside info modals (you can tweak if desired) */
.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 2rem;
    cursor: pointer;
    transition: color var(--transition-speed) ease;
}

.modal-close:hover {
    color: var(--accent-primary);
}

/* Existing styles for info modals */
.info-modal-body {
    padding: var(--spacing-xl);
    max-width: 800px;
    margin: 0 auto;
}

.info-modal-title {
    font-size: 2rem;
    color: var(--accent-primary);
    margin-bottom: var(--spacing-lg);
    text-align: center;
}

/* About Section */
.about-section {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.about-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
    padding: var(--spacing-lg);
    background-color: var(--bg-card);
    border-radius: 12px;
    border-left: 4px solid var(--accent-primary);
}

.about-avatar {
    font-size: 4rem;
    line-height: 1;
}

.about-identity h3 {
    font-size: 1.5rem;
    color: var(--accent-primary);
    margin-bottom: 0.5rem;
}

.about-location,
.about-experience {
    color: var(--text-secondary);
    margin: 0.25rem 0;
}

.about-bio,
.about-equipment,
.about-goals {
    background-color: var(--bg-card);
    padding: var(--spacing-lg);
    border-radius: 12px;
}

.about-bio h4,
.about-equipment h4,
.about-goals h4 {
    color: var(--accent-primary);
    margin-bottom: var(--spacing-md);
    font-size: 1.25rem;
}

.about-bio p,
.about-goals p {
    line-height: 1.8;
    color: var(--text-secondary);
}

#aboutEquipmentList {
    list-style: none;
    padding: 0;
}

#aboutEquipmentList li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-secondary);
}

#aboutEquipmentList li:before {
    content: "▸";
    position: absolute;
    left: 0;
    color: var(--accent-primary);
}

/* Contact Section */
.contact-section {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.contact-message {
    background-color: var(--bg-card);
    padding: var(--spacing-lg);
    border-radius: 12px;
    border-left: 4px solid var(--accent-primary);
}

.contact-message p {
    line-height: 1.8;
    color: var(--text-secondary);
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.contact-method {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
    padding: var(--spacing-lg);
    background-color: var(--bg-card);
    border-radius: 12px;
    transition: all var(--transition-speed) ease;
}

.contact-method:hover {
    transform: translateX(5px);
    border-left: 4px solid var(--accent-primary);
}

.contact-icon {
    font-size: 2.5rem;
    line-height: 1;
}

.contact-details h4 {
    color: var(--accent-primary);
    margin-bottom: 0.5rem;
}

.contact-details a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color var(--transition-speed) ease;
    font-size: 1.1rem;
}

.contact-details a:hover {
    color: var(--accent-primary);
}

.contact-social {
    background-color: var(--bg-card);
    padding: var(--spacing-lg);
    border-radius: 12px;
}

.contact-social h4 {
    color: var(--accent-primary);
    margin-bottom: var(--spacing-md);
}

.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-md);
}

.social-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background-color: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all var(--transition-speed) ease;
    font-weight: 500;
}

.social-link:hover {
    border-color: var(--accent-primary);
    background-color: rgba(99, 102, 241, 0.1);
    transform: translateY(-2px);
}

.social-link-icon {
    font-size: 1.2rem;
}

.contact-footer {
    text-align: center;
    padding: var(--spacing-lg);
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.hidden {
    display: none !important;
}

/* Loading state */
.loading {
    text-align: center;
    padding: var(--spacing-xl);
    color: var(--text-secondary);
}

/* Error state */
.error-message {
    background-color: #ef4444;
    color: white;
    padding: var(--spacing-md);
    border-radius: 8px;
    margin: var(--spacing-md);
    text-align: center;
}

/* ============================================
   SCROLL TO TOP BUTTON
   ============================================ */

.scroll-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-hover) 100%);
    border: 2px solid var(--border-color);
    border-radius: 50%;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    transition: all var(--transition-speed) ease;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:hover {
    background: linear-gradient(135deg, var(--accent-hover) 0%, #a5b4fc 100%);
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.5);
}

.scroll-to-top:active {
    transform: translateY(-2px);
}

.scroll-to-top svg {
    width: 24px;
    height: 24px;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    .scroll-to-top {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 48px;
        height: 48px;
    }
    
    .scroll-to-top svg {
        width: 20px;
        height: 20px;
    }
}

