/* static/css/khokhloma.css */

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

body {
    background-color: #2c4a3b;
    font-family: 'Georgia', 'Times New Roman', Times, serif;
    color: #2e2b26;
    line-height: 1.6;
    padding: 2rem 1rem;
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
}

#snow-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
    opacity: 0.7;
}

.page {
    max-width: 1200px;
    margin: 0 auto;
    background-color: #fdf7ed;
    box-shadow: 0 25px 45px rgba(30, 40, 20, 0.6);
    border-radius: 60px 60px 40px 40px;
    padding: 2.5rem 2.8rem;
    border: 1px solid #c9ad8d;
    position: relative;
    z-index: 10;
    backdrop-filter: blur(0.5px);
}

.header-strip {
    display: flex;
    gap: 8px;
    margin-bottom: 28px;
    flex-wrap: wrap;
}

.strip-block {
    height: 8px;
    flex: 1 1 70px;
    background-color: #b57e4a;
    border-radius: 30px;
}

.strip-block:nth-child(2) { background-color: #8b6b4b; }
.strip-block:nth-child(3) { background-color: #7a5a3a; }
.strip-block:nth-child(4) { background-color: #c59a6b; }
.strip-block:nth-child(5) { background-color: #a07d56; }

h1 {
    font-size: 3rem;
    font-weight: normal;
    letter-spacing: 1px;
    color: #3e3529;
    border-left: 8px solid #b57e4a;
    padding-left: 1.8rem;
    margin: 0 0 0.8rem 0;
    line-height: 1.2;
}

h1 strong {
    font-weight: 600;
    background: linear-gradient(135deg, #b57e4a 0%, #3d6b4f 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subhead {
    font-style: italic;
    color: #6b5843;
    margin-bottom: 2rem;
    font-size: 1.2rem;
    border-bottom: 2px dashed #cfb79b;
    padding-bottom: 0.7rem;
}

.stat-block {
    display: flex;
    gap: 2.2rem;
    background: #efe1d2;
    padding: 1.2rem 2rem;
    border-radius: 60px;
    border: 1px solid #c9ad8d;
    margin: 1.5rem 0 2rem 0;
    flex-wrap: wrap;
    justify-content: center;
}

.stat-item {
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.stat-item span {
    font-weight: bold;
    background: #7a9a7a;
    color: white;
    padding: 0.3rem 1.4rem;
    border-radius: 40px;
    font-size: 1rem;
}

.hero-img {
    width: 100%;
    max-height: 380px;
    object-fit: cover;
    border-radius: 50px;
    margin: 25px 0 20px;
    border: 4px solid white;
    box-shadow: 0 15px 30px rgba(70, 50, 30, 0.3);
    cursor: pointer;
}

.greeting-card {
    background-color: #efe1d2;
    border-radius: 50px;
    padding: 2rem 2.5rem;
    margin: 2rem 0 2.5rem 0;
    font-size: 1.15rem;
    box-shadow: inset 0 1px 8px rgba(255, 240, 225, 0.8), 0 8px 20px rgba(80, 50, 20, 0.15);
    border: 1px solid #ddc7b2;
}

.greeting-card p {
    margin-bottom: 1rem;
}

.section-title {
    font-size: 2.3rem;
    font-weight: 400;
    border-bottom: 3px solid #b57e4a;
    padding-bottom: 0.5rem;
    margin: 2.8rem 0 1.8rem 0;
    display: inline-block;
    letter-spacing: 0.5px;
    color: #3e3529;
}

.section-subtitle {
    font-size: 1.8rem;
    color: #4d3e2e;
    margin: 2rem 0 1.5rem 0;
    font-weight: 400;
    border-left: 6px solid #b57e4b;
    padding-left: 1.3rem;
}

.crafts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin: 2rem 0 3rem;
}

.craft-card {
    background: #f4e8dc;
    border-radius: 40px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(100, 70, 40, 0.2);
    transition: all 0.3s ease;
    border: 1px solid #dfcab3;
    cursor: pointer;
}

.craft-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 35px rgba(90, 60, 30, 0.3);
}

.craft-image {
    height: 210px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.craft-image::after {
    content: 'Хохлома';
    position: absolute;
    top: 1.2rem;
    right: 1.2rem;
    background: #b57e4a;
    color: white;
    padding: 0.4rem 1.2rem;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.2);
}

.craft-content {
    padding: 1.8rem;
}

.craft-region {
    color: #b57e4a;
    font-size: 1rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.craft-title {
    font-size: 1.5rem;
    margin-bottom: 0.8rem;
    color: #2e2b26;
    font-weight: 600;
}

.craft-description {
    color: #5a4c3c;
    margin-bottom: 1.2rem;
    line-height: 1.5;
    font-size: 1rem;
}

.craft-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1.2rem;
    border-top: 2px solid #d9bc9c;
}

.craft-price {
    font-size: 1.3rem;
    font-weight: bold;
    color: #7a5a3a;
}

.craft-duration {
    color: #7a9a7a;
    font-size: 1rem;
    font-weight: 500;
}

.craft-duration::before {
    content: '⏱ ';
}

.color-symbol {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 1.8rem;
    margin: 1.5rem 0 2rem 0;
    background: #f4e8dc;
    padding: 1.5rem 2.5rem;
    border-radius: 70px;
}

.color-dot {
    display: inline-block;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    margin-right: 10px;
    border: 2px solid rgba(255,255,255,0.6);
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}

.color-item {
    display: flex;
    align-items: center;
    background: white;
    padding: 0.5rem 1.5rem 0.5rem 0.8rem;
    border-radius: 50px;
    box-shadow: 0 4px 10px #d9bc9c;
    font-size: 1rem;
}

.techniques-block {
    background: #e1cfbb;
    border-radius: 50px;
    padding: 2rem 2.5rem;
    margin: 2.5rem 0;
    border-left: 15px solid #b57e4a;
    box-shadow: 0 8px 20px rgba(80, 50, 20, 0.2);
}

.techniques-block p {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.1rem;
}

.step-list {
    list-style: none;
    counter-reset: step-counter;
}

.step-list li {
    counter-increment: step-counter;
    margin-bottom: 2.5rem;
    position: relative;
    padding-left: 4rem;
    font-size: 1.1rem;
}

.step-list li::before {
    content: counter(step-counter);
    background-color: #7a9a7a;
    color: white;
    font-weight: bold;
    width: 2.8rem;
    height: 2.8rem;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    left: -0.3rem;
    top: -0.2rem;
    font-size: 1.2rem;
    border: 3px solid #ecdacb;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.8rem;
    margin: 2rem 0;
}

.gallery-item {
    background: #f4e8dc;
    border-radius: 35px;
    padding: 1.2rem;
    box-shadow: 0 8px 18px rgba(100, 60, 30, 0.15);
    transition: transform 0.3s;
    cursor: pointer;
}

.gallery-item:hover {
    transform: translateY(-8px);
}

.gallery-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 25px;
    border: 3px solid white;
    box-shadow: 0 5px 12px rgba(0,0,0,0.15);
}

.gallery-item p {
    text-align: center;
    margin-top: 1rem;
    font-style: italic;
    color: #4d4239;
    font-size: 1rem;
    font-weight: 500;
}

.newsletter-block {
    background: #7a9a7a;
    border-radius: 60px;
    padding: 3rem 2.5rem;
    margin: 3rem 0 2rem;
    color: white;
    text-align: center;
    border: 2px solid #c9ad8d;
}

.newsletter-block h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: white;
}

.newsletter-block p {
    margin-bottom: 2rem;
    font-size: 1.1rem;
    opacity: 0.95;
}

.subscribe-form {
    display: flex;
    gap: 1rem;
    justify-content: center;
    max-width: 600px;
    margin: 0 auto;
}

.subscribe-form input {
    flex: 1;
    padding: 1.2rem 1.8rem;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    outline: none;
    background: white;
    color: #2e2b26;
    border: 2px solid transparent;
}

.subscribe-form input:focus {
    border-color: #b57e4a;
}

.subscribe-form button {
    padding: 1.2rem 2.5rem;
    background: #b57e4a;
    color: white;
    border: none;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.subscribe-form button:hover {
    background: #9a6637;
    transform: scale(1.05);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

blockquote {
    background: #efe1d2;
    padding: 1.5rem 2.5rem;
    border-radius: 50px;
    font-style: italic;
    border-left: 10px solid #7a9a7a;
    margin: 2.5rem 0;
    color: #2e2b26;
    font-size: 1.1rem;
}

.footer {
    background: #2c4a3b;
    color: white;
    padding: 3rem 2.5rem 1.5rem;
    border-radius: 40px 40px 0 0;
    margin-top: 3rem;
    border-top: 3px solid #b57e4a;
}

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

.footer-section h3 {
    margin-bottom: 1.2rem;
    color: #e6c9a8;
    font-size: 1.3rem;
    border-bottom: 2px solid #b57e4a;
    padding-bottom: 0.5rem;
    display: inline-block;
}

.footer-section p, .footer-section a {
    color: #d9c3ab;
    text-decoration: none;
    line-height: 2;
    font-size: 1rem;
}

.footer-section a:hover {
    color: #e6c9a8;
}

.copyright {
    text-align: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid #7a5a3a;
    color: #bda68b;
}

.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 30px;
    border: 5px solid #fcf9f2;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.6);
}

.modal-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: white;
    font-size: 60px;
    font-weight: 300;
    cursor: pointer;
    background: rgba(70, 50, 30, 0.4);
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    line-height: 1;
}

.modal-close:hover {
    color: #e8dbcf;
    background: rgba(120, 80, 40, 0.7);
    transform: rotate(90deg);
}

.clickable-img {
    cursor: pointer;
    transition: opacity 0.3s, transform 0.3s;
}

.clickable-img:hover {
    opacity: 0.9;
    transform: scale(1.02);
}

::selection {
    background: #b57e4a;
    color: white;
}

@media (max-width: 800px) {
    .page {
        padding: 1.8rem;
    }
    h1 {
        font-size: 2.2rem;
    }
    .crafts-grid {
        grid-template-columns: 1fr;
    }
    .subscribe-form {
        flex-direction: column;
    }
    .stat-block {
        flex-direction: column;
        align-items: flex-start;
    }
    .modal-close {
        top: 15px;
        right: 20px;
        font-size: 45px;
        width: 55px;
        height: 55px;
    }
}