/* css/style.css - Cleaned and Optimized */

/* ========================================
   GLOBAL STYLES
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: #333;
    scroll-behavior: smooth;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 5rem;
}

@media (max-width: 768px) {
    html {
        scroll-padding-top: 4rem;
    }
}

/* ========================================
   ANIMATIONS
   ======================================== */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeInUp 1s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }

    to {
        opacity: 0;
        transform: translateY(-20px);
    }
}

@keyframes fadeInModal {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* ========================================
   NAVIGATION
   ======================================== */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1000;
    background-color: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

nav .container {
    max-width: 100%;
    margin: 0 auto;
}

nav img {
    transition: transform 0.3s ease;
}

nav img:hover {
    transform: scale(1.05);
}

.nav-link.active {
    position: relative;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 3px;
    background-color: #C8A951;
    border-radius: 2px;
}

/* Mobile Menu */
#mobile-menu-toggle {
    display: none;
    z-index: 1001;
    position: relative;
    cursor: pointer;
    background: transparent;
    border: 2px solid #C8A951;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.3s ease;
}

@media (max-width: 768px) {
    #mobile-menu-toggle {
        display: block;
    }

    nav .container {
        padding: 0.75rem 1rem;
    }

    nav img {
        height: 2.5rem;
    }

    nav span {
        font-size: 0.875rem;
    }
}

#mobile-menu-toggle:hover {
    background-color: rgba(200, 169, 81, 0.1);
    border-color: #B39641;
}

#mobile-menu-toggle:active {
    background-color: rgba(200, 169, 81, 0.2);
}

#mobile-menu-toggle:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(200, 169, 81, 0.3);
}

#mobile-menu-toggle svg {
    width: 1.5rem;
    height: 1.5rem;
    display: block;
    stroke: #C8A951;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

#mobile-menu {
    display: block;
    width: 100%;
    position: relative;
    background-color: white;
    border-top: 1px solid #e5e7eb;
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    z-index: 999;
    transition: max-height 0.4s ease-in-out, opacity 0.3s ease-in-out;
}

#mobile-menu:not(.hidden) {
    max-height: 600px;
    opacity: 1;
}

#mobile-menu a {
    display: block;
    padding: 0.875rem 1rem;
    color: #374151;
    text-decoration: none;
    font-size: 0.9375rem;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

#mobile-menu a:hover {
    background-color: #f9fafb;
    border-left-color: #C8A951;
    padding-left: 1.25rem;
}

#mobile-menu a.text-primary {
    color: #C8A951;
    font-weight: 600;
    background-color: #fef9e7;
    border-left-color: #C8A951;
}

/* ========================================
   LAYOUT & SPACING
   ======================================== */
.mt-16 {
    margin-top: 5rem !important;
}

@media (max-width: 768px) {
    .mt-16 {
        margin-top: 4rem !important;
    }
}

/* Hero section exception */
section.relative.mt-16.h-screen {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Header sections with gradient backgrounds */
section.mt-16.py-20,
section.mt-16.py-24,
section.bg-gradient-to-br,
section[class*="gradient"] {
    padding-top: 6rem !important;
}

@media (min-width: 769px) {

    section.mt-16.py-20,
    section.mt-16.py-24 {
        padding-top: 7rem !important;
    }
}

@media (max-width: 768px) {

    section.bg-gradient-to-br,
    section[class*="gradient"] {
        padding-top: 5rem !important;
    }
}

section h1,
section h2.text-4xl,
section h2.text-5xl {
    padding-top: 0.5rem;
}

/* ========================================
   SLIDER/CAROUSEL
   ======================================== */
.slider-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 0.5rem;
}

.slider-wrapper {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.slider-image {
    min-width: 100%;
    display: block;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 1rem;
    cursor: pointer;
    font-size: 1.5rem;
    z-index: 10;
    transition: background-color 0.3s ease;
    border-radius: 0.25rem;
}

.slider-btn:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.slider-btn:focus {
    outline: 2px solid #C8A951;
    outline-offset: 2px;
}

.slider-prev {
    left: 1rem;
}

.slider-next {
    right: 1rem;
}

.slider-dots {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
    z-index: 10;
}

.slider-dot {
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
    border: none;
}

.slider-dot.active {
    background-color: #C8A951;
    transform: scale(1.2);
}

.slider-dot:hover {
    background-color: rgba(255, 255, 255, 0.8);
}

/* Hero Slider Specific */
.hero-slider-container {
    position: relative;
    height: 100vh !important;
    padding-top: 0 !important;
}

.hero-slider-container .slider-wrapper {
    height: 100%;
}

.hero-slider-container .slider-image {
    min-width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-slider-container .slider-dots {
    bottom: 2rem;
    gap: 0.75rem;
}

.hero-slider-container .slider-dot {
    width: 0.875rem;
    height: 0.875rem;
    background-color: rgba(255, 255, 255, 0.6);
    border: 2px solid rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
}

.hero-slider-container .slider-dot.active {
    background-color: #C8A951;
    border-color: #C8A951;
    transform: scale(1.4);
}

.hero-slider-container .slider-dot:hover {
    background-color: rgba(255, 255, 255, 0.9);
}

.hero-slider-container .slider-prev,
.hero-slider-container .slider-next {
    display: none !important;
}

.hero-slider-container * {
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
}

.hero-slider-container {
    touch-action: pan-y;
}

/* ========================================
   BUTTONS
   ======================================== */
.btn-primary,
.btn-secondary,
.btn-outline {
    display: inline-block;
    padding: 0.75rem 2rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.btn-primary {
    background-color: #C8A951;
    color: white;
}

.btn-primary:hover {
    background-color: #B39641;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(200, 169, 81, 0.3);
}

.btn-secondary {
    background-color: #2F7D32;
    color: white;
}

.btn-secondary:hover {
    background-color: #256E29;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(47, 125, 50, 0.3);
}

.btn-outline {
    background-color: transparent;
    border-color: white;
    color: white;
}

.btn-outline:hover {
    background-color: white;
    color: #333;
}

/* ========================================
   FORMS
   ======================================== */
input[type="text"],
input[type="email"],
input[type="tel"],
select,
textarea {
    font-family: 'Poppins', sans-serif;
}

input:focus,
select:focus,
textarea:focus {
    border-color: #C8A951 !important;
    ring-color: #C8A951 !important;
}

input.error,
select.error,
textarea.error {
    border-color: #dc2626 !important;
    background-color: #fef2f2;
}

input.success,
select.success,
textarea.success {
    border-color: #2F7D32 !important;
    background-color: #f0fdf4;
}

/* ========================================
   CARDS & EFFECTS
   ======================================== */
.product-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.shadow-lg {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.shadow-xl {
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.shadow-2xl {
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

/* ========================================
   MODALS
   ======================================== */
#certModal,
#certModalFSSAI,
#certModalIEC,
#certModalAPEDA {
    animation: fadeInModal 0.3s ease-in-out;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

#certModal iframe,
#certModalFSSAI iframe,
#certModalIEC iframe,
#certModalAPEDA iframe {
    pointer-events: auto;
    user-select: none;
}

#certModal *,
#certModalFSSAI *,
#certModalIEC *,
#certModalAPEDA * {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
}

/* ========================================
   FOOTER
   ======================================== */
footer img {
    transition: transform 0.3s ease;
}

footer img:hover {
    transform: scale(1.05);
}

footer a {
    position: relative;
    transition: color 0.3s ease;
}

footer a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -2px;
    left: 0;
    background-color: #C8A951;
    transition: width 0.3s ease;
}

footer a:hover::after {
    width: 100%;
}

/* ========================================
   UTILITY CLASSES
   ======================================== */
.loading {
    pointer-events: none;
    opacity: 0.6;
}

.spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #C8A951;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-primary {
    background-color: #C8A951;
    color: white;
}

.badge-secondary {
    background-color: #2F7D32;
    color: white;
}

.gradient-text {
    background: linear-gradient(135deg, #C8A951 0%, #2F7D32 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ========================================
   SCROLLBAR
   ======================================== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #C8A951;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #B39641;
}

::selection {
    background-color: #C8A951;
    color: white;
}

::-moz-selection {
    background-color: #C8A951;
    color: white;
}

/* ========================================
   ACCESSIBILITY
   ======================================== */
:focus-visible {
    outline: 3px solid #C8A951;
    outline-offset: 3px;
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .fade-in {
        transition: none;
        opacity: 1;
        transform: none;
    }
}

@media (prefers-contrast: high) {

    .btn-primary,
    .btn-secondary {
        border: 2px solid currentColor;
    }
}

/* ========================================
   MOBILE RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
    .hero-slider-container {
        height: calc(100vh - 3.5rem) !important;
    }

    .hero-slider-container .text-center {
        padding: 0 1rem;
    }

    .hero-slider-container h2 {
        font-size: 1.5rem !important;
        line-height: 1.3;
        margin-bottom: 0.75rem;
    }

    .hero-slider-container p {
        font-size: 0.875rem !important;
        line-height: 1.4;
        margin-bottom: 1rem;
    }

    .hero-slider-container .btn-primary,
    .hero-slider-container .btn-outline,
    .hero-slider-container .btn-secondary {
        padding: 0.625rem 1.25rem;
        font-size: 0.875rem;
        width: 100%;
        max-width: 280px;
        margin: 0 auto;
    }

    .hero-slider-container .slider-dots {
        bottom: 1.5rem;
        gap: 0.5rem;
    }

    .hero-slider-container .slider-dot {
        width: 0.625rem;
        height: 0.625rem;
    }

    .hero-slider-container .slider-dot.active {
        transform: scale(1.3);
    }
}

@media (max-width: 375px) {
    .hero-slider-container h2 {
        font-size: 1.25rem !important;
    }

    .hero-slider-container p {
        font-size: 0.8rem !important;
    }

    .hero-slider-container .btn-primary,
    .hero-slider-container .btn-outline {
        font-size: 0.8rem;
        padding: 0.5rem 1rem;
    }

    nav span {
        font-size: 0.75rem;
    }
}

@media (min-width: 641px) and (max-width: 1024px) {
    .hero-slider-container h2 {
        font-size: 2.5rem !important;
    }

    .hero-slider-container p {
        font-size: 1.125rem !important;
    }
}

/* ========================================
   PRINT STYLES
   ======================================== */
@media print {

    nav,
    footer,
    .slider-btn,
    .slider-dots,
    button,
    #certModal,
    #certModalFSSAI,
    #certModalIEC,
    #certModalAPEDA {
        display: none !important;
    }

    body {
        background: white;
        color: black;
    }

    .fade-in {
        opacity: 1 !important;
        transform: none !important;
    }
}

/* Floating contact buttons */
#floating-contact { position: fixed; right: 18px; bottom: 24px; z-index: 55; display: flex; flex-direction: column; gap: 12px; }
.floating-btn { display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 9999px; box-shadow: 0 6px 18px rgba(15,23,42,0.15); text-decoration: none; color: #fff; transition: transform 160ms ease, box-shadow 160ms ease; }
.floating-btn:focus { outline: 3px solid rgba(200,169,81,0.25); outline-offset: 3px; }
.floating-btn:hover { transform: translateY(-4px); box-shadow: 0 10px 26px rgba(15,23,42,0.18); }

/* WhatsApp */
.floating-wa { background: #25D366; }
.floating-wa svg { width: 22px; height: 22px; }

/* Call */
.floating-call { background: #0EA5A0; } /* teal */
.floating-call svg { width: 20px; height: 20px; }

/* Responsive: reduce size on small screens */
@media (max-width: 420px) {
  .floating-btn { width: 46px; height: 46px; }
  #floating-contact { right: 12px; bottom: 18px; gap: 10px; }
}

/* Fallback modal styles */
.contact-fallback { background: rgba(0,0,0,0.45); }
.contact-fallback .bg-white { border-radius: 12px; }

/* Hide Back to Top Button */
button[aria-label="Back to top"] {
    display: none !important;
}
