/* ========== ДЕСКТОП (по умолчанию) ========== */



* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    margin: 0;
    font-family: "Playpen Sans", cursive;
    background: #f3f3f3;
    color: #212121;
    min-height: 100vh;
}

.page {
    max-width: 1100px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 0 16px 24px;
}

.header {
    margin: 0 auto;
    padding: 10px 10px;
}

/* ========== ВЕРХНЕЕ МЕНЮ ========== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #fefcfb;
    padding: 5px 50px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    position: sticky;
    top: 0;
    z-index: 99;
    flex-wrap: wrap;
}

.logo img {
    height: 50px;
    width: auto;
    border-radius: 5px;
    object-fit: contain;
}

/* Оверлей для затемнения */
.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
}

.overlay.active {
    display: block;
}

.nav-links {
    display: flex;
    gap: 15px;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.nav-links a {
    color: black;
    font-family: 'Be Vietnam Pro', sans-serif;
    text-decoration: none;
    font-size: 20px;
    padding: 8px 15px;
    transition: all 0.3s ease;
    border-radius: 25px;
    font-weight: 540;
}

.nav-links a:hover {
    color: #94162C;
    transform: translateY(-2px);
}

.nav-links a.active {
    color: #94162C;
}

.spacer {
    width: 150px;
}

/* АДАПТИВНОСТЬ ДЛЯ МЕНЮ (только для телефонов) */
@media (max-width: 768px) {
    .navbar {
        padding: 8px 20px;
        width: 100%;
    }
    
    .nav-links {
        position: static;
        transform: none;
        display: flex !important;
        gap: 10px;
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 0px;
    }
    
    .nav-links a {
        padding: 8px 12px;
        font-size: 16px;
    }
    
    .spacer {
        display: none;
    }
}

/* ========== НАВИГАЦИЯ ПО ШАГАМ ========== */
.steps-navigation {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 10px;
    margin-top: 30px;
    margin-bottom: 5px;
    padding: 0 5px;
    flex-wrap: wrap;
}

.step-item {
    display: flex;
    align-items: center;
    gap: 12px;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.step-item.active {
    opacity: 1;
}

.step-item.completed {
    opacity: 0.8;
}

.step-circle {
    width: 40px;
    height: 40px;
    background-color: #982030;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 18px;
    box-shadow: 0 2px 8px rgba(75, 103, 65, 0.3);
}

.step-item.active .step-circle {
    background-color: #982030;
    box-shadow: 0 4px 12px rgba(221, 191, 195, 1);
    transform: scale(1.05);
}

.step-content {
    display: flex;
    flex-direction: column;
}

.step-label {
    font-size: 14px;
    color: #982030;
    font-weight: 600;
    margin-bottom: 2px;
}

.step-title {
    font-size: 16px;
    color: #333;
    font-weight: 500;
}

.step-item.active .step-title {
    color: #000;
    font-weight: 600;
}

/* ========== КОНТЕЙНЕРЫ ДЛЯ РЕАКЦИЙ ========== */
.reaction-container {
    background: #ffe7ea;
    border-radius: 30px;
    padding: 20px;
    margin-bottom: 20px;
    margin-top: 30px;
    box-shadow: 0 4px 16px rgba(221, 191, 195, 1);
    gap: 20px;
}

.container-title {
    font-size: 24px;
    color: black;
    margin-bottom: 10px;
   /* border-bottom: 2px solid #982030;*/
    
    padding-bottom: 10px;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.reaction-content {
    display: flex;
    gap: 30px;
}

/* Левая панель с настройками */
.settings-panel {
    flex: 1;
    background: #ffe7ea;
    border-radius: 20px;
}

.settings-section {
    margin-bottom: 15px;
}

.settings-section label {
    font-weight: 600;
    color: black;
    display: block;
    margin-bottom: 10px;
}

/* Сетка с картинками */
.images-grid {
    /*display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-bottom: 20px; */

    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.image-option {
    width: 60px;
    height: 60px;
    border: 1px solid black;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
}

.image-option:hover {
    transform: scale(1.05);
    border-color: #982030;
}

.image-option input[type="radio"] {
    display: none;
}

.image-option input[type="radio"]:checked + img {
    border: 3px solid #982030;
}

.image-option img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}










.upload-section {
    margin: 10px 0;
    padding: 10px 10px 25px 10px;
    background: #ffcfd5;
    border-radius: 8px;
}

.upload-section label {
    display: block;
    font-weight: 600;
    color: black;
    margin-bottom: 15px;
}

.custom-upload {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.custom-upload input[type="file"] {
    padding: 10px;
    border: 2px dashed black;
    border-radius: 8px;
    background: white;
    cursor: pointer;
    font-size: 15px;
    font-family: "Playpen Sans", cursive;
}

.file-name {
    display: block;
    font-size: 10px;
    color: #313131;
    font-style: italic;
    padding: 1px 0;
    font-family: "Playpen Sans", cursive;
}

.upload-hint {
    font-size: 10px;
    color: #313131;
    margin-bottom: 8px;
    font-family: "Playpen Sans", cursive;
}








/* Кнопки-пресеты */
.preset-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 15px;
    color: black;

}

.preset-btn {
    background: #ffcfd5;
    border: 1px solid #ddbfc3;
    border-radius: 20px;
    padding: 8px 12px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s;
    color: black;
}

.preset-btn:hover {
    background: #ddbfc3;
    color: rgb(0, 0, 0);
    border: 2px solid #982030;
}

/* Текстовые поля */
.settings-section textarea {
    width: 100%;
    margin: 8px 0 16px;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 14px;
    font-family: inherit;
  
    resize: vertical;
}

.settings-section textarea:focus {
    outline: none;
    border-color: #982030;
    box-shadow: 0 0 0 2px rgba(75, 103, 65, 0.2);
}


    
 


.phone-mockup {
    width: 330px !important;
    min-height: 600px !important;


    background-size: cover;
    background-position: center;
    border-radius: 40px;
    padding: 15px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    box-shadow: 0 30px 50px rgba(0, 0, 0, 0.1), 0 0 0 8px #333, 0 0 0 10px #555;
    flex-shrink: 0;
    margin: 20px;
    gap: 0px;
    justify-content: center;
    overflow: hidden; 
    margin-bottom: 30px;
    
}


 .preview-image {width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 10px 0;

    max-height: 330px !important;
    min-height: 100px !important;
}

.preview-image img {
    max-width: 95% !important;
    max-height: 330px !important;
   


    /*width: auto;*/
    /*height: auto;*/
    object-fit: contain;
    border-radius: 10px;


    
}
 











/* Убираем wrapper - он не нужен */
.preview-text-wrapper {
    width: 100%;
    margin: 0;
    padding: 0;
}

.preview-text {
    color: black;
    font-size: 20px;
    text-align: center;
    padding: 8px 12px;
    font-weight: 600;
    background: rgba(0, 0, 0, 0);
    border-radius: 12px;
    width: 100%;
    word-break: break-word;
    overflow-wrap: break-word;
    margin: 0;
    box-sizing: border-box;
}

/* Кнопки навигации */
/* Кнопки навигации */
.navigation-buttons {
    
    display: flex;
    justify-content: center;
    flex-direction: row; 
    gap: 15px;
    margin-top: 30px;
}
.letter-style {

    gap: 30px 20px;
}
.btn-back {
    display: inline-block;
    background: #f5f5f5;
    color: #666;
    font-weight: 700;
    font-size: 16px;
    padding: 14px 20px;
    border-radius: 40px;
    text-decoration: none;
    text-align: center;
    border: 1px solid #ddd;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    cursor: pointer;
    transition: all 0.2s;
    flex: 1;
    min-width: 150px;
    max-width: 160px;
   
    
}

.btn-back:hover {
    background: #e0e0e0;
    transform: translateX(-3px);
}

.btn-next {
    flex: 1;
    background: #982030;
    color: white;
    font-weight: 700;
    font-size: 16px;
    padding: 17px 20px;
    border-radius: 40px;
    text-decoration: none;
    text-align: center;
    border: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    cursor: pointer;
    transition: opacity 0.2s, transform 0.2s;
    display: inline-block;
    min-width: 150px;
    max-width: 160px;
    
}

.btn-next:hover {
    opacity: 0.9;
    transform: translateX(3px);
}






/* Футер */
.footer {
    margin-top: auto;
    padding: 40px 16px;
    text-align: center;
    background-color: #982030;
    border-radius: 20px 20px 0 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px 20px;
    margin-bottom: 16px;
}

.footer-links a {
    color: white;
    font-size: 14px;
    text-decoration: none;
}

.footer-links a:hover {
    text-decoration: underline;
}

.footer-info p {
    margin: 4px 0;
    color: #e2576a;
    font-size: 13px;
}

/* ========== АДАПТИВНОСТЬ ========== */

/* Планшеты */
@media (max-width: 1024px) {

    .phone-mockup {
        width: 290px !important;
        min-height: 500px !important;
        margin: 0 auto;
        margin-bottom: 30px;
    }

    
    .preview-image {
        max-height: 300px !important;
        min-height: 100px !important;
        margin: 5px 0;
    }
    
    .preview-image img {
        max-width: 95% !important;
        max-height: 260px !important;
    }
    
    .reaction-content {
        flex-direction: column;
        align-items: center;
    }
    
    
}

/* Телефоны (планшетная ориентация) */
@media (max-width: 768px) {


    .phone-mockup {
        width: 290px !important;
        min-height: 480px !important;
        margin: 0 auto;
        margin-bottom: 30px;
    }

    
    .preview-image {
        max-height: 300px !important;
        min-height: 100px !important;
        margin: 5px 0;
    }
    
    .preview-image img {
        max-width: 95% !important;
        max-height: 260px !important;
    }


    .steps-navigation {
        gap: 10px;
       
    }
    
    .step-item {
        gap: 5px;
       
    }
    
    .images-grid {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
       
    }
    
    
    
    
    
    .container-title {
        font-size: 20px;
        margin-bottom: 20px;
    }
    
    .reaction-content {
        flex-direction: column;
        gap: 10px;
    }
    
    .settings-panel {
        width: 100%;
    }
    
    .settings-section {
        margin-bottom: 0px;
    }
    
    
    
    .preview-text {
        font-size: 20px !important;
        padding: 8px;
        font-weight: 600;
    }

    .footer-links {
    gap: 10px;
    }
}

/* Маленькие телефоны */
@media (max-width: 576px) {
   .phone-mockup {
        width: 290px !important;
        min-height: 480px !important;
    }
    
    .preview-text {
        font-size: 20px !important;
        padding: 6px;
    }
    
    .btn-back, .btn-next {
      
        font-size: 16px;
    }
    .preset-btn {
        font-size: 13px;
        padding: 8px 10px;
        color: black;
    }

     .navigation-buttons {
        flex-direction: column;
        align-items: center;
        
        justify-content: center;
        flex-direction: row; 
        margin-top: 5px;
        margin-bottom: 5px;
    }

    .btn-back, .btn-next {
        width: 100%;
        max-width: 190px;
        transform: none !important;
        
    }

    .btn-back:hover, .btn-next:hover {
        transform: none !important;
    }
}

@media (max-width: 375px) {
     .phone-mockup {
        width: 270px !important;
        min-height: 430px !important;
    }
    .preview-text {
        font-size: 18px !important;
        padding: 5px;
    }
}

.no-items {
    color: #999;
    font-style: italic;
    padding: 5px;
    text-align: center;
    background: #ffcfd5;
    border-radius: 8px;
    font-size: 12px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.reaction-container {
    animation: fadeIn 0.5s ease;
}







.hero-preview {
    width: 340px !important;
    min-height: 580px !important;


    background-size: cover;
    background-position: center;
    border-radius: 40px;
    padding: 15px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    box-shadow: 0 30px 50px rgba(0,0,0,0.1), 0 0 0 8px #333, 0 0 0 10px #555;
    flex-shrink: 0;
    margin-bottom: 20px;
   
    justify-content: center;
}



@media (max-width: 768px) {
   

    .hero-preview {
        width: 300px;
        min-height: 500px;
        margin-top: 20px;
        
    }
}



/* ================================================= Конверт ============================================================= */



/* ================================================= ВЫБОР ФОНА ============================================================= */
.background-section {
    margin: 5px 0;
}

.background-section label {
    font-weight: 600;
    color: black;
    display: block;
    margin-bottom: 5px;
}

.background-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 0px;
}

.background-option {
    width: 45px;
    height: 45px;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid black;
    transition: all 0.3s ease;
}

.background-option.selected {
    border: 3px solid #982030;  /* жирная обводка */
    
    transform: scale(1.02);
}


.background-option input[type="radio"] {
    display: none;
}

.background-option img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.no-items {
    color: #000000;
    font-style: italic;
}




.paper-design-option.selected {
    border-color: #982030 !important;
    background: #fff0f0 !important;
    box-shadow: 0 0 0 2px rgba(152, 32, 48, 0.2);
}
.paper-design-option:hover {
    transform: scale(1.02);
    transition: transform 0.2s;
}






/* Базовый стиль кнопки-карточки */
.style-btn {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 80px;
    padding: 5px;
    background: #ffffff;
    border: 1px solid #000000;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease;
    gap: 5px;
    text-align: center;
}

.style-btn img {
    width: 100%;      /* нужная ширина */
    height: 50px;     /* нужная высота */
    object-fit: cover; /* чтобы картинка красиво вписалась, не искажаясь */
    display: block;    /* убирает лишние отступы */
    border-radius: 8px; /* скругление углов (по желанию) */
}


/* Активное состояние (выбранная кнопка) */
.style-btn.active {
   
    background: #ffffff;
    border: 2px solid #982030;
}
.style-btn.active::before {
    transform: scale(1.05);
   
}

/* При наведении 
.style-btn:hover {
    transform: scale(1.02);
    border-color: #982030;
}*/

.envelope-design-section {
    margin-bottom: 20px;

}





























































































































