/* ==========================================================================
   CREAPAN FOOD SERVICE - CUSTOM STYLES
   ========================================================================== */

/* Font Family Declarations */
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_ExtraLight.woff2') format('woff2');
    font-weight: 200;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_ExtraLight_Italic.woff2') format('woff2');
    font-weight: 200;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_Light.woff2') format('woff2');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_Light_Italic.woff2') format('woff2');
    font-weight: 300;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_Italic.woff2') format('woff2');
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-Kit_Rounded_Medium.woff2') format('woff2');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-Kit_Rounded_Medium_Italic.woff2') format('woff2');
    font-weight: 500;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_SemiBold.woff2') format('woff2');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_SemiBold_Italic.woff2') format('woff2');
    font-weight: 600;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_Bold.woff2') format('woff2');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_Bold_Italic.woff2') format('woff2');
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_ExtraBold.woff2') format('woff2');
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_ExtraBold_Italic.woff2') format('woff2');
    font-weight: 800;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_Black.woff2') format('woff2');
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'KitRounded';
    src: url('../images/fonts/fonnts.com-KitRounded_Black_Italic.woff2') format('woff2');
    font-weight: 900;
    font-style: italic;
    font-display: swap;
}

/* Base Styles & Custom Tailwind Utilities */
:root {
    --color-primary: #d32f2f; /* Red tone */
    --color-primary-dark: #b71c1c;
    --color-secondary: #4fc3f7; /* Light blue accent */
    --color-bg-light: #fdfaf6; /* Light cream */
    --color-text-dark: #2a2a2a;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    max-width: 100%;
}

body {
    font-family: 'KitRounded', system-ui, -apple-system, sans-serif;
    color: var(--color-text-dark);
    background-color: var(--color-bg-light);
    overflow-x: hidden;
    max-width: 100%;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: #f1f1f1;
}
::-webkit-scrollbar-thumb {
    background: #d32f2f;
    border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
    background: #b71c1c;
}

/* Splashscreen Loader */
#splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

#splash-screen.fade-out {
    opacity: 0;
    visibility: hidden;
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid #d32f2f;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-top: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Parallax Sections & Elements */
.parallax-bg {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* Fallback for iOS / Mobile Devices which handle background-attachment: fixed poorly */
@media (max-width: 1024px) {
    .parallax-bg {
        background-attachment: scroll !important;
    }
}

/* Floating Cookies & Almonds Parallax Container */
.parallax-floating-container {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 30;
}

.parallax-floating-item {
    position: absolute;
    transition: transform 0.1s ease-out;
    will-change: transform;
}

/* Waves/Scallops Separators */
.wave-separator-red {
    background-image: url('../images/patron-rojo.webp');
    background-repeat: repeat-x;
    height: 25px;
    width: 100%;
}

.wave-separator-light {
    background-image: url('../images/patron-clarito.webp');
    background-repeat: repeat-x;
    height: 25px;
    width: 100%;
}

/* Scroll Animations CSS */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

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

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

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

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

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

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

/* Delay modifiers */
.delay-100 { transition-delay: 100ms; }
.delay-200 { transition-delay: 200ms; }
.delay-300 { transition-delay: 300ms; }
.delay-400 { transition-delay: 400ms; }
.delay-500 { transition-delay: 500ms; }

/* Custom Wave Transition Mask or Overlay */
.scalloped-divider-top {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 20px;
    background: url('../images/patron-rojo.webp') repeat-x bottom;
    background-size: auto 20px;
    z-index: 20;
}

.scalloped-divider-bottom {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 20px;
    background: url('../images/patron-rojo.webp') repeat-x top;
    background-size: auto 20px;
    z-index: 20;
    transform: rotate(180deg);
}

.scalloped-divider-light-bottom {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 20px;
    background: url('../images/patron-clarito.webp') repeat-x top;
    background-size: auto 20px;
    z-index: 20;
    transform: rotate(180deg);
}

/* Styles for Floating Contact Form Success Notification */
.form-success-toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background-color: #4caf50;
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    font-weight: 600;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.form-success-toast.show {
    transform: translateX(-50%) translateY(0);
}

/* Custom Brands Row Animation */
.brands-slider {
    display: flex;
    width: calc(250px * 14 * 2);
    animation: scrollBrands 40s linear infinite;
}

@keyframes scrollBrands {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-250px * 14)); }
}

.brands-slider:hover {
    animation-play-state: paused;
}
