@import url('https://fonts.cdnfonts.com/css/rubik');

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

body {
    font-family: 'Rubik', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px 16px;
}

.container {
    max-width: 468px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Header */
.header {
    background: #ffffff;
    padding: 24px 20px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    /* margin-bottom: 20px; */
    max-width: 468px;
    margin-left: auto;
    margin-right: auto;
    border-radius: 20px 20px 0px 0px;
    padding-bottom: 10px;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap;
    gap: 16px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 16px;
    border-radius: 7px;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.logo-text {
    font-size: 11px;
    font-weight: 700;
    color: #1a1a1a;
    letter-spacing: -0.5px;
}

.header-info {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    align-items: center;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #666;
    font-size: 13px;
    font-weight: 500;
}

.info-item .icon {
    font-size: 18px;
}

.info-item-main {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: right;
}

.info-main-text {
    font-size: 11px;
    font-weight: 600;
    color: #1a1a1a;
    line-height: 1.3;
}

.info-sub-text {
    font-size: 11px;
    font-weight: 500;
    color: #666;
    margin-top: 2px;
    line-height: 1.2;
}

.header-subtitle {
    margin-top: 0px;
    color: #666;
    font-size: 9px;
    font-weight: 500;
}
@media screen and (max-width: 430px) {
    .header-subtitle,.info-main-text,.info-sub-text {
        font-size: 8px;
    }
    
}
@media screen and (max-width: 400px) {
    .header-subtitle,.info-main-text,.info-sub-text {
        font-size: 8px;
    }
    
}
/* Hero Section */
.hero {
    background: #ffffff;
    padding: 14px 16px 4px;
    border-radius: 0px 0px 20px 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    max-width: 468px;
    margin-left: auto;
    margin-right: auto;
}

.hero-content {
    text-align: center;
}

.hero-badge {
    display: none;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #667eea;
    margin-bottom: 16px;
    font-weight: 600;
    text-align: start;
}

.hero-title {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 24px;
    line-height: 1.3;
    letter-spacing: -0.5px;
}

/* Hero Slider */
.hero-slider-wrapper {
    position: relative;
    margin: 32px 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    max-height: 374px;
}

.hero-slider {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 16px;
}

.slider-container {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 100%;
    /* висота задається JS під пропорції активної картинки */
    max-height: 374px;
    overflow: hidden;
    transition: padding-bottom 0.4s ease;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slide.active {
    opacity: 1;
    z-index: 1;
}

.slide-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
}

.hero-badge-overlay {
    position: absolute;
    top: 16px;
    right: 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    z-index: 2;
    animation: fadeIn 0.6s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: #667eea;
}

.slider-nav:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.slider-nav:active {
    transform: translateY(-50%) scale(0.95);
}

.slider-prev {
    left: 12px;
}

.slider-next {
    right: 12px;
}

.slider-indicators {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.indicator:hover {
    background: rgba(255, 255, 255, 0.7);
    transform: scale(1.2);
}

.indicator.active {
    background: #fff;
    border-color: #fff;
    width: 24px;
    border-radius: 5px;
}

/* Touch support for mobile */
.hero-slider {
    touch-action: pan-y;
}

@media (max-width: 480px) {
    .slider-nav {
        width: 36px;
        height: 36px;
    }
    
    .slider-nav svg {
        width: 20px;
        height: 20px;
    }
    
    .slider-prev {
        left: 8px;
    }
    
    .slider-next {
        right: 8px;
    }
    
    .hero-badge-overlay {
        font-size: 10px;
        padding: 6px 12px;
        top: 10px;
        right: 10px;
        max-width: calc(100% - 100px);
        text-align: start;
    }
    
    .slider-indicators {
        bottom: 10px;
        gap: 6px;
    }
    
    .indicator {
        width: 8px;
        height: 8px;
    }
    
    .indicator.active {
        width: 20px;
    }
}

@media (max-width: 360px) {
    .slider-nav {
        width: 32px;
        height: 32px;
    }
    
    .slider-nav svg {
        width: 18px;
        height: 18px;
    }
    
    .hero-badge-overlay {
        font-size: 9px;
        padding: 5px 10px;
    }
}

.hero-features {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 32px 0;
}

.feature-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 20px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 13px;
    color: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: transform 0.2s;
}

.feature-badge:hover {
    transform: translateY(-2px);
}

.feature-badge.red {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.feature-badge.green {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.feature-badge.yellow {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.hero-description {
    font-size: 15px;
    color: #666;
    margin: 0 auto 24px;
    line-height: 1.7;
}

.hero-price {
    margin: 24px 0;
}

.old-price {
    text-decoration: line-through;
    color: #999;
    font-size: 16px;
    margin-right: 12px;
}

.new-price {
    font-size: 24px;
    font-weight: 800;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-stats {
    display: flex;
    justify-content: space-around;
    gap: 16px;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid #f0f0f0;
}

.stat-item {
    text-align: center;
    flex: 1;
}

.stat-number {
    font-size: 36px;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 6px;
}

.stat-label {
    font-size: 12px;
    color: #666;
    line-height: 1.4;
    font-weight: 500;
}

.hero-features-bottom {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid #f0f0f0;
}

.hero-features-bottom .feature-text {
    font-size: 14px;
    font-weight: 500;
    color: #666;
    text-align: center;
    line-height: 1.5;
}

/* Materials Section */
.materials {
    background: #ffffff;
    padding: 40px 20px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    max-width: 468px;
    margin-left: auto;
    margin-right: auto;
}

.section-title {
    font-size: 28px;
    font-weight: 800;
    text-align: center;
    color: #1a1a1a;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

.section-subtitle {
    text-align: center;
    color: #666;
    font-size: 14px;
    margin: 0 auto 32px;
    line-height: 1.7;
}

.materials-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.material-card {
    padding: 24px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 16px;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.material-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.material-card h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #1a1a1a;
}

.material-card p {
    color: #555;
    line-height: 1.7;
    font-size: 14px;
}

/* Products Section */
.products {
    background: #ffffff;
    padding: 40px 20px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    max-width: 468px;
    margin-left: auto;
    margin-right: auto;
}

.products-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 32px;
}

.product-card {
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid #f0f0f0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
}

.product-image {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
}

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

.product-info {
    padding: 20px;
}

.product-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
    color: #1a1a1a;
}

.product-material {
    font-size: 13px;
    color: #667eea;
    margin-bottom: 10px;
    font-weight: 600;
}
h1.hero-title {
    font-size: 11px;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--accent-dark);
    font-weight: 600;
    margin-bottom: 6px;
    text-align: start;
}

.product-description-wrap {
    margin-bottom: 12px;
}

.product-description {
    font-size: 14px;
    color: #666;
    margin-bottom: 8px;
    line-height: 1.6;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.product-description-wrap .product-description {
    max-height: 4.8em;
    margin-bottom: 6px;
}

.product-description-wrap .product-description.is-expanded {
    max-height: 2000px;
}

.product-description-toggle {
    background: none;
    border: none;
    padding: 0;
    font-size: 13px;
    font-weight: 600;
    color: #667eea;
    cursor: pointer;
    text-decoration: underline;
    transition: color 0.2s;
}

.product-description-toggle:hover {
    color: #5568d3;
}

.product-price {
    margin-bottom: 16px;
}

.product-price .old-price {
    font-size: 13px;
}

.product-price .new-price {
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Buttons */
.btn {
    display: inline-block;
    width: 100%;
    padding: 16px 24px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 700;
    font-size: 16px;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #6b7280;
    color: #fff;
}

.btn-secondary:hover {
    background: #4b5563;
}

/* Delivery Section */
.delivery {
    background: #ffffff;
    padding: 40px 20px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    max-width: 468px;
    margin-left: auto;
    margin-right: auto;
}

.delivery-content {
    margin-top: 32px;
}

.delivery-section {
    margin-bottom: 32px;
    padding: 24px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 16px;
}

.delivery-section:last-of-type {
    margin-bottom: 24px;
}

.delivery-section h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
    color: #1a1a1a;
}

.delivery-section ul {
    list-style: none;
    padding: 0;
}

.delivery-section ul li {
    color: #555;
    line-height: 1.8;
    font-size: 14px;
    margin-bottom: 10px;
    padding-left: 24px;
    position: relative;
}

.delivery-section ul li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #667eea;
    font-weight: bold;
}

.delivery-section ul li strong {
    color: #1a1a1a;
    font-weight: 600;
}

.delivery-info {
    padding: 20px;
    background: linear-gradient(135deg, #ffeaa7 0%, #fab1a0 100%);
    border-radius: 16px;
    margin-top: 24px;
}

.delivery-info p {
    color: #1a1a1a;
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 8px;
}

.delivery-info p:last-child {
    margin-bottom: 0;
}

.delivery-info p strong {
    font-weight: 700;
}

/* Order Form Section */
.order-form-section {
    background: #ffffff;
    padding: 40px 20px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    max-width: 468px;
    margin-left: auto;
    margin-right: auto;
}

.order-form {
    margin-top: 32px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
    color: #1a1a1a;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.3s;
    background: #ffffff;
    color: #1a1a1a;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

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

.alert {
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    font-size: 14px;
    font-weight: 500;
}

.alert-success {
    background: linear-gradient(135deg, #84fab0 0%, #8fd3f4 100%);
    color: #1a1a1a;
}

.alert-error {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
}

.alert-error ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.alert-error ul li {
    margin-bottom: 4px;
}

.alert-error ul li:last-child {
    margin-bottom: 0;
}

/* Footer */
.footer {
    background: #1a1a1a;
    color: #fff;
    padding: 32px 20px;
    text-align: center;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    max-width: 468px;
    margin: 20px auto 0;
}

.footer p {
    font-size: 13px;
    color: #999;
}

/* Product Detail */
.product-detail {
    background: #fff;
    padding: 40px 20px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    max-width: 468px;
    margin: 0 auto;
}

.product-detail-content {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.product-main-image {
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.product-main-image img {
    width: 100%;
    height: auto;
    display: block;
}

.product-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-top: 20px;
}

.product-gallery img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.3s;
}

.product-gallery img:hover {
    transform: scale(1.05);
}

.product-info-detail h1 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 12px;
    color: #1a1a1a;
    letter-spacing: -0.5px;
}

.product-info-detail .product-material {
    font-size: 15px;
    color: #667eea;
    margin-bottom: 16px;
    font-weight: 600;
}

.product-info-detail .product-description {
    font-size: 15px;
    color: #666;
    line-height: 1.8;
    margin-bottom: 24px;
}

/* Cart Icon Button */
.product-image {
    position: relative;
}

.cart-icon-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 10;
    color: #667eea;
}

.cart-icon-btn:hover {
    background: #fff;
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
}

.cart-icon-btn:active {
    transform: scale(0.95);
}

.cart-icon-btn svg {
    width: 20px;
    height: 20px;
}

/* Cart Items in Form */
#cart-items-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 8px;
}

.cart-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: #f9fafb;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    transition: all 0.3s;
}

.cart-item:hover {
    border-color: #667eea;
    background: #f3f4f6;
}

.cart-item-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.cart-item-info strong {
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
}

.cart-item-size {
    font-size: 12px;
    color: #666;
    font-weight: 500;
    display: block;
    margin-top: 4px;
}

.cart-item-price {
    font-size: 13px;
    color: #667eea;
    font-weight: 600;
}

.cart-item-remove {
    width: 32px;
    height: 32px;
    background: transparent;
    border: none;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    color: #ef4444;
    margin-left: 12px;
}

.cart-item-remove:hover {
    background: #fee2e2;
    transform: scale(1.1);
}

.cart-item-remove:active {
    transform: scale(0.95);
}

.cart-item-remove svg {
    width: 18px;
    height: 18px;
}

.cart-empty {
    padding: 20px;
    text-align: center;
    color: #9ca3af;
    font-size: 14px;
    background: #f9fafb;
    border-radius: 12px;
    border: 2px dashed #e5e7eb;
}

/* Cart Notifications */
.cart-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    z-index: 10000;
    opacity: 0;
    transform: translateY(-20px);
    transition: all 0.3s;
    max-width: 300px;
    font-size: 14px;
    font-weight: 500;
}

.cart-notification.show {
    opacity: 1;
    transform: translateY(0);
}

.cart-notification-success {
    border-left: 4px solid #10b981;
    color: #065f46;
}

.cart-notification-error {
    border-left: 4px solid #ef4444;
    color: #991b1b;
}

/* Responsive Design */
@media (max-width: 480px) {
    body {
        padding: 12px;
    }
    
    .container {
        padding: 0 12px;
    }
    
    .hero-title {
        font-size: 24px;
        text-align: start;
    }
    
    .section-title {
        font-size: 24px;
    }
    
    .stat-number {
        font-size: 28px;
    }
    
    .hero-badge-overlay {
        display: inline-block;
        margin-top: 16px;
    }
}
