/* ========================================
   PIEDRALIS.COM — Design System
   Based on Brand Book v2.0
   ======================================== */

/* === TOKENS === */
:root {
    --color-primary: #2C2825;
    --color-secondary: #8B7355;
    --color-stone: #C4B5A0;
    --color-cream: #F5F0E8;
    --color-accent: #5E7258;
    --color-marble: #A09080;
    --color-white: #FEFDFB;
    --color-dark: #1A1816;

    --font-display: 'Outfit', sans-serif;
    --font-heading: 'Cormorant Garamond', serif;
    --font-body: 'DM Sans', sans-serif;

    --ease: cubic-bezier(0.16, 1, 0.3, 1);
    --shadow-soft: 0 4px 24px rgba(44, 40, 37, 0.06);
    --shadow-medium: 0 8px 40px rgba(44, 40, 37, 0.1);
    --shadow-strong: 0 16px 56px rgba(44, 40, 37, 0.14);
    --radius: 2px;
}

/* === RESET === */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
    font-family: var(--font-body);
    color: var(--color-primary);
    background: var(--color-cream);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 2rem; }
.container--narrow { max-width: 800px; }

/* === NAVIGATION === */
.nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    display: flex; align-items: center; justify-content: space-between;
    padding: 1.2rem 3rem;
    background: transparent;
    transition: all 0.5s var(--ease);
}
.nav--scrolled {
    padding: 0.7rem 3rem;
    background: rgba(245, 240, 232, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(44, 40, 37, 0.05);
    box-shadow: var(--shadow-soft);
}

.nav__logo {
    display: flex; align-items: center; gap: 0.6rem;
}
.nav__logo-icon {
    width: 32px; height: 29px; transition: transform 0.3s var(--ease);
}
.nav__logo:hover .nav__logo-icon { transform: scale(1.05); }
.nav__logo-text {
    font-family: var(--font-display); font-weight: 300;
    font-size: 0.85rem; letter-spacing: 0.3em;
    color: var(--color-cream);
    transition: color 0.5s var(--ease);
}
.nav--scrolled .nav__logo-text { color: var(--color-primary); }

.nav__links { display: flex; align-items: center; gap: 2rem; }
.nav__link {
    font-size: 0.68rem; font-weight: 500; letter-spacing: 0.08em;
    text-transform: uppercase; color: rgba(245, 240, 232, 0.6);
    transition: all 0.3s ease; position: relative;
}
.nav__link::after {
    content: ''; position: absolute; bottom: -4px; left: 0;
    width: 0; height: 1px; background: var(--color-secondary);
    transition: width 0.4s var(--ease);
}
.nav__link:hover { color: var(--color-cream); }
.nav__link:hover::after { width: 100%; }
.nav__link--active { color: var(--color-cream); }
.nav__link--active::after { width: 100%; }

.nav--scrolled .nav__link { color: rgba(44, 40, 37, 0.45); }
.nav--scrolled .nav__link:hover { color: var(--color-primary); }
.nav--scrolled .nav__link--active { color: var(--color-primary); }

.nav__cta {
    font-size: 0.62rem; font-weight: 600; letter-spacing: 0.1em;
    text-transform: uppercase; padding: 0.55rem 1.4rem;
    border: 1px solid rgba(245, 240, 232, 0.3);
    color: var(--color-cream);
    transition: all 0.3s var(--ease);
}
.nav__cta:hover {
    background: var(--color-secondary); border-color: var(--color-secondary);
    color: var(--color-cream);
}
.nav--scrolled .nav__cta {
    border-color: var(--color-secondary); color: var(--color-secondary);
}
.nav--scrolled .nav__cta:hover {
    background: var(--color-secondary); color: var(--color-cream);
}

/* Mobile menu */
.nav__hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: 4px; }
.nav__hamburger span {
    width: 22px; height: 1.5px; background: var(--color-cream);
    transition: all 0.3s var(--ease);
}
.nav--scrolled .nav__hamburger span { background: var(--color-primary); }

/* === HERO === */
.hero {
    min-height: 100vh; position: relative;
    display: flex; align-items: center; justify-content: center;
    background: var(--color-dark); color: var(--color-cream);
    overflow: hidden;
}
.hero__bg {
    position: absolute; inset: 0; z-index: 0;
    background-size: cover; background-position: center;
    filter: brightness(0.35) contrast(1.1);
}
.hero__overlay {
    position: absolute; inset: 0; z-index: 1;
    background:
        linear-gradient(180deg, rgba(26,24,22,0.5) 0%, rgba(26,24,22,0.2) 40%, rgba(26,24,22,0.7) 100%),
        radial-gradient(ellipse at 30% 60%, rgba(139,115,85,0.08) 0%, transparent 60%);
}
/* Noise texture */
.hero::after {
    content: ''; position: absolute; inset: 0; z-index: 1;
    opacity: 0.025;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.hero__content {
    position: relative; z-index: 2; text-align: center;
    max-width: 720px; padding: 0 2rem;
    animation: heroFadeUp 1.4s var(--ease) both;
}
.hero__eyebrow {
    font-size: 0.6rem; font-weight: 600; letter-spacing: 0.35em;
    text-transform: uppercase; color: var(--color-secondary);
    margin-bottom: 1.8rem;
    animation: heroFadeUp 1.4s var(--ease) 0.2s both;
}
.hero__title {
    font-family: var(--font-heading); font-weight: 300;
    font-size: clamp(2.4rem, 5vw, 3.8rem);
    line-height: 1.2; letter-spacing: -0.01em;
    margin-bottom: 1.5rem;
    animation: heroFadeUp 1.4s var(--ease) 0.3s both;
}
.hero__line {
    width: 48px; height: 1px; background: var(--color-secondary);
    margin: 0 auto 1.5rem;
    animation: expandLine 1.6s var(--ease) 0.6s both;
}
.hero__subtitle {
    font-size: 0.95rem; font-weight: 300; line-height: 1.8;
    color: var(--color-stone); max-width: 480px; margin: 0 auto 2.5rem;
    animation: heroFadeUp 1.4s var(--ease) 0.5s both;
}
.hero__actions {
    display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap;
    animation: heroFadeUp 1.4s var(--ease) 0.7s both;
}

.hero__scroll {
    position: absolute; bottom: 2.5rem; left: 50%; transform: translateX(-50%);
    z-index: 2; display: flex; flex-direction: column; align-items: center; gap: 0.6rem;
    animation: heroFadeUp 1.4s var(--ease) 1s both;
}
.hero__scroll span {
    font-size: 0.55rem; font-weight: 500; letter-spacing: 0.25em;
    text-transform: uppercase; color: var(--color-stone); opacity: 0.4;
}
.hero__scroll-line {
    width: 1px; height: 36px;
    background: linear-gradient(to bottom, var(--color-secondary), transparent);
    animation: pulse 2.5s ease-in-out infinite;
}

/* === BUTTONS === */
.btn {
    display: inline-flex; align-items: center; gap: 0.6rem;
    font-size: 0.65rem; font-weight: 600; letter-spacing: 0.12em;
    text-transform: uppercase; padding: 0.9rem 2rem;
    transition: all 0.4s var(--ease); position: relative; overflow: hidden;
}
.btn--primary {
    background: var(--color-secondary); color: var(--color-cream);
    border: 1px solid var(--color-secondary);
}
.btn--primary:hover {
    background: #9D8465; border-color: #9D8465;
    transform: translateY(-2px); box-shadow: 0 6px 20px rgba(139,115,85,0.25);
}
.btn--outline {
    background: transparent; color: var(--color-cream);
    border: 1px solid rgba(245, 240, 232, 0.3);
}
.btn--outline:hover {
    background: rgba(245, 240, 232, 0.08);
    border-color: rgba(245, 240, 232, 0.5);
}
.btn--dark {
    background: var(--color-primary); color: var(--color-cream);
    border: 1px solid var(--color-primary);
}
.btn--dark:hover {
    background: #3D3835; border-color: #3D3835;
    transform: translateY(-2px); box-shadow: var(--shadow-medium);
}
.btn--whatsapp {
    background: #25D366; color: white; border: 1px solid #25D366;
}
.btn--whatsapp:hover {
    background: #20BD5A; transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
}

/* === SECTIONS === */
.section { padding: 7rem 0; }
.section--dark { background: var(--color-dark); color: var(--color-cream); }
.section--stone { background: var(--color-primary); color: var(--color-cream); }
.section--cream { background: var(--color-cream); }
.section--white { background: var(--color-white); }

.section__header { text-align: center; margin-bottom: 4rem; }
.section__eyebrow {
    display: inline-block; font-size: 0.6rem; font-weight: 600;
    letter-spacing: 0.25em; text-transform: uppercase;
    color: var(--color-secondary); margin-bottom: 1rem;
}
.section__title {
    font-family: var(--font-heading); font-weight: 300;
    font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.01em;
    margin-bottom: 0.8rem;
}
.section__subtitle {
    font-size: 0.9rem; font-weight: 300; opacity: 0.55;
    max-width: 520px; margin: 0 auto; line-height: 1.8;
}

/* === VALUE PROPS (3 cols) === */
.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: rgba(44,40,37,0.06); }
.value {
    background: var(--color-cream); padding: 3rem 2rem; text-align: center;
    transition: all 0.4s var(--ease);
}
.value:hover { background: var(--color-white); transform: translateY(-2px); }
.value__icon {
    font-size: 1.6rem; margin-bottom: 1.2rem; color: var(--color-secondary);
    font-family: var(--font-heading); font-weight: 300;
}
.value__title {
    font-family: var(--font-heading); font-weight: 600;
    font-size: 1.15rem; margin-bottom: 0.5rem;
}
.value__text { font-size: 0.82rem; opacity: 0.55; line-height: 1.7; }

/* === PRODUCT GRID === */
.products-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem;
}
.product-card {
    position: relative; overflow: hidden; cursor: pointer;
    border: 1px solid rgba(44,40,37,0.06);
    transition: all 0.5s var(--ease);
}
.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-strong);
    border-color: transparent;
}
.product-card__img {
    width: 100%; aspect-ratio: 1; object-fit: cover;
    transition: transform 0.8s var(--ease);
}
.product-card:hover .product-card__img { transform: scale(1.05); }
.product-card__overlay {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, transparent 50%, rgba(26,24,22,0.75) 100%);
    display: flex; flex-direction: column; justify-content: flex-end;
    padding: 1.5rem; opacity: 0; transition: opacity 0.4s var(--ease);
}
.product-card:hover .product-card__overlay { opacity: 1; }
.product-card__name {
    font-family: var(--font-heading); font-weight: 400;
    font-size: 1.15rem; color: var(--color-cream); margin-bottom: 0.2rem;
}
.product-card__meta {
    font-size: 0.68rem; font-weight: 500; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--color-stone);
}
.product-card__info {
    padding: 1.2rem 1.5rem; background: var(--color-white);
}
.product-card__info-name {
    font-family: var(--font-heading); font-weight: 600;
    font-size: 1.05rem; margin-bottom: 0.15rem;
}
.product-card__info-detail {
    font-size: 0.72rem; color: var(--color-secondary);
    font-weight: 500; margin-bottom: 0.3rem;
}
.product-card__info-price {
    font-size: 0.78rem; font-weight: 300; opacity: 0.5;
}
.product-card__badge {
    position: absolute; top: 1rem; left: 1rem;
    font-size: 0.55rem; font-weight: 600; letter-spacing: 0.1em;
    text-transform: uppercase; padding: 0.3rem 0.7rem;
    background: var(--color-secondary); color: var(--color-cream);
    z-index: 2;
}

/* === PARALLAX QUOTE === */
.parallax {
    position: relative; padding: 8rem 0; overflow: hidden;
    background: var(--color-primary); color: var(--color-cream);
}
.parallax::before {
    content: ''; position: absolute; inset: 0;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.parallax__content {
    position: relative; z-index: 1; text-align: center;
    max-width: 680px; margin: 0 auto; padding: 0 2rem;
}
.parallax__quote {
    font-family: var(--font-heading); font-weight: 300;
    font-style: italic; font-size: clamp(1.3rem, 3vw, 1.8rem);
    line-height: 1.8; margin-bottom: 1.5rem;
}
.parallax__cite {
    font-family: var(--font-body); font-style: normal;
    font-size: 0.65rem; font-weight: 600; letter-spacing: 0.2em;
    text-transform: uppercase; color: var(--color-secondary);
}
.parallax__line {
    width: 40px; height: 1px; background: var(--color-secondary);
    margin: 0 auto 1.5rem; opacity: 0.5;
}

/* === PROCESS STEPS === */
.process { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.process__step { text-align: center; position: relative; padding: 2rem 1.5rem; }
.process__step::after {
    content: '→'; position: absolute; right: -1rem; top: 50%;
    transform: translateY(-50%); font-size: 1.2rem; color: var(--color-stone); opacity: 0.3;
}
.process__step:last-child::after { display: none; }
.process__num {
    font-family: var(--font-display); font-weight: 200;
    font-size: 2.5rem; letter-spacing: 0.1em; color: var(--color-secondary);
    opacity: 0.3; margin-bottom: 1rem;
}
.process__title {
    font-family: var(--font-heading); font-weight: 600;
    font-size: 1.15rem; margin-bottom: 0.6rem;
}
.process__text { font-size: 0.82rem; opacity: 0.55; line-height: 1.7; }

/* === TRUST === */
.trust { text-align: center; }
.trust__badges {
    display: flex; justify-content: center; gap: 3rem; flex-wrap: wrap;
    margin-bottom: 2rem;
}
.trust__badge {
    display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
}
.trust__badge-icon {
    font-size: 1.5rem; color: var(--color-secondary); opacity: 0.6;
}
.trust__badge-text {
    font-size: 0.7rem; font-weight: 500; letter-spacing: 0.08em;
    text-transform: uppercase; opacity: 0.45;
}

/* === CTA SECTION === */
.cta-section {
    background: var(--color-primary); color: var(--color-cream);
    padding: 5rem 0; text-align: center;
}
.cta-section__title {
    font-family: var(--font-heading); font-weight: 300;
    font-size: clamp(1.8rem, 3.5vw, 2.5rem); margin-bottom: 0.6rem;
}
.cta-section__subtitle {
    font-size: 0.85rem; opacity: 0.5; margin-bottom: 2rem;
    max-width: 420px; margin-left: auto; margin-right: auto;
}

/* === FOOTER === */
.footer {
    background: var(--color-dark); color: var(--color-cream);
    padding: 4rem 0 2rem;
}
.footer__top {
    display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 3rem;
    padding-bottom: 3rem; border-bottom: 1px solid rgba(245,240,232,0.06);
}
.footer__brand-text {
    font-size: 0.82rem; opacity: 0.45; line-height: 1.8; margin-top: 1rem;
}
.footer__col-title {
    font-family: var(--font-heading); font-weight: 600;
    font-size: 1rem; margin-bottom: 1.2rem;
}
.footer__links { list-style: none; }
.footer__links li { margin-bottom: 0.5rem; }
.footer__links a {
    font-size: 0.78rem; opacity: 0.4; transition: opacity 0.3s ease;
}
.footer__links a:hover { opacity: 1; color: var(--color-secondary); }
.footer__contact-item {
    font-size: 0.78rem; opacity: 0.45; margin-bottom: 0.5rem;
}
.footer__bottom {
    display: flex; justify-content: space-between; align-items: center;
    padding-top: 2rem;
}
.footer__copy { font-size: 0.65rem; opacity: 0.25; }
.footer__legal { font-size: 0.6rem; opacity: 0.2; }

/* === WHATSAPP FLOAT === */
.whatsapp-float {
    position: fixed; bottom: 2rem; right: 2rem; z-index: 999;
    width: 56px; height: 56px; border-radius: 50%;
    background: #25D366; color: white;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.35);
    transition: all 0.3s var(--ease);
    animation: whatsappPulse 3s ease-in-out infinite;
}
.whatsapp-float:hover {
    transform: scale(1.1); box-shadow: 0 6px 28px rgba(37, 211, 102, 0.45);
}
.whatsapp-float svg { width: 28px; height: 28px; }

/* === CATALOG PAGE === */
.catalog-filters {
    display: flex; justify-content: center; gap: 0.5rem; flex-wrap: wrap;
    margin-bottom: 3rem;
}
.catalog-filter {
    font-size: 0.65rem; font-weight: 600; letter-spacing: 0.1em;
    text-transform: uppercase; padding: 0.55rem 1.3rem;
    border: 1px solid rgba(44,40,37,0.12); color: var(--color-primary);
    transition: all 0.3s var(--ease); cursor: pointer;
    background: transparent;
}
.catalog-filter:hover, .catalog-filter--active {
    background: var(--color-primary); color: var(--color-cream);
    border-color: var(--color-primary);
}
.catalog-disclaimer {
    text-align: center; max-width: 560px; margin: 0 auto 3rem;
    padding: 1.2rem 1.5rem;
    border: 1px dashed var(--color-stone);
    background: rgba(196, 181, 160, 0.08);
}
.catalog-disclaimer p {
    font-size: 0.78rem; line-height: 1.7; opacity: 0.6;
}
.catalog-disclaimer strong { color: var(--color-secondary); font-weight: 600; opacity: 1; }

/* === HISTORIA PAGE === */
.timeline { position: relative; max-width: 700px; margin: 0 auto; }
.timeline::before {
    content: ''; position: absolute; left: 50%; top: 0; bottom: 0;
    width: 1px; background: rgba(44,40,37,0.1);
    transform: translateX(-50%);
}
.timeline__item {
    display: flex; gap: 2rem; margin-bottom: 3rem; align-items: flex-start;
}
.timeline__year {
    flex-shrink: 0; width: 80px; text-align: right;
    font-family: var(--font-display); font-weight: 200;
    font-size: 1.5rem; letter-spacing: 0.1em; color: var(--color-secondary);
    opacity: 0.5; padding-top: 0.3rem;
}
.timeline__dot {
    flex-shrink: 0; width: 10px; height: 10px; border-radius: 50%;
    border: 2px solid var(--color-secondary); background: var(--color-cream);
    margin-top: 0.6rem;
}
.timeline__content { flex: 1; }
.timeline__title {
    font-family: var(--font-heading); font-weight: 600;
    font-size: 1.1rem; margin-bottom: 0.4rem;
}
.timeline__text { font-size: 0.85rem; opacity: 0.6; line-height: 1.7; }

/* === PAGE HERO (interior) === */
.page-hero {
    padding: 10rem 0 4rem; background: var(--color-primary);
    color: var(--color-cream); text-align: center;
}
.page-hero__eyebrow {
    font-size: 0.6rem; font-weight: 600; letter-spacing: 0.3em;
    text-transform: uppercase; color: var(--color-secondary); margin-bottom: 1rem;
}
.page-hero__title {
    font-family: var(--font-heading); font-weight: 300;
    font-size: clamp(2.2rem, 5vw, 3.5rem); margin-bottom: 0.8rem;
}
.page-hero__subtitle {
    font-size: 0.9rem; font-weight: 300; opacity: 0.45;
    max-width: 480px; margin: 0 auto;
}

/* === ANIMATIONS === */
@keyframes heroFadeUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes expandLine {
    from { width: 0; opacity: 0; }
    to { width: 48px; opacity: 1; }
}
@keyframes pulse {
    0%, 100% { opacity: 0.3; transform: scaleY(0.7); }
    50% { opacity: 1; transform: scaleY(1); }
}
@keyframes whatsappPulse {
    0%, 100% { box-shadow: 0 4px 20px rgba(37,211,102,0.35); }
    50% { box-shadow: 0 4px 30px rgba(37,211,102,0.55), 0 0 0 12px rgba(37,211,102,0.08); }
}

.fade-in {
    opacity: 0; transform: translateY(28px);
    transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.fade-in.visible { opacity: 1; transform: translateY(0); }
.fade-in-delay-1 { transition-delay: 0.1s; }
.fade-in-delay-2 { transition-delay: 0.2s; }
.fade-in-delay-3 { transition-delay: 0.3s; }

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .products-grid { grid-template-columns: repeat(2, 1fr); }
    .footer__top { grid-template-columns: 1fr 1fr; gap: 2rem; }
}

@media (max-width: 768px) {
    .nav { padding: 1rem 1.5rem; }
    .nav--scrolled { padding: 0.6rem 1.5rem; }
    .nav__links { display: none; }
    .nav__hamburger { display: flex; }
    .nav__cta { display: none; }

    /* Mobile menu overlay */
    .nav__links--open {
        display: flex !important; flex-direction: column;
        position: fixed; inset: 0;
        background: var(--color-primary); color: var(--color-cream);
        align-items: center; justify-content: center; gap: 2rem;
        z-index: 999;
    }
    .nav__links--open .nav__link {
        font-size: 1rem; color: rgba(245,240,232,0.6);
    }
    .nav__links--open .nav__link:hover { color: var(--color-cream); }

    .section { padding: 4.5rem 0; }
    .hero__title { font-size: clamp(2rem, 7vw, 3rem); }
    .values { grid-template-columns: 1fr; gap: 1px; }
    .products-grid { grid-template-columns: 1fr; }
    .process { grid-template-columns: 1fr; gap: 1rem; }
    .process__step::after { display: none; }
    .footer__top { grid-template-columns: 1fr; gap: 2rem; }
    .footer__bottom { flex-direction: column; gap: 0.5rem; text-align: center; }
    .hero__actions { flex-direction: column; align-items: center; }
    .catalog-filters { gap: 0.4rem; }
    .timeline__item { gap: 1rem; }
    .timeline__year { width: 60px; font-size: 1.1rem; }
}

@media (max-width: 480px) {
    .container { padding: 0 1.2rem; }
    .hero { min-height: 90vh; }
}
