/* --- Typography & Resets --- */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --text-primary: #1a1a1a;
    --text-secondary: #4a4a4a;
    --glass-bg: rgba(255, 255, 255, 0.45);
    --glass-border: rgba(212, 175, 55, 0.4);
    --gold: #D4AF37;
    --gold-hover: #b5952f;
    --transition: all 0.3s ease;
    --marble-base: radial-gradient(circle at 50% 50%, #ffffff 0%, #f4f4f4 100%);
    --marble-veins: linear-gradient(135deg, transparent 48%, rgba(212, 175, 55, 0.1) 49%, rgba(212, 175, 55, 0.3) 50%, rgba(212, 175, 55, 0.1) 51%, transparent 52%);
}

[data-theme="dark"] {
    --text-primary: #fdfdfd;
    --text-secondary: #cccccc;
    --glass-bg: rgba(15, 15, 15, 0.6);
    --glass-border: rgba(212, 175, 55, 0.3);
    --marble-base: radial-gradient(circle at 30% 70%, #1a1a1a 0%, #050505 100%);
    --marble-veins: linear-gradient(135deg, transparent 48%, rgba(212, 175, 55, 0.15) 49%, rgba(212, 175, 55, 0.6) 50%, rgba(212, 175, 55, 0.15) 51%, transparent 52%);
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-primary);
    background: var(--marble-veins), var(--marble-base);
    background-size: 200% 200%;
    background-attachment: fixed;
    animation: floatMarble 40s linear infinite;
    min-height: 100vh;
}

@keyframes floatMarble {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

h1, h2, h3, .logo { font-family: 'Cinzel', serif; font-weight: 600; letter-spacing: 1px; }
a { text-decoration: none; color: inherit; transition: var(--transition); }
.gold-text { color: var(--gold); }
.gold-text:hover { color: var(--gold-hover); }

/* --- Glassmorphism --- */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.15);
    transition: background 0.5s ease, border 0.5s ease;
}

/* --- Layout --- */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 4rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

.hero { height: 80vh; display: flex; align-items: center; justify-content: center; text-align: center; padding: 0 2rem; }
.hero-content { max-width: 800px; padding: 4rem; border-radius: 4px; }
.hero h1 { font-size: 3.5rem; margin-bottom: 1.5rem; color: var(--gold); }
.hero p { font-size: 1.2rem; line-height: 1.6; color: var(--text-secondary); margin-bottom: 2.5rem; }

.hero-actions { display: flex; gap: 1.5rem; justify-content: center; }
.btn-solid { background: var(--gold); color: #000; padding: 1rem 2rem; font-weight: 600; font-family: 'Cinzel', serif; transition: var(--transition); }
.btn-solid:hover { background: var(--gold-hover); transform: translateY(-2px); }
.btn-outline { border: 1px solid var(--gold); color: var(--gold); padding: 1rem 2rem; font-family: 'Cinzel', serif; transition: var(--transition); }
.btn-outline:hover { background: var(--gold); color: #000; }

/* About Us Section Fixed */
.about-us { padding: 6rem 4rem; display: flex; justify-content: center; }
.about-container { max-width: 900px; padding: 4rem; border-radius: 4px; text-align: center; }
.section-title { font-size: 2.5rem; margin-bottom: 3rem; color: var(--gold); text-align: center; }
.about-text p { margin-bottom: 1.5rem; line-height: 1.8; color: var(--text-secondary); font-size: 1.1rem; }

/* Portfolio Grid */
.portfolio { padding: 0 4rem 6rem 4rem; }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; }

.card { position: relative; border-radius: 2px; overflow: hidden; aspect-ratio: 4/5; transform: translateZ(0); }
.card-img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1); will-change: transform; }
.card:hover .card-img { transform: scale(1.1); }

.card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.3) 60%, transparent 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.5s ease;
}
.card:hover .card-overlay { opacity: 1; }
.card-overlay h3 { color: var(--gold); font-size: 1.5rem; margin-bottom: 0.5rem; transform: translateY(10px); transition: transform 0.4s ease; }
.card-overlay p { color: #fff; font-size: 0.95rem; line-height: 1.5; transform: translateY(10px); transition: transform 0.4s ease; }
.card:hover h3, .card:hover p { transform: translateY(0); }

/* Footer */
footer { text-align: center; padding: 4rem 2rem; margin: 4rem 4rem 2rem 4rem; border-radius: 4px; }
footer h2 { color: var(--gold); margin-bottom: 1rem; }
footer p { color: var(--text-secondary); margin-bottom: 1.5rem; }
.footer-contacts a { margin: 0 1rem; font-weight: 500; }

.btn-glass {
    background: transparent;
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    width: 45px; height: 45px;
    border-radius: 50%;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: var(--transition);
}

/* Theme Icons */
html:not([data-theme="dark"]) .icon-sun { display: none; }
html:not([data-theme="dark"]) .icon-moon { display: block; }
html[data-theme="dark"] .icon-sun { display: block; }
html[data-theme="dark"] .icon-moon { display: none; }

/* Responsive */
@media (max-width: 1024px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 768px) {
    nav { flex-direction: column; gap: 1rem; padding: 1rem; }
    .grid { grid-template-columns: 1fr; }
    .hero h1 { font-size: 2.5rem; }
    .about-us, .portfolio { padding: 2rem 1.5rem; }
    .about-container, .hero-content { padding: 2rem; }
    .hero-actions { flex-direction: column; }
}

/* --- Логотип та Навігація (Виправлення) --- */
nav .logo {
    font-size: 1.5rem;
    color: var(--gold);
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    color: var(--gold) !important; /* Колір посилань Call Us / Email Us */
}

/* Оптимізація розташування елементів у хедері */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 4rem;
    position: sticky;
    top: 0;
    z-index: 100;
}