@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

* {
    font-family: 'Inter', sans-serif;
}

html {
    scroll-behavior: smooth;
}

#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #22c55e, #16a34a, #15803d);
    z-index: 9999;
    width: 0%;
    transition: width 0.1s linear;
}

.hero-bg {
    background-image: linear-gradient(135deg, rgba(21, 128, 61, 0.88) 0%, rgba(22, 101, 52, 0.92) 100%),
                       url('../images/hero-banner.webp');
    background-size: cover;
    background-position: center;
}

.hero-spotlight {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    background: radial-gradient(circle 300px at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(255,255,255,0.08), transparent 70%);
}

.hero-bg:hover .hero-spotlight {
    opacity: 1;
}

.catalog-card {
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
}

.catalog-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(21, 128, 61, 0.95) 0%, rgba(21, 128, 61, 0.7) 50%, transparent 100%);
    transition: all 0.3s ease;
}

.catalog-card:hover::before {
    background: linear-gradient(to top, rgba(21, 128, 61, 0.98) 0%, rgba(21, 128, 61, 0.85) 50%, rgba(21, 128, 61, 0.3) 100%);
}

.catalog-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.glassmorphism {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.feature-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 20px 40px rgba(21, 128, 61, 0.2);
}

.feature-icon-wrapper {
    position: relative;
    overflow: hidden;
}

.feature-icon-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.3) 0%, transparent 100%);
    pointer-events: none;
}

.news-card {
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
}

.news-card::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70%;
    background: linear-gradient(to top, rgba(21, 128, 61, 0.95) 0%, rgba(21, 128, 61, 0.7) 40%, transparent 100%);
    z-index: 1;
}

.news-card:hover {
    transform: translateY(-8px) rotate(0.5deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.product-card {
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.product-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #16a34a, #22c55e);
    transform: scaleX(0);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 0 0 0.75rem 0.75rem;
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 32px -8px rgba(21, 128, 61, 0.18);
}

.product-card:hover::after {
    transform: scaleX(1);
}

.product-card:hover .product-image {
    transform: scale(1.08);
}

.btn-primary {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #15803d 0%, #166534 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(21, 128, 61, 0.3);
}

.btn-outline {
    border: 2px solid white;
    transition: all 0.3s ease;
}

.btn-outline:hover {
    background: white;
    color: #15803d;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 255, 255, 0.3);
}

.ripple-container {
    position: relative;
    overflow: hidden;
}

.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    transform: scale(0);
    animation: ripple-anim 0.6s ease-out;
    pointer-events: none;
}

@keyframes ripple-anim {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

.cta-section {
    background: linear-gradient(135deg, rgba(22, 101, 52, 0.95) 0%, rgba(21, 128, 61, 0.92) 100%),
                url('../images/hero-banner.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-left.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-right.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-scale.revealed {
    opacity: 1;
    transform: scale(1);
}

.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }
.stagger-5 { transition-delay: 0.5s; }
.stagger-6 { transition-delay: 0.6s; }

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

.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

.hero-stagger-1 { animation-delay: 0.1s; }
.hero-stagger-2 { animation-delay: 0.3s; }

.gradient-text {
    background: linear-gradient(135deg, #15803d 0%, #22c55e 50%, #15803d 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 3s ease-in-out infinite;
}

@keyframes gradient-shift {
    0%, 100% { background-position: 0% center; }
    50% { background-position: 200% center; }
}

.gradient-text-white {
    background: linear-gradient(135deg, #ffffff 0%, #bbf7d0 50%, #ffffff 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 4s ease-in-out infinite;
}

.text-shadow {
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.tab-btn {
    position: relative;
    transition: all 0.3s ease;
}

.tab-btn::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 3px;
    background: #15803d;
    border-radius: 2px;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.tab-btn.tab-active::after {
    width: 60%;
}

.tab-btn.tab-active {
    background: #15803d;
    color: white;
    box-shadow: 0 4px 12px rgba(21, 128, 61, 0.3);
    transform: translateY(-2px);
}

.counter-value {
    display: inline-block;
    font-variant-numeric: tabular-nums;
}

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-pulse 1.5s ease-in-out infinite;
}

@keyframes skeleton-pulse {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.mobile-overlay {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.mobile-drawer {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.mobile-drawer.active {
    transform: translateX(0);
}

.burger-line {
    transition: all 0.3s ease;
}

.burger-active .burger-line:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.burger-active .burger-line:nth-child(2) {
    opacity: 0;
}

.burger-active .burger-line:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.search-wrapper {
    position: relative;
    z-index: 9999;
}

.search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-top: none;
    border-radius: 0 0 1rem 1rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    max-height: 360px;
    overflow-y: auto;
    z-index: 9999;
    display: none;
}

.search-dropdown.active {
    display: block;
}

.search-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 24px;
    transition: background 0.15s;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.search-dropdown-item:hover,
.search-dropdown-item.highlighted {
    background: #f0fdf4;
}

.search-dropdown-item .item-icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0fdf4;
    color: #16a34a;
}

.search-dropdown-item .item-icon.category {
    background: #ede9fe;
    color: #7c3aed;
}

.search-dropdown-item .item-body {
    flex: 1;
    min-width: 0;
}

.search-dropdown-item .item-title {
    font-weight: 600;
    color: #111827;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-dropdown-item .item-title mark {
    background: #dcfce7;
    color: #166534;
    padding: 0 2px;
    border-radius: 2px;
}

.search-dropdown-item .item-desc {
    font-size: 0.8125rem;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-dropdown-empty {
    padding: 28px 24px;
    text-align: center;
    color: #9ca3af;
}

.search-dropdown-group-title {
    padding: 10px 24px 4px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #9ca3af;
}

.search-dropdown-loading {
    padding: 28px 24px;
    text-align: center;
    color: #9ca3af;
}

.search-spinner {
    width: 28px;
    height: 28px;
    border: 3px solid #e5e7eb;
    border-top-color: #16a34a;
    border-radius: 50%;
    animation: search-spin 0.6s linear infinite;
    margin: 0 auto 8px;
}

@keyframes search-spin {
    to { transform: rotate(360deg); }
}

#backToTop {
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

#backToTop.visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

#stickyCta {
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

#stickyCta.visible {
    transform: translateY(0);
}

.stat-card {
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 0deg, transparent, rgba(21, 128, 61, 0.1), transparent 30%);
    animation: stat-rotate 6s linear infinite;
}

@keyframes stat-rotate {
    to { transform: rotate(360deg); }
}

@media (max-width: 1023px) {
    .hero-bg {
        background-attachment: scroll;
    }
    .cta-section {
        background-attachment: scroll;
    }
}

.site-header {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.site-header.scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.site-header.scrolled .header-top {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.site-header.scrolled .header-logo {
    height: 2rem;
}

@media (min-width: 1024px) {
    .site-header.scrolled .header-logo {
        height: 2.25rem;
    }
}

/* Flat page content enhancements */
.flat-content h2 {
    border-left: 4px solid #16a34a;
    padding-left: 1rem;
    margin-top: 2.5rem !important;
    margin-bottom: 1rem !important;
}

.flat-content h3 {
    color: #15803d;
}

.flat-content ul {
    list-style: none;
    padding-left: 0 !important;
}

.flat-content ul li {
    position: relative;
    padding-left: 1.75rem;
    margin-bottom: 0.75rem;
}

.flat-content ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.45em;
    width: 0.6em;
    height: 0.6em;
    background-color: #22c55e;
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E");
    mask-size: contain;
    -webkit-mask-size: contain;
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
}

.flat-content strong {
    color: #15803d;
    font-weight: 700;
}

.flat-content a[href^="tel:"] {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: #f0fdf4;
    border: 1px solid #dcfce7;
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    font-weight: 600;
    color: #15803d !important;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.flat-content a[href^="tel:"]:hover {
    background: #dcfce7;
    border-color: #bbf7d0;
}

.flat-content a[href^="mailto:"] {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: #f0fdf4;
    border: 1px solid #dcfce7;
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    font-weight: 600;
    color: #15803d !important;
    transition: all 0.2s ease;
}

.flat-content a[href^="mailto:"]:hover {
    background: #dcfce7;
    border-color: #bbf7d0;
}

.flat-content img {
    border-radius: 0.75rem;
}

.flat-content .flex.flex-wrap.gap-4.mt-8 {
    background: #f9fafb;
    border: 1px solid #f3f4f6;
    border-radius: 1rem;
    padding: 1.5rem;
}

.flat-content .flex.flex-wrap.gap-4.mt-8 img {
    border-radius: 0.5rem;
}

.flat-content table {
    border-collapse: collapse;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.flat-content table th {
    background: #f9fafb;
    text-align: left;
    padding: 0.625rem 0.75rem;
    font-weight: 600;
    color: #374151;
    border-bottom: 2px solid #e5e7eb;
}

.flat-content table td {
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid #f3f4f6;
    color: #4b5563;
}

.cart-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 9998;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.cart-modal-overlay.visible {
    opacity: 1;
}

.cart-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.cart-modal.visible {
    opacity: 1;
    pointer-events: auto;
}

.cart-modal-card {
    background: white;
    border-radius: 1.5rem;
    padding: 2rem;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    text-align: center;
    transform: scale(0.9);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.cart-modal.visible .cart-modal-card {
    transform: scale(1);
}

.product-content h1 {
    display: none;
}

.product-content h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #111827;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    padding-left: 0.75rem;
    border-left: 3px solid #16a34a;
}

.product-content h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #15803d;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
}

.product-content h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.product-content p {
    margin-bottom: 0.75rem;
    line-height: 1.7;
}

.product-content ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0.75rem;
}

.product-content ul li {
    position: relative;
    padding-left: 1.25rem;
    margin-bottom: 0.35rem;
    line-height: 1.6;
}

.product-content ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #22c55e;
}

.product-content ol {
    padding-left: 1.5rem;
    margin-bottom: 0.75rem;
    list-style-type: decimal;
}

.product-content ol li {
    margin-bottom: 0.35rem;
    line-height: 1.6;
}

.product-content strong,
.product-content b {
    font-weight: 600;
    color: #15803d;
}

.product-content table {
    border-collapse: collapse;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.product-content table th {
    background: #f9fafb;
    text-align: left;
    padding: 0.625rem 0.75rem;
    font-weight: 600;
    color: #374151;
    border-bottom: 2px solid #e5e7eb;
}

.product-content table td {
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid #f3f4f6;
    color: #4b5563;
}

.product-content table tr:hover td {
    background: #f9fafb;
}

.product-content a {
    color: #16a34a;
    text-decoration: underline;
}

.product-content a:hover {
    color: #15803d;
}
