/* ===== CSS Custom Properties ===== */
:root {
    /* Cover / Landing area */
    --cover-text-color: #b2dcf7;
    --highlight: #448ca7;
    --highlight-contrast: #b2dcf7;
    --highlight-inverse: #b2dcf7;
    --highlight-inverse-contrast: white;

    /* Sticky navigation */
    --sticky-menu-text-color: #448ca7;

    /* Light section */
    --section-light-text-color: #3a4145;
    --section-light-bg-color: #f2efe8;

    /* Dark section */
    --section-dark-text-color: #f2efe8;
    --section-dark-bg-color: #448ca7;

    /* Shared */
    --section-uni-quote: grey;
    --section-uni-code-bg-color: #e0ded7;

    /* Footer */
    --footer-color-background: #22343a;
    --footer-color: #bbc7cc;

    /* Dynamic variables */
    --color-text: var(--section-light-text-color);
    --color-background: var(--section-light-bg-color);
}

/* ===== CSS Reset / Normalize ===== */
*, *::before, *::after {
    box-sizing: border-box;
}

/* ===== Base Styles ===== */
html {
    height: 100%;
    max-height: 100%;
    font-size: 62.5%;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    height: 100%;
    max-height: 100%;
    font-family: "Proza Libre", sans-serif;
    font-size: 1.9rem;
    line-height: 1.7em;
    color: var(--section-light-text-color);
    font-weight: 400;
}

::selection {
    color: #222;
    background: #d6edff;
    text-shadow: none;
}

/* ===== Typography ===== */
h1, h2, h3, h4, h5, h6 {
    text-rendering: optimizeLegibility;
    line-height: 1.1;
    margin-top: 0;
    margin-bottom: 0.5em;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 600;
    letter-spacing: 0.01em;
}

h1 {
    font-size: 5rem;
    line-height: 1.15em;
    font-weight: 500;
}

h2 {
    font-size: 3.8rem;
    line-height: 1.2em;
    font-weight: 600;
}

h3 {
    font-size: 3.2rem;
    line-height: 1.25em;
}

h4 {
    font-size: 2.8rem;
    line-height: 1.3em;
}

h5 {
    font-size: 2.4rem;
}

h6 {
    font-size: 2rem;
}

p {
    margin: 1.2em 0;
}

a {
    color: inherit;
    transition: all ease 0.3s;
}

a:hover {
    color: var(--sticky-menu-text-color);
}

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

/* ===== Header / Hero Section ===== */
#site-head {
    position: relative;
    display: table;
    width: 100%;
    height: 100vh;
    margin-bottom: 0;
    text-align: center;
    color: #fff;
    background: #000;
    overflow: hidden;
}

#site-head video {
    position: absolute;
    top: 0;
    left: 0;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    object-fit: cover;
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.4) 0%,
        rgba(0, 0, 0, 0.2) 40%,
        rgba(0, 0, 0, 0.3) 100%
    );
    z-index: 2;
}

#site-head .vertical {
    display: table-cell;
    vertical-align: middle;
    position: relative;
    z-index: 3;
}

#site-head .site-head-content {
    padding: 0 20px;
    position: relative;
    z-index: 3;
}

.blog-title {
    margin: 10px 0;
    font-size: 7rem;
    font-family: "Parisienne", cursive;
    font-weight: 400;
    letter-spacing: 0.02em;
    color: #fff;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.5), 0 1px 3px rgba(0, 0, 0, 0.3);
}

.blog-description {
    margin: 0 0 2rem 0;
    font-size: 2.4rem;
    line-height: 1.5em;
    font-weight: 400;
    font-family: "Proza Libre", sans-serif;
    letter-spacing: 0.02em;
    color: #fff;
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.5), 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Hero CTA Button */
#site-head .cta-button {
    display: inline-block;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 1.6rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--section-dark-bg-color);
    background-color: #fff;
    padding: 1rem 2.5rem;
    border-radius: 30px;
    letter-spacing: 0.03em;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    margin-top: 1rem;
}

#site-head .cta-button:hover {
    background-color: var(--section-light-bg-color);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.4);
    transform: translateY(-2px);
    color: var(--section-dark-bg-color);
}

/* ===== Top Navigation Bar ===== */
.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 99999;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 3rem;
    background-color: rgba(255, 255, 255, 0.97);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.top-nav.at-top {
    background-color: rgba(0, 0, 0, 0.25);
    box-shadow: none;
}

.top-nav.at-top .nav-brand a,
.top-nav.at-top .nav-item {
    color: #fff;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

.top-nav.at-top .nav-item:hover,
.top-nav.at-top .nav-item.active {
    color: #fff;
}

.top-nav.at-top .nav-item.active::after {
    background-color: #fff;
}

.nav-brand a {
    font-family: "Parisienne", cursive;
    font-size: 2.4rem;
    font-weight: 400;
    text-decoration: none;
    color: var(--section-light-text-color);
    letter-spacing: 0.02em;
    transition: all 0.3s ease;
}

.nav-brand a:hover {
    color: var(--sticky-menu-text-color);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-item {
    font-family: "Proza Libre", sans-serif;
    font-size: 1.2rem;
    font-weight: 500;
    text-decoration: none;
    color: var(--section-light-text-color);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.8rem 1.2rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    position: relative;
}

.nav-item:hover {
    color: var(--sticky-menu-text-color);
}

.nav-item.active {
    color: var(--sticky-menu-text-color);
}

.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background-color: var(--sticky-menu-text-color);
    border-radius: 1px;
}

/* Header Arrow */
#header-arrow {
    font-size: 140px;
    margin: -10px auto;
    text-align: center;
    position: absolute;
    width: 100%;
    left: 0;
    bottom: -120px;
    cursor: pointer;
    opacity: 0.6;
    transition: all ease 0.3s;
    text-decoration: none;
    color: #fff;
    z-index: 3;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

#header-arrow:hover {
    opacity: 0.9;
}


/* ===== Content Sections ===== */
.post-holder {
    width: 100%;
    height: 100%;
    text-align: justify;
    background-color: var(--color-background);
    color: var(--color-text);
    position: relative;
    padding-bottom: 20px;
}

.post-holder.light {
    --color-text: var(--section-light-text-color);
    --color-background: var(--section-light-bg-color);
    background-color: var(--section-light-bg-color);
    color: var(--section-light-text-color);
}

.post-holder.dark {
    --color-text: var(--section-dark-text-color);
    --color-background: var(--section-dark-bg-color);
    background-color: var(--section-dark-bg-color);
    color: var(--section-dark-text-color);
}

/* Section dividers - organic wave shape */
.post-holder::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 80px;
    z-index: 1;
    pointer-events: none;
}

.post-holder.light::after {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 120' preserveAspectRatio='none'%3E%3Cpath d='M0,0 C150,90 350,0 500,50 C650,100 800,20 1000,80 C1100,100 1150,60 1200,80 L1200,120 L0,120 Z' fill='%23448ca7'/%3E%3C/svg%3E") no-repeat bottom center;
    background-size: 100% 100%;
}

.post-holder.dark::after {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 120' preserveAspectRatio='none'%3E%3Cpath d='M0,80 C100,40 300,100 500,60 C700,20 900,90 1050,50 C1150,30 1180,70 1200,40 L1200,120 L0,120 Z' fill='%23f2efe8'/%3E%3C/svg%3E") no-repeat bottom center;
    background-size: 100% 100%;
}

.post-holder.last::after,
.post-holder:last-child::after {
    display: none;
}

/* Post Content */
.post {
    position: relative;
    width: 80%;
    max-width: 700px;
    margin: 0 auto;
    padding-bottom: 4rem;
    padding-top: 4rem;
    hyphens: auto;
    scroll-margin-top: 80px;
}

.post-header {
    margin-bottom: 1.5em;
}

.post-title {
    margin: 0;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.post-title a {
    text-decoration: none;
}

.post-content img {
    float: right;
    max-width: 40%;
    margin: 0.5em 0 1em 2em;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
    shape-outside: margin-box;
}

.post-holder:nth-child(even) .post-content img {
    float: left;
    margin: 0.5em 2em 1em 0;
}

.post-content::after {
    content: '';
    display: table;
    clear: both;
}

/* ===== Contact List ===== */
.contact-list {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 2rem;
}

.contact-item {
    display: block;
}

.contact-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    font-size: 1.7rem;
    padding: 1.2rem 1.5rem;
    border-radius: 6px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.contact-link:hover {
    background-color: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.08);
}

.contact-link i {
    font-size: 2.8rem;
    width: 3rem;
    text-align: center;
    color: var(--contact-accent, var(--sticky-menu-text-color));
}

.contact-label {
    display: none;
}

.contact-value {
    color: var(--contact-accent, var(--sticky-menu-text-color));
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 1.5rem;
    font-weight: 500;
    text-align: center;
}

.post-holder.dark .contact-link i,
.post-holder.dark .contact-value {
    --contact-accent: var(--highlight-inverse);
}

.post-holder.dark .contact-link:hover {
    background-color: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.15);
}

/* ===== Mi consulta ===== */
#mi-espacio {
    max-width: 900px;
    text-align: center;
}

#mi-espacio .post-content {
    text-align: center;
}

#mi-espacio .post-content img {
    float: none;
    display: block;
    max-width: 100%;
    margin: 0 auto 1.5rem;
}

.address-link {
    display: block;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 2rem;
    font-weight: 500;
    line-height: 1.6;
    text-decoration: none;
    margin-top: 1.5rem;
    transition: opacity 0.3s ease;
}

.address-link:hover {
    opacity: 0.7;
}

.address-link i {
    color: var(--sticky-menu-text-color);
    margin-right: 0.5rem;
}

/* ===== Testimonials Carousel ===== */
#opiniones {
    text-align: center;
}

#opiniones .post-content {
    max-width: none;
}

.carousel {
    position: relative;
    overflow: hidden;
}

.carousel-track {
    display: flex;
    transition: transform 0.4s ease;
}

.carousel-track.no-transition {
    transition: none;
}

.carousel-controls {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.carousel-btn {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: inherit;
    width: 4.5rem;
    height: 4.5rem;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.carousel-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.35);
}

.testimonial-card {
    flex: 0 0 50%;
    margin: 0;
    padding: 1rem;
    box-sizing: border-box;
    position: relative;
    display: flex;
    flex-direction: column;
    text-align: left;
    aspect-ratio: 1;
}

.testimonial-card::before {
    content: '';
    position: absolute;
    inset: 1rem;
    background-color: rgba(255, 255, 255, 0.07);
    border-radius: 12px;
}

.testimonial-card > * {
    position: relative;
}

.testimonial-card > .testimonial-stars {
    padding: 1.5rem 1.5rem 0;
}

.testimonial-card > p {
    padding: 0 1.5rem;
    margin: 0.6rem 0;
    font-style: italic;
    font-size: 1.4rem;
    line-height: 1.6;
    flex: 1;
}

.testimonial-card > cite {
    padding: 0 1.5rem 1.5rem;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 1.4rem;
    font-style: normal;
    font-weight: 600;
    opacity: 0.8;
}

.testimonial-stars {
    color: #f4c150;
    font-size: 1.2rem;
    letter-spacing: 0.15em;
}

.testimonial-stars .half-star {
    position: relative;
    display: inline-block;
    color: rgba(255, 255, 255, 0.2);
}

.testimonial-stars .half-star::before {
    content: '\f005';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    overflow: hidden;
    width: 50%;
    color: #f4c150;
}


/* ===== Pricing / Tarifas ===== */
#tarifas {
    text-align: center;
}

.pricing-cards {
    display: flex;
    justify-content: center;
    gap: 3rem;
}

.pricing-card {
    padding: 4rem 5rem;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    background-color: rgba(255, 255, 255, 0.6);
    text-align: center;
}

.pricing-card i {
    font-size: 3.5rem;
    color: var(--sticky-menu-text-color);
    margin-bottom: 1.5rem;
}

.pricing-name {
    font-size: 2.4rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
}

.pricing-amount {
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 6rem;
    font-weight: 600;
    color: var(--sticky-menu-text-color);
    line-height: 1;
}

.pricing-currency {
    font-size: 3.2rem;
    vertical-align: super;
    margin-left: 0.2rem;
}

/* Center the contact section */
#contacto {
    text-align: center;
    padding-top: 6rem;
    padding-bottom: 6rem;
}

#contacto .post-header {
    text-align: center;
}

#contacto .post-content {
    display: flex;
    justify-content: center;
}

/* ===== Footer ===== */
.site-footer {
    background: var(--footer-color-background);
    color: var(--footer-color);
    font-family: "Proza Libre", sans-serif;
    font-size: 1.3rem;
    position: relative;
    margin: 0;
    padding: 1.5rem 0;
    line-height: 1.5em;
    text-align: center;
    letter-spacing: 0.02em;
}

.site-footer a {
    color: var(--footer-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.site-footer a:hover {
    color: var(--sticky-menu-text-color);
}

.copyright {
    margin: 0.5rem 0;
}

/* ===== Media Queries - Tablet (< 1130px) ===== */
@media only screen and (max-width: 1130px) {
    .top-nav {
        padding: 0.8rem 1.5rem;
    }

    .nav-brand a {
        font-size: 2rem;
    }

    .nav-item {
        font-size: 1.1rem;
        padding: 0.6rem 0.8rem;
    }

    .post-holder {
        padding-top: 20px;
    }

    .post-holder::after {
        height: 60px;
    }

    #site-head {
        min-height: 240px;
        padding: 15% 0;
        height: 100vh;
    }

    .blog-title {
        font-size: 6rem;
    }

    .blog-description {
        font-size: 2rem;
        line-height: 1.5em;
    }

    #site-head .cta-button {
        font-size: 1.4rem;
        padding: 0.9rem 2rem;
    }

    .post {
        font-size: 0.95em;
        line-height: 1.65em;
        scroll-margin-top: 70px;
    }

    h1 {
        font-size: 4.2rem;
    }

    h2 {
        font-size: 3.4rem;
    }

    h3 {
        font-size: 2.8rem;
    }

    h4 {
        font-size: 2.4rem;
    }
}

/* ===== Media Queries - Small Tablet (< 900px) ===== */
@media only screen and (max-width: 900px) {
    .top-nav {
        flex-direction: column;
        padding: 0.6rem 1rem;
        gap: 0.3rem;
    }

    .nav-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.2rem;
    }

    .nav-item {
        font-size: 1rem;
        padding: 0.4rem 0.6rem;
    }

    .post {
        scroll-margin-top: 100px;
    }

    .post-holder::after {
        height: 50px;
    }
}

/* ===== Media Queries - Mobile (< 500px) ===== */
@media only screen and (max-width: 500px) {
    .top-nav {
        padding: 0.5rem 0.6rem;
    }

    .nav-brand a {
        font-size: 1.8rem;
    }

    .nav-item {
        font-size: 0.85rem;
        padding: 0.3rem 0.4rem;
        letter-spacing: 0.04em;
    }

    .nav-item.active::after {
        width: 12px;
        bottom: 1px;
    }

    .post-holder {
        padding-top: 20px;
    }

    .post-holder::after {
        height: 40px;
    }

    .post {
        width: auto;
        margin-left: 20px;
        margin-right: 20px;
        font-size: 0.9em;
        line-height: 1.6em;
        scroll-margin-top: 110px;
    }

    #site-head {
        padding: 10% 0;
        height: 85vh;
    }

    #header-arrow {
        display: none;
    }

    .blog-title {
        font-size: 5rem;
    }

    .blog-description {
        font-size: 1.8rem;
    }

    #site-head .cta-button {
        font-size: 1.3rem;
        padding: 0.8rem 1.8rem;
    }

    h1, h2 {
        font-size: 2.8rem;
        line-height: 1.15em;
    }

    h3 {
        font-size: 2.4rem;
    }

    h4 {
        font-size: 2rem;
    }

    .site-footer {
        font-size: 1.1rem;
    }

    .testimonial-card {
        flex: 0 0 100%;
    }

    .pricing-cards {
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
    }

    .pricing-card {
        padding: 2rem 3rem;
        width: 100%;
    }

    .pricing-amount {
        font-size: 4rem;
    }

    .contact-list {
        gap: 1.5rem;
    }

    .contact-link {
        padding: 1rem;
    }

    .contact-link i {
        font-size: 3rem;
    }

    .contact-value {
        display: none;
    }
}
