@font-face {
    font-family: 'Playfair Display';
    src: url('../fonts/PlayfairDisplay-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Inter';
    src: url('../fonts/Inter-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Inter';
    src: url('../fonts/Inter-Light.woff2') format('woff2');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

:root {
    --bg-color: #050505;
    --surface-color: rgba(20, 20, 20, 0.6);
    --surface-blur: blur(20px);
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --gold: #C8A86A;
    --gold-hover: #e0c285;
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
    --transition-smooth: 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

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

html {
    /* removed scroll-behavior: smooth to fix mouse wheel jumping */
}

html, body {
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    overflow-x: hidden;
}

::-webkit-scrollbar {
    width: 0px !important;
    background: transparent !important;
    display: none !important;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-weight: 300;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 400;
    line-height: 1.2;
}

a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color var(--transition-smooth);
}

a:hover {
    color: var(--gold);
}

/* Glassmorphism Utilities */
.glass {
    background: var(--surface-color);
    backdrop-filter: var(--surface-blur);
    -webkit-backdrop-filter: var(--surface-blur);
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Typography */
.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    opacity: 0;
    transform: translateY(-100%);
    transition: padding 0.3s ease, background 0.3s ease, opacity 0.4s ease, transform 0.4s ease;
}

nav.scrolled {
    padding: 1rem 2rem;
    background: rgba(5, 5, 5, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    opacity: 1;
    transform: translateY(0);
}

nav .logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    letter-spacing: 2px;
}

nav .links a {
    margin-left: 2rem;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

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

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center center;
    background-color: #050505;
    z-index: -2;
    transform: scale(1.05);
    transition: transform 10s ease-out;
}

.hero.loaded .hero-bg {
    transform: scale(1);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, #050505 0%, transparent 25%, transparent 75%, #050505 100%), linear-gradient(to bottom, rgba(5,5,5,0.3) 0%, rgba(5,5,5,1) 100%);
    z-index: -1;
}

.hero h1 {
    font-size: 5rem;
    letter-spacing: 5px;
    text-align: center;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 1.5s forwards 0.5s;
}

.hero p {
    font-size: 1.2rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--gold);
    margin-top: 1rem;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 1.5s forwards 0.8s;
}

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

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    animation: fadeUp 1.5s forwards 1.2s;
}

.scroll-indicator::after {
    content: '';
    display: block;
    width: 1px;
    height: 50px;
    background: var(--gold);
    margin: 10px auto 0;
    animation: pulseScroll 2s infinite;
}

@keyframes pulseScroll {
    0% { transform: scaleY(0); transform-origin: top; }
    50% { transform: scaleY(1); transform-origin: top; }
    50.1% { transform: scaleY(1); transform-origin: bottom; }
    100% { transform: scaleY(0); transform-origin: bottom; }
}

/* Sections General */
section {
    padding: 8rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
    scroll-margin-top: 100px;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

/* Portfolio Masonry */
.portfolio-filters {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.portfolio-filters button {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    transition: color 0.3s;
}

.portfolio-filters button.active, .portfolio-filters button:hover {
    color: var(--gold);
}

.masonry {
    column-count: 3;
    column-gap: 20px;
}

.masonry-item {
    break-inside: avoid;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
    cursor: zoom-in;
    border-radius: 4px;
}

.masonry-item img {
    width: 100%;
    display: block;
    transition: transform var(--transition-smooth);
}

.masonry-item:hover img {
    transform: scale(1.03);
}

.masonry-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    opacity: 0;
    transition: opacity var(--transition-smooth);
}

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

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s;
}

.lightbox.active {
    opacity: 1;
    pointer-events: all;
}

.lightbox img {
    max-height: 90vh;
    max-width: 90vw;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 1rem;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    font-family: var(--font-body);
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
}

.contact-form input:focus, .contact-form textarea:focus {
    border-color: var(--gold);
}

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

.btn {
    padding: 1rem 2.5rem;
    background: transparent;
    color: #fff;
    border: 1px solid var(--gold);
    font-family: var(--font-body);
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.3s;
    align-self: flex-start;
    white-space: nowrap;
    text-align: center;
}

.btn:hover {
    background: var(--gold);
    color: #000;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    margin-top: 2rem;
}

.social-card {
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
    flex: 1;
    transition: transform 0.3s;
}

.social-card:hover {
    transform: translateY(-5px);
}

/* Footer */
footer {
    padding: 4rem 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.footer-links {
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
    gap: 2rem;
}

/* Back to Top Button */
#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    background: transparent;
    backdrop-filter: blur(5px);
    border: 1px solid var(--gold);
    color: var(--gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
}

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

#back-to-top:hover {
    background: rgba(200, 168, 106, 0.1);
    color: var(--gold);
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(200, 168, 106, 0.2);
}

/* Legal Modal */
.legal-modal {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s;
    backdrop-filter: blur(5px);
}

.legal-modal.active {
    opacity: 1;
    pointer-events: all;
}

.legal-modal-content {
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
    padding: 3rem;
    position: relative;
    border-radius: 8px;
    scrollbar-width: thin;
    scrollbar-color: var(--gold) transparent;
}

.legal-modal-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 2.5rem;
    color: var(--gold);
    cursor: pointer;
    line-height: 1;
}

/* CMS Edit Mode Styles */
.cms-edit-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--gold);
    color: #000;
    border: none;
    padding: 5px 10px;
    font-size: 0.75rem;
    cursor: pointer;
    z-index: 100;
    opacity: 0;
    transition: opacity 0.3s;
}

.editable-wrapper {
    position: relative;
}

.editable-wrapper:hover .cms-edit-btn {
    opacity: 1;
}

.cms-toolbar {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    padding: 15px;
    border-radius: 8px;
    display: flex;
    gap: 2rem;
}

.hamburger {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    .masonry { column-count: 2; }
    .about-grid, .contact-grid { grid-template-columns: 1fr; }
    .hero h1 { font-size: 3rem; }
}

@media (max-width: 480px) {
    .masonry { column-count: 1; }
    
    .section-title { font-size: 1.8rem; }
    
    .hamburger { display: block; }
    
    nav .links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(0,0,0,0.95);
        padding: 1rem;
        text-align: center;
        border-bottom: 1px solid var(--gold);
    }
    
    nav .links.active {
        display: flex;
    }

    .btn {
        padding: 0.8rem 1.2rem;
        letter-spacing: 1px;
        font-size: 0.9rem;
    }
}
