/* ===================================
   DekoStavby - Строительная компания
   Главный файл стилей
   =================================== */

/* CSS Variables */
:root {
    --black: #0a0a0a;
    --black-light: #1a1a1a;
    --white: #fafafa;
    --white-dim: #e8e8e8;
    --gold: #c9a54e;
    --gold-light: #dfc06a;
    --gold-dark: #a88a3d;
}

/* ===================================
   Base Styles
   =================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--black);
    color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4 {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
}

/* ===================================
   Navigation
   =================================== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1.5rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s ease, padding 0.3s ease;
}

.nav.scrolled {
    background-color: rgba(10, 10, 10, 0.95);
    padding: 1rem 5%;
    backdrop-filter: blur(10px);
}

.logo {
    text-decoration: none;
    display: flex;
    align-items: center;
}

.logo img {
    height: 55px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-links a {
    color: var(--white);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
    position: relative;
    transition: color 0.3s ease;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--gold);
    transition: width 0.3s ease;
}

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

.nav-links a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle span {
    width: 25px;
    height: 2px;
    background: var(--white);
    transition: 0.3s;
}

/* ===================================
   Hero Section
   =================================== */
.hero {
    min-height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: linear-gradient(135deg, var(--black) 0%, var(--black-light) 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(201, 165, 78, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(201, 165, 78, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.hero-container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 5%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-badge {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    border: 1px solid var(--gold);
    color: var(--gold);
    font-size: 0.75rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 2rem;
    animation: fadeInUp 0.8s ease;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-title .highlight {
    color: var(--gold);
    font-style: italic;
}

.hero-description {
    font-size: 1.1rem;
    color: var(--white-dim);
    margin-bottom: 2.5rem;
    max-width: 500px;
    font-weight: 300;
    animation: fadeInUp 0.8s ease 0.4s both;
}

.hero-cta {
    display: flex;
    gap: 1.5rem;
    animation: fadeInUp 0.8s ease 0.6s both;
}

/* ===================================
   Buttons
   =================================== */
.btn {
    padding: 1rem 2.5rem;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-family: 'Montserrat', sans-serif;
}

.btn-primary {
    background: var(--gold);
    color: var(--black);
}

.btn-primary:hover {
    background: var(--gold-light);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(201, 165, 78, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--white);
    border: 1px solid var(--white);
}

.btn-secondary:hover {
    background: var(--white);
    color: var(--black);
}

/* ===================================
   Slider
   =================================== */
.hero-slider {
    position: relative;
    height: 500px;
    animation: fadeIn 1s ease 0.5s both;
}

.slider-container {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s ease;
    transform: scale(1.05);
}

.slide.active {
    opacity: 1;
    transform: scale(1);
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    background: linear-gradient(to top, rgba(10, 10, 10, 0.9), transparent);
}

.slide-title {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.slide-location {
    font-size: 0.85rem;
    color: var(--gold);
}

.slider-nav {
    position: absolute;
    bottom: -3rem;
    left: 0;
    display: flex;
    gap: 1rem;
}

.slider-btn {
    width: 50px;
    height: 50px;
    border: 1px solid var(--white);
    background: transparent;
    color: var(--white);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider-btn:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: var(--black);
}

.slider-counter {
    position: absolute;
    bottom: -2.5rem;
    right: 0;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
}

.slider-counter .current {
    font-size: 2rem;
    color: var(--gold);
}

/* ===================================
   Section Styles
   =================================== */
section {
    padding: 8rem 5%;
}

.section-header {
    text-align: center;
    margin-bottom: 5rem;
}

.section-label {
    display: inline-block;
    color: var(--gold);
    font-size: 0.8rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3.5rem);
    margin-bottom: 1.5rem;
}

.section-divider {
    width: 60px;
    height: 2px;
    background: var(--gold);
    margin: 0 auto;
}

/* ===================================
   Services Section
   =================================== */
.services {
    background: var(--white);
    color: var(--black);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.service-card {
    padding: 3rem 2rem;
    background: var(--white);
    border: 1px solid #e0e0e0;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--gold);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-icon {
    width: 60px;
    height: 60px;
    margin-bottom: 1.5rem;
    color: var(--gold);
    stroke-width: 1.5;
}

.service-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--black);
}

.service-description {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.8;
}

/* ===================================
   Experience Section
   =================================== */
.experience {
    background: linear-gradient(135deg, var(--black-light) 0%, var(--black) 100%);
    position: relative;
}

.experience::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23c9a54e' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.experience-content {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 5rem;
}

.stat-item {
    text-align: center;
    padding: 2rem;
    border: 1px solid rgba(201, 165, 78, 0.2);
    transition: all 0.3s ease;
}

.stat-item:hover {
    border-color: var(--gold);
    background: rgba(201, 165, 78, 0.05);
}

.stat-number {
    font-family: 'Cormorant Garamond', serif;
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--gold);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--white-dim);
}

/* ===================================
   Portfolio Grid
   =================================== */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.portfolio-item {
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
    cursor: pointer;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

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

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 10, 10, 0.8);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.4s ease;
}

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

.portfolio-category {
    color: var(--gold);
    font-size: 0.75rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.portfolio-title {
    font-size: 1.3rem;
}

/* ===================================
   Team Section
   =================================== */
.team {
    background: var(--white);
    color: var(--black);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.team-card {
    text-align: center;
}

.team-photo {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto 1.5rem;
    overflow: hidden;
}

.team-photo::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border: 2px solid var(--gold);
    z-index: 1;
    transition: transform 0.4s ease;
}

.team-card:hover .team-photo::before {
    transform: rotate(5deg);
}

.team-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.4s ease;
}

.team-card:hover .team-photo img {
    filter: grayscale(0%);
}

.team-name {
    font-size: 1.4rem;
    margin-bottom: 0.3rem;
    color: var(--black);
}

.team-role {
    color: var(--gold);
    font-size: 0.85rem;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

.team-bio {
    color: #666;
    font-size: 0.9rem;
    max-width: 280px;
    margin: 0 auto;
}

/* ===================================
   Contact Section
   =================================== */
.contact {
    background: var(--black);
    position: relative;
}

.contact::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(45deg, transparent 45%, rgba(201, 165, 78, 0.03) 50%, transparent 55%),
        linear-gradient(-45deg, transparent 45%, rgba(201, 165, 78, 0.03) 50%, transparent 55%);
    background-size: 30px 30px;
}

.contact-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    position: relative;
    z-index: 1;
}

/* ===================================
   Contact Form
   =================================== */
.contact-form {
    background: var(--black-light);
    padding: 3rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.form-title {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.form-subtitle {
    color: var(--white-dim);
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 1rem;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--white);
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

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

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

.form-group select option {
    background: var(--black);
}

.form-submit {
    width: 100%;
    padding: 1.2rem;
    background: var(--gold);
    color: var(--black);
    border: none;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
}

.form-submit:hover {
    background: var(--gold-light);
    transform: translateY(-2px);
}

/* ===================================
   Contact Info
   =================================== */
.contact-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.contact-info-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-item:last-of-type {
    border-bottom: none;
}

.contact-icon {
    width: 50px;
    height: 50px;
    border: 1px solid var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gold);
    flex-shrink: 0;
}

.contact-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--gold);
    margin-bottom: 0.5rem;
}

.contact-value {
    font-size: 1.1rem;
    color: var(--white);
}

.contact-value a {
    color: var(--white);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

/* ===================================
   Social Links
   =================================== */
.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.social-link {
    width: 45px;
    height: 45px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: var(--black);
}

/* ===================================
   Footer
   =================================== */
.footer {
    background: var(--black-light);
    padding: 3rem 5%;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-logo {
    margin-bottom: 1rem;
}

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

.footer-text {
    color: #666;
    font-size: 0.85rem;
}

/* ===================================
   Animations
   =================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Scroll animations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* ===================================
   Responsive Design
   =================================== */

/* Tablet */
@media (max-width: 1024px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-description {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-slider {
        height: 400px;
        margin-top: 3rem;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-container {
        grid-template-columns: 1fr;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: var(--black);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        transform: translateX(100%);
        transition: transform 0.3s ease;
    }

    .nav-links.active {
        transform: translateX(0);
    }

    .nav-links a {
        font-size: 1.2rem;
    }

    .menu-toggle {
        display: flex;
    }

    .menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    .hero-slider {
        height: 300px;
    }

    .slider-nav {
        bottom: -2.5rem;
    }

    .slider-btn {
        width: 40px;
        height: 40px;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }

    .stat-number {
        font-size: 2.5rem;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    section {
        padding: 5rem 5%;
    }

    .contact-form {
        padding: 2rem;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .hero-cta {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .team-grid {
        grid-template-columns: 1fr;
    }
}

/* ===================================
   Portfolio Modal
   =================================== */
.portfolio-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.portfolio-modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    cursor: pointer;
}

.modal-content {
    position: relative;
    width: 90%;
    max-width: 1000px;
    max-height: 90vh;
    z-index: 2001;
    transform: scale(0.9);
    transition: transform 0.4s ease;
}

.portfolio-modal.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: -50px;
    right: 0;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 1px solid var(--white);
    color: var(--white);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 2002;
}

.modal-close:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: var(--black);
}

.modal-slider {
    position: relative;
    width: 100%;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: var(--black-light);
}

.modal-slides {
    width: 100%;
    height: 100%;
    position: relative;
}

.modal-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.modal-slide.active {
    opacity: 1;
}

.modal-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--white);
    color: var(--white);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.modal-nav:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: var(--black);
}

.modal-prev {
    left: 1rem;
}

.modal-next {
    right: 1rem;
}

.modal-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-title {
    font-size: 1.5rem;
    color: var(--white);
}

.modal-counter {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
    color: var(--white-dim);
}

.modal-counter .modal-current {
    font-size: 1.8rem;
    color: var(--gold);
}

/* Modal Responsive */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
    }

    .modal-close {
        top: -45px;
        width: 35px;
        height: 35px;
    }

    .modal-nav {
        width: 40px;
        height: 40px;
    }

    .modal-prev {
        left: 0.5rem;
    }

    .modal-next {
        right: 0.5rem;
    }

    .modal-title {
        font-size: 1.2rem;
    }

    .modal-info {
        padding: 1rem 0;
    }
}

