/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Cormorant Garamond', 'Garamond', serif;
    line-height: 1.6;
    color: #333;
    background-color: #E8D1A7; /* golden batter */
}


h1, h2, h3, .logo h1, .section-title {
    font-family: 'Cinzel', 'UnifrakturMaguntia', serif;
    letter-spacing: 2px; /* додаємо розрідження */
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== HEADER ===== */
header {
    background-color: #9D9167; /* olive harvest */
    padding: 20px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.logo h1 {
    font-family: 'Cinzel', serif;
    font-size: 2.5rem;
    color: #743014; /* spiced wine */
    text-transform: lowercase;
    letter-spacing: 1px;
}

nav ul {
    display: flex;
    list-style: none;
    flex-wrap: wrap;
}

nav ul li {
    margin-left: 30px;
}

nav ul li a {
    text-decoration: none;
    color: #E8D1A7;
    font-weight: 600;
    font-size: 1.1rem;
    transition: color 0.3s;
    padding: 5px 10px;
    border-radius: 3px;
}

nav ul li a:hover,
nav ul li a.active {
    color: #743014;
    background-color: rgba(232, 209, 167, 0.2);
}

/* ===== HERO ===== */
.hero {
    background: linear-gradient(rgba(116,48,20,0.85), rgba(116,48,20,0.9));
    color: #E8D1A7;
    text-align: center;
    padding: 100px 0;
}

.hero-content h2 {
    font-family: 'Cinzel', serif;
    font-size: 3.5rem;
    margin-bottom: 20px;
}

.hero-content p {
    font-size: 1.5rem;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-block;
    background-color: #743014;
    color: #E8D1A7;
    padding: 12px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s;
    border: 2px solid #743014;
    cursor: pointer;
}

.btn:hover {
    background-color: #9D9167;
    border-color: #9D9167;
    color: #E8D1A7;
}

/* ===== SECTION TITLES ===== */
.section-title {
    font-family: 'Cinzel', serif;
    font-size: 2.5rem;
    color: #743014;
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background-color: #9D9167;
}

.section-subtitle {
    text-align: center;
    color: #743014;
    font-size: 1.2rem;
    margin-bottom: 40px;
}

/* ===== PRICING TABLE ===== */
.pricing {
    padding: 80px 0;
    background-color: #f5f0e4;
}

.pricing-table {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.pricing-category {
    flex: 1;
    min-width: 280px;
    background-color: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
    border-top: 5px solid #9D9167;
}

.pricing-category h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.8rem;
    color: #743014;
    margin-bottom: 20px;
}

.pricing-category ul {
    list-style: none;
}

.pricing-category li {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    font-size: 1.2rem;
    color: #333;
}

.pricing-category li:last-child {
    border-bottom: none;
}

/* ===== TERMS SECTION ===== */
.terms {
    padding: 80px 0;
    background-color: #f5f0e4;
}

.terms-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1000px;
    margin: 0 auto;
}

.terms-list ul,
.terms-dont ul {
    list-style: none;
    padding: 0;
}

.terms-list li {
    margin-bottom: 15px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.terms-list i {
    color: #743014;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.terms-dont h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.8rem;
    color: #743014;
    margin-bottom: 20px;
    border-bottom: 2px solid #9D9167;
    padding-bottom: 10px;
}

.terms-dont ul li {
    margin-bottom: 10px;
    font-size: 1.2rem;
    font-weight: 600;
    color: #743014;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.social-handles {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #9D9167;
}

.social-handles p {
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: #333;
}

.social-handles strong {
    color: #743014;
    font-weight: 700;
}

/* ===== GALLERY (preview & full) ===== */
.preview {
    padding: 80px 0;
}

.preview:nth-child(even) {
    background-color: #f5f0e4;
}

.gallery-preview {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

/* Загальні стилі для контейнерів зображень */
.gallery-item {
    position: relative;
    width: 100%;
    background-color: #9D9167; /* фон під час завантаження */
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    aspect-ratio: 4 / 3; /* однакове співвідношення для всіх */
}

.gallery-preview .gallery-item {
    flex: 1 1 250px; /* дозволяє переноситись на малих екранах */
}

.gallery-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* заповнює контейнер, може трохи обрізати, але зберігає пропорції */
    object-position: center;
    transition: transform 0.3s ease;
    /* Покращення якості */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
    -ms-interpolation-mode: bicubic;
}

/* при наведенні – легке збільшення */
.gallery-item:hover .gallery-image {
    transform: scale(1.03);
}

.view-more, .back-home {
    text-align: center;
    margin-top: 20px;
}

/* ===== FULL GALLERY GRID ===== */
.gallery-full {
    padding: 80px 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

/* ===== ORDER FORM ===== */
.order-form {
    padding: 80px 0;
    background-color: #f5f0e4;
}

form {
    max-width: 800px;
    margin: 0 auto;
    background-color: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #743014;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #9D9167;
    border-radius: 5px;
    font-family: 'Raleway', sans-serif;
    font-size: 1rem;
    background-color: #f9f9f9;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #743014;
    box-shadow: 0 0 5px rgba(116,48,20,0.3);
}

.submit-btn {
    width: 100%;
    padding: 15px;
    font-size: 1.2rem;
}

/* ===== FOOTER ===== */
footer {
    background-color: #743014;
    color: #E8D1A7;
    padding: 40px 0;
    text-align: center;
}

footer p {
    margin-bottom: 10px;
}

.social-icons a {
    color: #E8D1A7;
    font-size: 1.5rem;
    margin: 0 15px;
    transition: color 0.3s;
    display: inline-block;
}

.social-icons a:hover {
    color: #9D9167;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 992px) {
    .gallery-preview {
        flex-direction: column;
    }
    .gallery-preview .gallery-item {
        width: 100%;
        max-width: 500px;
        margin: 0 auto;
    }
    .terms-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 768px) {
    header .container {
        flex-direction: column;
        text-align: center;
    }
    nav ul {
        justify-content: center;
        margin-top: 15px;
    }
    nav ul li {
        margin: 5px 15px;
    }
    .hero-content h2 {
        font-size: 2.5rem;
    }
    .hero-content p {
        font-size: 1.2rem;
    }
    .section-title {
        font-size: 2rem;
    }
    form {
        padding: 25px;
    }
}

/* Стилі для тексту-підказки під полем файлу */
.form-text {
    display: block;
    margin-top: 5px;
    font-size: 0.9rem;
    color: #666;
}

/* Стилізація самого поля файлу (можна за бажанням) */
input[type="file"] {
    padding: 10px;
    background-color: #f9f9f9;
    border: 1px solid #9D9167;
    border-radius: 5px;
    width: 100%;
    cursor: pointer;
}

input[type="file"]::file-selector-button {
    background-color: #743014;
    color: #E8D1A7;
    border: none;
    padding: 8px 16px;
    border-radius: 5px;
    margin-right: 15px;
    cursor: pointer;
    transition: background-color 0.3s;
}

input[type="file"]::file-selector-button:hover {
    background-color: #9D9167;
}

.gallery-item {
    transition: box-shadow 0.3s ease;
}

.gallery-item:hover {
    box-shadow: 0 15px 30px rgba(116, 48, 20, 0.2); /* spiced wine з прозорістю */
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 4px;
    background: linear-gradient(90deg, #E8D1A7, #743014, #9D9167);
    border-radius: 2px;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.08);
}

.gallery-image {
    border: 3px solid #9D9167; /* olive harvest */
    box-sizing: border-box;
}

.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s;
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(232, 209, 167, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.5s, height 0.5s;
}

.btn:hover::after {
    width: 300px;
    height: 300px;
}

.btn:active {
    transform: scale(0.98);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.gallery-item, .pricing-category, .terms-grid {
    animation: fadeInUp 0.8s ease-out forwards;
}

.social-icons a {
    color: #E8D1A7;
    font-size: 1.8rem;
    margin: 0 10px;
    transition: color 0.3s, transform 0.2s;
}

.social-icons a:hover {
    color: #9D9167;
    transform: scale(1.1);
}

.social-handles a {
    color: #743014;
    text-decoration: none;
    border-bottom: 1px dotted #9D9167;
}

.social-handles a:hover {
    color: #9D9167;
    border-bottom-style: solid;
}

/* Modal (Lightbox) */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.9);
    cursor: pointer;
}

.modal-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    animation: zoom 0.3s;
}

@keyframes zoom {
    from {transform: scale(0.9); opacity: 0;}
    to {transform: scale(1); opacity: 1;}
}

.close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
    z-index: 10000;
}

.close:hover,
.close:focus {
    color: #bbb;
    text-decoration: none;
}

#caption {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 700px;
    text-align: center;
    color: #ccc;
    padding: 10px 0;
    height: 150px;
    font-family: 'Raleway', sans-serif;
    font-size: 1rem;
}

/* Адаптивність */
@media (max-width: 768px) {
    .modal-content {
        max-width: 95%;
        max-height: 85%;
    }
    .close {
        top: 15px;
        right: 25px;
        font-size: 30px;
    }
}