/* =============================================
   Modern CSS Stylesheet - Efeon Royal International
   Mobile-First, Responsive Design
   ============================================= */

/* CSS Variables */
:root {
    /* Colors */
    --color-primary: #c01806;
    --color-primary-dark: #a01305;
    --color-secondary: #1a1a1a;
    --color-text: #333333;
    --color-text-light: #666666;
    --color-text-muted: #999999;
    --color-white: #ffffff;
    --color-light: #f8f9fa;
    --color-dark: #111111;
    --color-overlay: rgba(0, 0, 0, 0.6);
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-display: 'Playfair Display', Georgia, serif;
    
    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-full: 50%;
    
    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.2);
    
    /* Container */
    --container-max: 1200px;
    --container-padding: 1.5rem;
}

/* Reset & Base Styles */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-primary);
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-white);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

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

input,
textarea {
    font-family: inherit;
    font-size: inherit;
}

/* Container */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

/* Section Styles */
.section {
    padding: var(--space-3xl) 0;
}

.section-header {
    text-align: center;
    margin-bottom: var(--space-3xl);
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: var(--space-md);
}

.section-divider {
    width: 60px;
    height: 3px;
    background: var(--color-primary);
    margin: 0 auto var(--space-md);
}

.section-subtitle {
    color: var(--color-text-light);
    font-size: 1.1rem;
}

.bg-light {
    background-color: var(--color-light);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: var(--radius-sm);
    transition: all var(--transition-normal);
    cursor: pointer;
    border: 2px solid transparent;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-white);
    border-color: var(--color-primary);
}

.btn-primary:hover {
    background-color: var(--color-primary-dark);
    border-color: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-full {
    width: 100%;
}

/* Loader */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-white);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    transition: opacity var(--transition-slow), visibility var(--transition-slow);
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid var(--color-light);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Header & Navigation */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: transparent;
    transition: all var(--transition-normal);
}

.header.scrolled {
    background: var(--color-white);
    box-shadow: var(--shadow-sm);
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.nav-logo img {
    height: 50px;
    width: auto;
}

.header.scrolled .nav-logo img {
    height: 40px;
}

.nav-menu {
    display: flex;
    gap: var(--space-xl);
}

.nav-link {
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--color-white);
    position: relative;
    transition: color var(--transition-normal);
}

.header.scrolled .nav-link {
    color: var(--color-secondary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-primary);
    transition: width var(--transition-normal);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 5px;
}

.nav-toggle span {
    width: 25px;
    height: 2px;
    background: var(--color-white);
    transition: all var(--transition-normal);
}

.header.scrolled .nav-toggle span {
    background: var(--color-secondary);
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition-slow), visibility var(--transition-slow);
}

.hero-slide.active {
    opacity: 1;
    visibility: visible;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-overlay);
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: var(--color-white);
    padding: 0 var(--container-padding);
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 6vw, 4rem);
    font-weight: 700;
    margin-bottom: var(--space-md);
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease 0.3s forwards;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    margin-bottom: var(--space-xl);
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease 0.5s forwards;
}

.hero-content .btn {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease 0.7s forwards;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-controls {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: var(--space-md);
    z-index: 2;
}

.hero-arrow {
    width: 50px;
    height: 50px;
    border: 2px solid var(--color-white);
    border-radius: 50%;
    color: var(--color-white);
    font-size: 1.2rem;
    transition: all var(--transition-normal);
}

.hero-arrow:hover {
    background: var(--color-white);
    color: var(--color-secondary);
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--color-white);
    z-index: 2;
    animation: bounce 2s infinite;
}

.scroll-mouse {
    width: 26px;
    height: 40px;
    border: 2px solid var(--color-white);
    border-radius: 20px;
    position: relative;
}

.scroll-mouse::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: var(--color-white);
    border-radius: 2px;
    animation: scrollWheel 2s infinite;
}

.scroll-text {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: var(--space-sm);
}

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

@keyframes scrollWheel {
    0%, 100% { opacity: 1; transform: translateX(-50%) translateY(0); }
    50% { opacity: 0.5; transform: translateX(-50%) translateY(10px); }
}

/* About Section */
.about-content {
    display: grid;
    gap: var(--space-2xl);
}

.about-text .lead {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--color-secondary);
    margin-bottom: var(--space-lg);
}

.about-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-lg);
}

.about-card {
    background: var(--color-white);
    padding: var(--space-xl);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
    text-align: justify;
}

.about-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.about-card-icon {
    width: 60px;
    height: 60px;
    background: var(--color-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-lg);
}

.about-card-icon i {
    font-size: 1.5rem;
    color: var(--color-white);
}

.about-card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: var(--space-md);
}

.about-card p {
    color: var(--color-text-light);
}

.objectives-list {
    padding-left: var(--space-lg);
}

.objectives-list li {
    position: relative;
    margin-bottom: var(--space-sm);
    color: var(--color-text-light);
}

.objectives-list li::before {
    content: '✓';
    position: absolute;
    left: -20px;
    color: var(--color-primary);
}

/* Team Section */
.team-section {
    margin-top: var(--space-3xl);
    padding-top: var(--space-2xl);
    border-top: 1px solid #eee;
}

.team-title {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: var(--space-xl);
}

.team-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
}

.team-tab {
    padding: var(--space-md) var(--space-lg);
    background: var(--color-light);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-text);
    transition: all var(--transition-normal);
}

.team-tab:hover,
.team-tab.active {
    background: var(--color-primary);
    color: var(--color-white);
}

.team-content {
    max-width: 900px;
    margin: 0 auto;
}

.team-panel {
    display: none;
    text-align: center;
    padding: var(--space-xl);
    background: var(--color-light);
    border-radius: var(--radius-md);
}

.team-panel.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

.team-panel p {
    color: var(--color-text-light);
    margin-bottom: var(--space-md);
}

.team-panel p:last-child {
    margin-bottom: 0;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Portfolio Section */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: var(--space-lg);
}

/* Grouped Portfolio Item */
.portfolio-group-item {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-md);
    aspect-ratio: 4/3;
    cursor: pointer;
}

.portfolio-group-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/logo-footer.png') center center no-repeat;
    background-size: 40% auto;
    opacity: 0.6;
    pointer-events: none;
    z-index: 1;
    transition: opacity var(--transition-normal);
}

.portfolio-group-item:hover::after {
    opacity: 0.8;
}

.group-preview {
    position: relative;
    width: 100%;
    height: 100%;
}

.group-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
    position: relative;
    z-index: 0;
}

.portfolio-group-item:hover .group-preview img {
    transform: scale(1.1);
}

/* Group Count Badge */
.group-count-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--color-primary);
    color: var(--color-white);
    padding: 6px 12px;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 2;
    box-shadow: var(--shadow-md);
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-md);
    aspect-ratio: 4/3;
}

.portfolio-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/logo-footer.png') center center no-repeat;
    background-size: 40% auto;
    opacity: 0.6;
    pointer-events: none;
    z-index: 1;
    transition: opacity var(--transition-normal);
}

.portfolio-item:hover::after {
    opacity: 0.8;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
    position: relative;
    z-index: 0;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-info {
    text-align: center;
    color: var(--color-white);
    transform: translateY(20px);
    transition: transform var(--transition-normal);
}

.portfolio-item:hover .portfolio-info {
    transform: translateY(0);
}

.portfolio-info h4 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--space-xs);
}

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition-normal), visibility var(--transition-normal);
}

.lightbox.active {
    opacity: 1;
    visibility: visible;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Lightbox Image Container */
.lightbox-image-container {
    position: relative;
    display: inline-block;
}

.lightbox-image-container img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: var(--radius-md);
    transition: opacity 0.3s ease;
}

/* Lightbox Watermark */
.lightbox-watermark {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0.7;
    pointer-events: none;
    z-index: 10;
}

.lightbox-watermark img {
    width: 120px;
    height: auto;
    filter: brightness(0) invert(1);
}

/* Lightbox Loading Spinner */
.lightbox-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 5;
    display: none;
}

.lightbox-loading.active {
    display: block;
}

.lightbox-loading .spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.lightbox-close {
    position: absolute;
    top: -50px;
    right: 0;
    font-size: 2rem;
    color: var(--color-white);
    transition: color var(--transition-fast);
}

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

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2rem;
    color: var(--color-white);
    padding: var(--space-md);
    transition: color var(--transition-fast), transform var(--transition-fast);
}

.lightbox-prev:hover,
.lightbox-next:hover {
    color: var(--color-primary);
    transform: translateY(-50%) scale(1.2);
}

.lightbox-prev {
    left: -80px;
}

.lightbox-next {
    right: -80px;
}

.lightbox-info {
    text-align: center;
    margin-top: var(--space-lg);
    color: var(--color-white);
}

.lightbox-info h4 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--space-xs);
}

.lightbox-info span {
    font-size: 0.9rem;
    opacity: 0.7;
}

/* Contact Section */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-lg);
}

.contact-card {
    display: flex;
    align-items: flex-start;
    gap: var(--space-lg);
    padding: var(--space-lg);
    background: var(--color-light);
    border-radius: var(--radius-md);
    transition: transform var(--transition-normal);
}

.contact-card:hover {
    transform: translateY(-3px);
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: var(--color-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.contact-icon i {
    font-size: 1.2rem;
    color: var(--color-white);
}

.contact-details h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: var(--space-xs);
}

.contact-details p,
.contact-details a {
    font-size: 0.9rem;
    color: var(--color-text-light);
    transition: color var(--transition-fast);
}

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

/* Contact Form */
.contact-form {
    background: var(--color-light);
    padding: var(--space-xl);
    border-radius: var(--radius-md);
}

.form-group {
    margin-bottom: var(--space-lg);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: var(--space-md) var(--space-lg);
    border: 2px solid #e0e0e0;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    transition: border-color var(--transition-normal);
    background: var(--color-white);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
}

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

/* Footer */
.footer {
    background: var(--color-secondary);
    color: var(--color-white);
    padding: var(--space-2xl) 0;
    position: relative;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-lg);
    text-align: center;
}

.footer-logo img {
    height: 40px;
    width: auto;
}

.footer-text {
    font-size: 0.9rem;
    opacity: 0.8;
}

.back-to-top {
    position: absolute;
    top: -25px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--color-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    font-size: 1.2rem;
    transition: all var(--transition-normal);
    opacity: 0;
    visibility: hidden;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--color-primary-dark);
    transform: translateY(-3px);
}

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

/* Tablet */
@media (max-width: 768px) {
    :root {
        --container-padding: 1rem;
    }
    
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--color-white);
        flex-direction: column;
        padding: 100px var(--space-xl) var(--space-xl);
        gap: var(--space-lg);
        box-shadow: var(--shadow-lg);
        transition: right var(--transition-normal);
    }
    
    .nav-menu.active {
        right: 0;
    }
    
    .nav-link {
        color: var(--color-secondary);
        font-size: 1rem;
    }
    
    .nav-toggle {
        display: flex;
        z-index: 1001;
    }
    
    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    
    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }
    
    .header.scrolled .nav-toggle span {
        background: var(--color-secondary);
    }
    
    .hero-controls {
        bottom: 80px;
    }
    
    .section {
        padding: var(--space-2xl) 0;
    }
    
    .about-cards {
        grid-template-columns: 1fr;
    }
    
    .contact-info {
        grid-template-columns: 1fr;
    }
    
    .portfolio-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    .lightbox-prev {
        left: -50px;
        font-size: 1.5rem;
    }
    
    .lightbox-next {
        right: -50px;
        font-size: 1.5rem;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.85rem;
    }
    
    .team-tabs {
        flex-direction: column;
        align-items: stretch;
    }
    
    .team-tab {
        text-align: center;
    }
    
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .back-to-top {
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .lightbox-close {
        top: -40px;
        font-size: 1.5rem;
    }
    
    .lightbox-prev,
    .lightbox-next {
        padding: var(--space-sm);
        font-size: 1.2rem;
    }
    
    .lightbox-prev {
        left: 0;
    }
    
    .lightbox-next {
        right: 0;
    }
}

/* Large Screens */
@media (min-width: 1200px) {
    .container {
        padding: 0 2rem;
    }
}

/* Print Styles */
@media print {
    .header,
    .hero-controls,
    .scroll-indicator,
    .back-to-top,
    .contact-form {
        display: none !important;
    }
    
    .hero {
        height: auto;
        min-height: auto;
        padding: var(--space-xl) 0;
    }
    
    .section {
        padding: var(--space-xl) 0;
    }
}
