/* ==========================================
   PIC SUPERMERCATS DE LA CARN
   Corporate Website Styles
   ========================================== */

/* ---------- Reset & Base ---------- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Barlow', sans-serif;
    font-weight: 400;
    line-height: 1.6;
    color: var(--black);
    background: var(--white);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s;
}

ul {
    list-style: none;
}

/* ---------- CSS Variables ---------- */
:root {
    --red: #C41E1E;
    --red-dark: #9B1717;
    --red-light: rgba(196, 30, 30, 0.08);
    --black: #1A1A1A;
    --black-soft: #2D2D2D;
    --white: #FFFFFF;
    --off-white: #F7F4F1;
    --gray: #6B6B6B;
    --gray-light: #E8E8E8;
    --whatsapp: #25D366;
    --whatsapp-dark: #1DA851;

    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.16);

    --radius: 4px;
    --radius-lg: 8px;

    --header-height: 80px;
    --container: 1200px;
    --container-narrow: 800px;
}

/* ---------- Typography ---------- */
.section-tag {
    display: inline-block;
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 700;
    font-size: 0.875rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--red);
    margin-bottom: 0.75rem;
}

.section-tag--light {
    color: rgba(255, 255, 255, 0.7);
}

.section-title {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 900;
    font-size: clamp(2rem, 5vw, 3rem);
    text-transform: uppercase;
    letter-spacing: 0.02em;
    line-height: 1.1;
    color: var(--black);
    margin-bottom: 1.5rem;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--red);
    margin-top: 0.75rem;
}

.section-title--light {
    color: var(--white);
}

.section-title--center {
    text-align: center;
}

.section-title--center::after {
    margin-left: auto;
    margin-right: auto;
}

/* ---------- Layout ---------- */
.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 0.875rem 2rem;
    border: 2px solid transparent;
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    line-height: 1.2;
}

.btn--primary {
    background: var(--red);
    color: var(--white);
    border-color: var(--red);
}

.btn--primary:hover {
    background: var(--red-dark);
    border-color: var(--red-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn--outline {
    background: transparent;
    color: var(--white);
    border-color: var(--white);
}

.btn--outline:hover {
    background: var(--white);
    color: var(--black);
    transform: translateY(-2px);
}

.btn--whatsapp {
    background: var(--whatsapp);
    color: var(--white);
    border-color: var(--whatsapp);
}

.btn--whatsapp:hover {
    background: var(--whatsapp-dark);
    border-color: var(--whatsapp-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn--dark-outline {
    background: transparent;
    color: var(--black);
    border-color: var(--black);
}

.btn--dark-outline:hover {
    background: var(--black);
    color: var(--white);
    transform: translateY(-2px);
}

/* ---------- Header ---------- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: var(--white);
    z-index: 1000;
    transition: box-shadow 0.3s ease;
}

.header--scrolled {
    box-shadow: var(--shadow-sm);
}

.header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.header__logo img {
    max-height: 50px;
    max-width: 200px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.header__menu {
    display: flex;
    gap: 2rem;
}

.header__link {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--black);
    position: relative;
    padding: 0.5rem 0;
}

.header__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--red);
    transition: width 0.3s ease;
}

.header__link:hover::after,
.header__link.active::after {
    width: 100%;
}

.header__link:hover {
    color: var(--red);
}

.header__link.active {
    color: var(--red);
}

.header__toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.header__toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--black);
    transition: all 0.3s ease;
    transform-origin: center;
}

.header__toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.header__toggle.active span:nth-child(2) {
    opacity: 0;
}

.header__toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    min-height: 75vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: var(--black);
}

.hero__bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero__bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
}

.hero__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(26, 26, 26, 0.3) 0%,
        rgba(26, 26, 26, 0.5) 50%,
        rgba(26, 26, 26, 0.75) 100%
    );
    z-index: 1;
}

.hero__content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white);
    padding: calc(var(--header-height) + 2rem) 1.5rem 4rem;
}

.hero__title {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 900;
    font-size: clamp(2.5rem, 8vw, 5rem);
    text-transform: uppercase;
    line-height: 1.05;
    letter-spacing: 0.02em;
    margin-bottom: 1.25rem;
    text-shadow: 0 2px 30px rgba(0, 0, 0, 0.4);
}

.hero__subtitle {
    font-size: clamp(1rem, 2.5vw, 1.35rem);
    font-weight: 500;
    opacity: 0.9;
    margin-bottom: 2.5rem;
    letter-spacing: 0.02em;
}

.hero__buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Red bottom accent on hero */
.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: var(--red);
    z-index: 3;
}

/* ---------- Qué Ofrecemos ---------- */
.ofrecemos {
    padding: 6rem 0;
    background: var(--white);
}

.ofrecemos__inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.ofrecemos__image {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.ofrecemos__image::after {
    content: '';
    position: absolute;
    top: -10px;
    right: -10px;
    width: 100%;
    height: 100%;
    border: 3px solid var(--red);
    border-radius: var(--radius-lg);
    z-index: -1;
}

.ofrecemos__image img {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
}

.ofrecemos__list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 0.5rem;
}

.ofrecemos__list li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--black-soft);
    line-height: 1.5;
}

.ofrecemos__list li::before {
    content: '';
    flex-shrink: 0;
    width: 8px;
    height: 8px;
    background: var(--red);
    border-radius: 50%;
    margin-top: 0.55rem;
}

/* ---------- Hostelería ---------- */
.hosteleria {
    padding: 7rem 0;
    background: var(--black);
    position: relative;
    overflow: hidden;
}

.hosteleria::before {
    content: '';
    position: absolute;
    top: -30px;
    left: 0;
    width: 100%;
    height: 60px;
    background: var(--white);
    transform: skewY(-2deg);
    z-index: 1;
}

.hosteleria::after {
    content: '';
    position: absolute;
    bottom: -30px;
    left: 0;
    width: 100%;
    height: 60px;
    background: var(--off-white);
    transform: skewY(-2deg);
    z-index: 1;
}

.hosteleria__inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hosteleria__content {
    color: var(--white);
}

.hosteleria__text {
    font-size: 1.15rem;
    line-height: 1.8;
    opacity: 0.85;
    margin-bottom: 2rem;
}

.hosteleria__image {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.hosteleria__image img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

/* ---------- Nosotros ---------- */
.nosotros {
    padding: 6rem 0;
    background: var(--off-white);
    background-image: radial-gradient(circle, rgba(0, 0, 0, 0.025) 1px, transparent 1px);
    background-size: 24px 24px;
}

.nosotros__inner {
    max-width: var(--container-narrow);
    margin: 0 auto;
}

.nosotros__content {
    text-align: center;
}

.nosotros__content .section-title::after {
    margin-left: auto;
    margin-right: auto;
}

.nosotros__content p {
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--gray);
    margin-bottom: 1.25rem;
}

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

/* ---------- Tiendas ---------- */
.tiendas {
    padding: 6rem 0;
    background: var(--white);
}

.tiendas__header {
    text-align: center;
    margin-bottom: 3rem;
}

.tiendas__header .section-title::after {
    margin-left: auto;
    margin-right: auto;
}

.tiendas__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.tienda-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--gray-light);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tienda-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.tienda-card__image {
    position: relative;
    overflow: hidden;
}

.tienda-card__image img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.tienda-card:hover .tienda-card__image img {
    transform: scale(1.03);
}

.tienda-card__image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--red);
}

.tienda-card__body {
    padding: 1.5rem;
}

.tienda-card__name {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 800;
    font-size: 1.35rem;
    text-transform: uppercase;
    color: var(--black);
    margin-bottom: 1rem;
}

.tienda-card__address,
.tienda-card__phone {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.95rem;
    color: var(--gray);
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.tienda-card__address svg,
.tienda-card__phone svg {
    flex-shrink: 0;
    margin-top: 2px;
    color: var(--red);
}

.tienda-card__phone a {
    color: var(--red);
    font-weight: 600;
}

.tienda-card__phone a:hover {
    text-decoration: underline;
}

.tienda-card__hours {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--gray);
    padding-top: 0.75rem;
    border-top: 1px solid var(--gray-light);
}

.tienda-card__hours svg {
    flex-shrink: 0;
    margin-top: 3px;
    color: var(--red);
}

.tienda-card__hours p {
    line-height: 1.6;
}

/* ---------- Ofertas ---------- */
.ofertas {
    padding: 5rem 0;
    background: var(--red);
    position: relative;
    overflow: hidden;
}

.ofertas::before {
    content: '';
    position: absolute;
    top: -30px;
    left: 0;
    width: 100%;
    height: 60px;
    background: var(--white);
    transform: skewY(2deg);
    z-index: 1;
}

.ofertas__inner {
    text-align: center;
    position: relative;
    z-index: 2;
}

.ofertas__inner .section-title {
    color: var(--white);
}

.ofertas__inner .section-title::after {
    background: var(--white);
    margin-left: auto;
    margin-right: auto;
}

.ofertas__text {
    font-size: 1.15rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin: 0 auto 2rem;
    line-height: 1.7;
}

.ofertas .btn--outline {
    border-color: var(--white);
    color: var(--white);
}

.ofertas .btn--outline:hover {
    background: var(--white);
    color: var(--red);
}

/* ---------- Footer ---------- */
.footer {
    background: var(--black);
    color: var(--white);
    padding-top: 4rem;
}

.footer__inner {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer__logo {
    max-width: 220px;
    width: auto;
    height: auto;
    margin-bottom: 1rem;
    border-radius: var(--radius);
    object-fit: contain;
}

.footer__slogan {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    opacity: 0.5;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.footer__contact h3,
.footer__hours h3 {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
    color: var(--red);
}

.footer__contact p,
.footer__hours p {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
    opacity: 0.7;
    margin-bottom: 0.5rem;
}

.footer__contact a:hover {
    color: var(--red);
    opacity: 1;
}

.footer__contact svg {
    flex-shrink: 0;
    opacity: 0.5;
}

.footer__note {
    font-size: 0.85rem !important;
    font-style: italic;
    opacity: 0.4 !important;
    margin-top: 0.5rem;
}

.footer__bottom {
    padding: 1.5rem 0;
}

.footer__bottom p {
    font-size: 0.85rem;
    opacity: 0.4;
    text-align: center;
}

/* ---------- Scroll Reveal Animations ---------- */
[data-reveal] {
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

[data-reveal="up"] {
    transform: translateY(40px);
}

[data-reveal="left"] {
    transform: translateX(-40px);
}

[data-reveal="right"] {
    transform: translateX(40px);
}

[data-reveal="fade"] {
    transform: none;
}

[data-reveal].revealed {
    opacity: 1;
    transform: translate(0, 0);
}

[data-delay="1"] {
    transition-delay: 0.15s;
}

[data-delay="2"] {
    transition-delay: 0.3s;
}

[data-delay="3"] {
    transition-delay: 0.45s;
}

/* ---------- Mobile Navigation Overlay ---------- */
.nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.nav-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ---------- Responsive: Tablet ---------- */
@media (max-width: 1024px) {
    .tiendas__grid {
        grid-template-columns: 1fr 1fr;
    }

    .tiendas__grid .tienda-card:last-child {
        grid-column: 1 / -1;
        max-width: 500px;
        justify-self: center;
    }

    .footer__inner {
        grid-template-columns: 1fr 1fr;
    }

    .footer__brand {
        grid-column: 1 / -1;
    }
}

/* ---------- Responsive: Mobile ---------- */
@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }

    html {
        scroll-padding-top: 70px;
    }

    .header__toggle {
        display: flex;
    }

    .header__nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        height: 100dvh;
        background: var(--white);
        box-shadow: var(--shadow-lg);
        transition: right 0.3s ease;
        z-index: 1000;
        padding-top: calc(var(--header-height) + 2rem);
    }

    .header__nav.open {
        right: 0;
    }

    .header__menu {
        flex-direction: column;
        padding: 0 2rem;
        gap: 0;
    }

    .header__link {
        display: block;
        padding: 1rem 0;
        border-bottom: 1px solid var(--gray-light);
        font-size: 1.1rem;
    }

    .header__link::after {
        display: none;
    }

    .ofrecemos {
        padding: 4rem 0;
    }

    .ofrecemos__inner {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .ofrecemos__image {
        order: -1;
        max-width: 400px;
        margin: 0 auto;
    }

    .ofrecemos__image::after {
        display: none;
    }

    .ofrecemos__image img {
        aspect-ratio: 1 / 1;
    }

    .hosteleria {
        padding: 5rem 0;
    }

    .hosteleria__inner {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .hosteleria__image {
        order: -1;
    }

    .nosotros {
        padding: 4rem 0;
    }

    .tiendas {
        padding: 4rem 0;
    }

    .tiendas__grid {
        grid-template-columns: 1fr;
        max-width: 500px;
        margin: 0 auto;
    }

    .tiendas__grid .tienda-card:last-child {
        max-width: none;
    }

    .ofertas {
        padding: 4rem 0;
    }

    .footer__inner {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .footer__logo {
        margin: 0 auto 1rem;
    }

    .footer__contact p,
    .footer__hours p {
        justify-content: center;
    }

    .hero__title {
        font-size: clamp(2rem, 10vw, 3.5rem);
    }

    .hero__content {
        padding: calc(var(--header-height) + 1rem) 1rem 3rem;
    }
}

/* ---------- Responsive: Small Mobile ---------- */
@media (max-width: 400px) {
    .hero__buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .hero__title {
        font-size: 2rem;
    }
}
