/* Milena Ferencevic Portfolio - Global Styles */

/* CSS Variables for consistent theming */
:root {
    /* Colors */
    --bg-primary: #0D1117;
    --fg-primary: #F0F6FC;
    --accent-color: #CD5C5C;
    --accent-hover: #B44545;
    --border-color: #30363D;
    --card-bg: #161B22;
    --card-bg-light: rgba(255, 255, 255, 0.1);
    --muted-fg: rgba(255, 255, 255, 0.7);
    
    /* Spacing */
    --container-padding: 1rem;
    --section-padding: 4rem 0;
    --card-padding: 2rem;
    
    /* Typography */
    --font-sans: 'Inter', sans-serif;
    --font-serif: 'Playfair Display', serif;
    
    /* Borders & Radius */
    --border-radius: 0.5rem;
    --border-radius-lg: 0.75rem;
    
    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.2);
    --shadow-hover: 0 15px 35px rgba(0, 0, 0, 0.2);
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-medium: 0.3s ease;
    --transition-slow: 0.6s ease;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    color: var(--fg-primary) !important;
}

body {
    background-color: var(--bg-primary) !important;
    color: var(--fg-primary) !important;
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
}

.font-serif {
    font-family: var(--font-serif) !important;
}

/* Typography */
h1, h2, h3, h4, h5, h6, p, span, div, a, button, label, input, textarea, li, td, th, blockquote {
    color: var(--fg-primary) !important;
}

.text-sensual {
    color: var(--accent-color) !important;
}

.text-muted-foreground {
    color: var(--muted-fg) !important;
}

/* Layout Components */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

/* Background Classes */
.bg-gallery-black {
    background-color: var(--bg-primary) !important;
}

.bg-gallery-white {
    background-color: var(--card-bg-light) !important;
}

.bg-gallery-gray {
    background-color: var(--card-bg) !important;
}

.bg-sensual {
    background-color: var(--accent-color) !important;
}

/* Button Styles */
.btn-primary {
    background: var(--accent-color);
    color: white !important;
    padding: 1rem 2rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    display: inline-block;
    font-weight: 500;
    transition: all var(--transition-fast);
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Scrollbar Styling - Only for body, not hero section */
body::-webkit-scrollbar {
    width: 6px;
}

body::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

body::-webkit-scrollbar-thumb {
    background: var(--accent-color);
    border-radius: 3px;
}

body::-webkit-scrollbar-thumb:hover {
    background: var(--accent-hover);
}

/* Hide scrollbars in hero section */
.hero-section::-webkit-scrollbar {
    display: none;
}

.hero-section {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Smooth Scroll */
html {
    scroll-behavior: smooth;
}

/* Performance Optimizations */
img {
    max-width: 100%;
    height: auto;
}

/* Loading Animation */
.loading {
    position: fixed;
    inset: 0;
    background: var(--bg-primary);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s ease;
}

.loading.fade-out {
    opacity: 0;
    pointer-events: none;
}

.spinner {
    width: 32px;
    height: 32px;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Milena Ferencevic Name Styling - Global Red Accent */
.artist-name, 
*:contains("Milena Ferencevic"),
*:contains("Milena Ferenčević") {
    color: #DC143C !important;
}

/* Special styling for hero title with artist name */
.hero-title:contains("Milena"),
h1:contains("Milena"),
h2:contains("Milena"),
h3:contains("Milena") {
    background: linear-gradient(135deg, #DC143C 0%, #FF6B6B 50%, #DC143C 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(220, 20, 60, 0.3);
}

/* Fallback for browsers that don't support :contains() */
.milena-name {
    color: #DC143C !important;
    font-weight: 600;
    position: relative;
}

.milena-name::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, #DC143C, transparent);
    opacity: 0.5;
}

/* Enhanced Mobile Responsive Design */
@media (max-width: 768px) {
    :root {
        --container-padding: 1rem;
        --section-padding: 2rem 0;
        --card-padding: 1.5rem;
    }
    
    /* Typography adjustments for mobile */
    .hero-title {
        font-size: 2.5rem !important;
        line-height: 1.2 !important;
        margin-bottom: 1rem !important;
    }
    
    .hero-subtitle {
        font-size: 1.125rem !important;
        line-height: 1.4 !important;
        margin-bottom: 2rem !important;
    }
    
    /* General text improvements for mobile */
    h1 { font-size: 2rem !important; line-height: 1.2 !important; }
    h2 { font-size: 1.75rem !important; line-height: 1.3 !important; }
    h3 { font-size: 1.5rem !important; line-height: 1.3 !important; }
    h4 { font-size: 1.25rem !important; line-height: 1.4 !important; }
    
    p, li { 
        font-size: 1rem !important; 
        line-height: 1.6 !important; 
        margin-bottom: 1rem !important;
    }
    
    /* Touch targets and button improvements */
    button, a, .btn {
        min-height: 44px !important;
        touch-action: manipulation !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0.75rem 1.5rem !important;
    }
    
    /* Form improvements for mobile */
    input, textarea, select {
        font-size: 16px !important; /* Prevents zoom on iOS */
        min-height: 44px !important;
        padding: 0.75rem 1rem !important;
        border-radius: 8px !important;
        touch-action: manipulation !important;
    }
    
    /* Container and spacing adjustments */
    .container, .max-w-7xl, .max-w-6xl, .max-w-5xl {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
        margin: 0 auto !important;
    }
    
    /* Grid and layout adjustments */
    .grid {
        grid-template-columns: 1fr !important;
        gap: 1.5rem !important;
    }
    
    .flex {
        flex-direction: column !important;
        gap: 1rem !important;
    }
    
    /* Card and content improvements */
    .card, .bg-white, .bg-gray-100 {
        padding: var(--card-padding) !important;
        margin-bottom: 1.5rem !important;
        border-radius: var(--border-radius-lg) !important;
    }
    
    /* Image responsiveness */
    img {
        max-width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    
    /* Navigation improvements */
    .nav-links {
        display: none !important;
    }
    
    /* Table responsiveness */
    table {
        display: block !important;
        overflow-x: auto !important;
        white-space: nowrap !important;
    }
    
    /* Modal and overlay improvements */
    .modal, .lightbox {
        padding: 1rem !important;
    }
    
    .modal-content, .lightbox-content {
        max-width: 95vw !important;
        max-height: 90vh !important;
        margin: 0 auto !important;
    }
}

/* Additional mobile optimizations for smaller screens */
@media (max-width: 480px) {
    :root {
        --container-padding: 0.75rem;
        --section-padding: 1.5rem 0;
        --card-padding: 1rem;
    }
    
    .hero-title {
        font-size: 2rem !important;
    }
    
    .hero-subtitle {
        font-size: 1rem !important;
    }
    
    h1 { font-size: 1.75rem !important; }
    h2 { font-size: 1.5rem !important; }
    h3 { font-size: 1.25rem !important; }
    
    button, a, .btn {
        padding: 0.625rem 1.25rem !important;
        font-size: 0.95rem !important;
    }
    
    input, textarea, select {
        padding: 0.625rem 0.875rem !important;
    }
}

/* Admin indicator mobile optimization */
#adminIndicator {
    position: fixed !important;
    top: 10px !important;
    right: 10px !important;
    z-index: 9999 !important;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    padding: 8px 16px !important;
    border-radius: 20px !important;
    font-size: 12px !important;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3) !important;
    transition: all 0.3s ease !important;
    white-space: nowrap !important;
}

@media (max-width: 767px) {
    #adminIndicator {
        top: 90px !important;
        right: 10px !important;
        font-size: 11px !important;
        padding: 6px 12px !important;
        z-index: 998 !important;
    }
    
    #adminIndicator button {
        font-size: 9px !important;
        padding: 2px 6px !important;
        margin-left: 6px !important;
        border-radius: 8px !important;
    }
}

@media (max-width: 480px) {
    #adminIndicator {
        top: 90px !important;
        right: 5px !important;
        font-size: 10px !important;
        padding: 5px 10px !important;
    }
    
    #adminIndicator span {
        display: inline-block !important;
        white-space: nowrap !important;
    }
    
    #adminIndicator button {
        font-size: 8px !important;
        padding: 1px 4px !important;
        margin-left: 4px !important;
    }
}

/* Enhanced Footer Mobile Styles */
footer {
    width: 100% !important;
    overflow-x: hidden !important;
    position: relative !important;
}

footer .container {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
    max-width: 100% !important;
    text-align: center !important;
}

/* Base footer styles */
footer h3 {
    font-size: 1.25rem !important;
    margin-bottom: 1rem !important;
    font-weight: 700 !important;
}

footer .space-x-6,
footer .flex.justify-center {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 1.5rem !important;
    margin-bottom: 1.5rem !important;
}

footer svg {
    width: 1.25rem !important;
    height: 1.25rem !important;
    min-width: 1.25rem !important;
    min-height: 1.25rem !important;
    flex-shrink: 0 !important;
}

/* Tablet and mobile */
@media (max-width: 768px) {
    footer {
        padding: 2.5rem 0 1.5rem !important;
    }
    
    footer .container {
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
        max-width: 100% !important;
    }
    
    footer h3 {
        font-size: 1.25rem !important;
        margin-bottom: 0.75rem !important;
        color: #ffffff !important;
        text-align: center !important;
    }
    
    /* Divider line */
    footer .w-16 {
        width: 4rem !important;
        height: 2px !important;
        margin: 0 auto 2rem !important;
        background: #CD5C5C !important;
    }
    
    /* Social media icons - Force horizontal layout */
    footer .flex.justify-center {
        display: flex !important;
        flex-direction: row !important;
        gap: 2.5rem !important;
        margin-bottom: 2rem !important;
        justify-content: center !important;
        align-items: center !important;
        flex-wrap: nowrap !important;
    }
    
    footer .flex.justify-center a {
        padding: 0.75rem !important;
        border-radius: 12px !important;
        background: rgba(255, 255, 255, 0.08) !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        min-width: 48px !important;
        min-height: 48px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        touch-action: manipulation !important;
        border: 1px solid rgba(255, 255, 255, 0.1) !important;
        transform: translateY(0) !important;
        flex-shrink: 0 !important;
    }
    
    footer .flex.justify-center a:hover,
    footer .flex.justify-center a:active {
        background: rgba(205, 92, 92, 0.15) !important;
        border-color: rgba(205, 92, 92, 0.3) !important;
        transform: translateY(-2px) !important;
        box-shadow: 0 4px 12px rgba(205, 92, 92, 0.2) !important;
    }
    
    footer svg {
        width: 1.5rem !important;
        height: 1.5rem !important;
        color: #ffffff !important;
        transition: color 0.3s ease !important;
    }
    
    /* Contact info - inline layout like desktop - High specificity */
    footer .container .text-xs {
        font-size: 0.875rem !important;
        line-height: 1.6 !important;
        margin-bottom: 1.5rem !important;
        display: block !important;
        text-align: center !important;
        white-space: nowrap !important;
        overflow-x: auto !important;
    }
    
    footer .container .text-xs a {
        display: inline !important;
        color: #cccccc !important;
        text-decoration: none !important;
        transition: color 0.3s ease !important;
        touch-action: manipulation !important;
        padding: 0.5rem !important;
        border-radius: 4px !important;
        margin: 0 !important;
    }
    
    footer .container .text-xs a:hover,
    footer .container .text-xs a:active {
        color: #CD5C5C !important;
    }
    
    /* Show separators - High specificity */
    footer .container .text-xs .mx-2 {
        display: inline !important;
        color: #666666 !important;
        margin: 0 0.5rem !important;
    }
    
    /* Copyright text */
    footer .text-sm {
        font-size: 0.875rem !important;
        line-height: 1.5 !important;
        color: #999999 !important;
        margin-bottom: 0 !important;
        padding-top: 1rem !important;
        border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
        text-align: center !important;
    }
}

/* Small mobile devices */
@media (max-width: 480px) {
    footer {
        padding: 2rem 0 1rem !important;
    }
    
    footer .container {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    footer h3 {
        font-size: 1.125rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    footer .w-16 {
        width: 3rem !important;
        margin-bottom: 1.5rem !important;
    }
    
    footer .flex.justify-center {
        display: flex !important;
        flex-direction: row !important;
        gap: 2rem !important;
        margin-bottom: 1.5rem !important;
        justify-content: center !important;
        align-items: center !important;
        flex-wrap: nowrap !important;
    }
    
    footer .flex.justify-center a {
        min-width: 44px !important;
        min-height: 44px !important;
        padding: 0.625rem !important;
        flex-shrink: 0 !important;
    }
    
    footer .container .text-xs {
        font-size: 0.8rem !important;
        display: block !important;
        text-align: center !important;
        white-space: nowrap !important;
        overflow-x: auto !important;
        padding: 0 1rem !important;
    }
    
    footer .container .text-xs a {
        display: inline !important;
        padding: 0.5rem !important;
        font-size: 0.8rem !important;
        color: #cccccc !important;
        transition: color 0.3s ease !important;
        margin: 0 !important;
    }
    
    footer .container .text-xs .mx-2 {
        display: inline !important;
        color: #666666 !important;
        margin: 0 0.5rem !important;
    }
    
    footer .text-sm {
        font-size: 0.8rem !important;
        padding-top: 0.75rem !important;
    }
}

@media (min-width: 1200px) {
    :root {
        --container-padding: 2rem;
    }
}