/* 
   Design System - Tu Terapeuta Ocupacional
   Premium, Modern, and Accessible
*/

:root {
    --primary: #ad1f5f;
    --primary-dark: #8c194d;
    --primary-light: #d14a85;
    --secondary: #fdf8f9;
    --accent: #6b143b;
    --text-main: #2c3e50;
    --text-muted: #5d6d7e;
    --bg-white: #ffffff;
    --glass: rgba(255, 255, 255, 0.9);
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 50px rgba(173, 31, 95, 0.12);
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 32px;
}

@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-main);
    background-color: var(--bg-white);
    line-height: 1.7;
    overflow-x: hidden;
    font-size: 16px;
}

h1, h2, h3, h4, .font-elegant {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    line-height: 1.2;
}

h1 { font-size: clamp(2.5rem, 8vw, 4.5rem); }
h2 { font-size: clamp(2rem, 5vw, 3.5rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2.2rem); }

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

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

/* --- Layout Components --- */

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 2000;
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(173, 31, 95, 0.08);
    padding: 0.6rem 0;
    transition: var(--transition);
}

header.scrolled {
    padding: 0.4rem 0;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow-md);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo img {
    height: 55px;
    width: auto;
    transition: var(--transition);
}

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

.nav-links a {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-main);
    position: relative;
    opacity: 0.75;
}

.nav-links a:hover, .nav-links a.active {
    opacity: 1;
    color: var(--primary);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
}

.nav-links a:hover::after, .nav-links a.active::after {
    width: 100%;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.btn-cta {
    background: var(--primary);
    color: white !important;
    padding: 0.8rem 1.8rem;
    border-radius: var(--radius-lg);
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 8px 20px rgba(173, 31, 95, 0.15);
    transition: var(--transition);
    border: 2px solid transparent;
}

.btn-cta:hover {
    background: var(--bg-white);
    color: var(--primary) !important;
    border-color: var(--primary);
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(173, 31, 95, 0.25);
}

/* Menu Toggle (Hamburger) */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 2100;
    padding: 10px;
}

.menu-toggle span {
    display: block;
    width: 28px;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
    border-radius: 2px;
}

.menu-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

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

.menu-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* --- Responsive Nav --- */

@media (max-width: 992px) {
    .menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: var(--bg-white);
        flex-direction: column;
        justify-content: center;
        gap: 2.5rem;
        transition: 0.5s cubic-bezier(0.77,0.2,0.05,1.0);
        box-shadow: -10px 0 30px rgba(0,0,0,0.05);
        z-index: 2050;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 1.2rem;
    }

    .header-actions .btn-cta {
        display: none; /* Hide on mobile header, show inside nav-links instead */
    }
    
    .nav-links .btn-cta {
        display: inline-block;
        margin-top: 1rem;
    }
}

/* --- Sections & Layout Utilities --- */

section {
    padding: clamp(4rem, 10vw, 8rem) 0;
    position: relative;
    overflow: hidden;
}

.section-header {
    text-align: center;
    margin-bottom: clamp(3rem, 8vw, 5rem);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.section-header h2 {
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.section-header p {
    color: var(--text-muted);
    font-size: 1.15rem;
}

main {
    padding-top: 0; /* Removing fixed padding-top, using relative positioning or margin on first section if needed */
}

/* --- Hero Section Refinement --- */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: white;
    padding-top: 80px;
    text-align: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.3) 50%, rgba(0,0,0,0.6) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
}

.hero h1 {
    font-weight: 700;
    margin-bottom: 2rem;
    text-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.hero p {
    font-size: clamp(1.1rem, 2vw, 1.4rem);
    margin-bottom: 3rem;
    font-weight: 300;
    opacity: 0.9;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* --- Feature/Info Sections --- */

.info-section {
    display: flex;
    align-items: center;
    gap: 4rem;
    flex-wrap: wrap;
}

.info-content {
    flex: 1;
    min-width: 320px;
}

.info-image-wrapper {
    flex: 1;
    min-width: 320px;
    position: relative;
}

.info-image {
    width: 100%;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
}

.info-image:hover {
    transform: scale(1.02);
}

/* Specific styling for Rossy section */
.rossy-intro {
    background: var(--secondary);
}

.rossy-intro .info-content h2 {
    font-size: clamp(3rem, 10vw, 5rem);
    line-height: 1.1;
}

/* --- Custom Cards --- */

.grid-services {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
}

.service-card {
    background: white;
    padding: clamp(2rem, 5vw, 3.5rem);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(173, 31, 95, 0.05);
    transition: var(--transition);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.service-card:hover {
    transform: translateY(-15px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(173, 31, 95, 0.2);
}

.service-card .icon-box {
    width: 80px;
    height: 80px;
    background: var(--secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    transition: var(--transition);
}

.service-card:hover .icon-box {
    background: var(--primary);
    transform: rotateY(180deg);
}

.service-card .icon-box img {
    width: 40px;
    transition: var(--transition);
}

.service-card:hover .icon-box img {
    filter: brightness(0) invert(1);
}

.service-card h3 {
    margin-bottom: 1.2rem;
    color: var(--primary);
}

.service-card p {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.service-card .btn-link {
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

.service-card .btn-link:hover {
    gap: 1rem;
}

/* --- Service List --- */

.service-list-container {
    padding: 6rem 0;
}

.service-list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 2.5rem;
    margin-top: 3rem;
}

.service-item {
    background: white;
    padding: 2.5rem;
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.04);
    border: 1px solid rgba(173, 31, 95, 0.05);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.service-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(173, 31, 95, 0.08);
    border-color: rgba(173, 31, 95, 0.2);
}

.service-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 6px;
    height: 100%;
    background: var(--primary);
    opacity: 0.1;
    transition: var(--transition);
}

.service-item:hover::before {
    opacity: 1;
}

.service-item h3 {
    font-size: 1.6rem;
    color: var(--primary);
    margin-bottom: 1rem;
    font-family: 'Poppins', sans-serif;
}

.service-item p {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.7;
}

.service-tagline {
    text-align: center;
    margin-top: 4rem;
    font-size: 1.5rem;
    color: var(--primary);
    font-family: 'Poppins', sans-serif;
    font-style: italic;
    opacity: 0.8;
}

/* --- Footer Redesign --- */
footer {
    background: #1a1a1a;
    color: white;
    padding: clamp(4rem, 8vw, 6rem) 0 3rem;
    position: relative;
    overflow: hidden;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-col h4 {
    font-size: 1.6rem;
    margin-bottom: 1.8rem;
    color: white;
    position: relative;
    display: inline-block;
}

.footer-col h4::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--primary);
}

.footer-col p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
}

.footer-col ul li {
    margin-bottom: 1.2rem;
    transition: var(--transition);
}

.footer-col ul li a {
    color: rgba(255, 255, 255, 0.7);
}

.footer-col ul li a:hover {
    color: var(--primary-light);
    padding-left: 8px;
}

.social-links {
    display: flex;
    gap: 1.2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.social-icon {
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.social-icon:hover {
    background: var(--primary);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(173, 31, 95, 0.3);
    border-color: var(--primary);
}

.social-icon img {
    width: 24px;
    opacity: 0.9;
}

.footer-bottom {
    text-align: center;
    padding-top: 3rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
}

.footer-bottom strong {
    color: var(--primary-light);
}

/* --- Responsive --- */

/* --- Infoproducts Store --- */

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
    margin-top: 3rem;
}

.product-card {
    background: white;
    border-radius: 25px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    border: 1px solid rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-12px);
    box-shadow: var(--shadow-hover);
}

.product-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.product-info {
    padding: 2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-category {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.product-card h3 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.product-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent);
    margin-top: auto;
    margin-bottom: 1.5rem;
}

.btn-buy {
    background: var(--text-main);
    color: white;
    padding: 1rem;
    border-radius: 15px;
    text-align: center;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
}

.btn-buy:hover {
    background: var(--primary);
}

/* --- Responsive updates --- */

@media (max-width: 992px) {
    .nav-links {
        display: none;
    }
    .hero h1 {
        font-size: 3rem;
    }
    nav {
        justify-content: space-between;
    }
    .logo img {
        height: 50px;
    }
    .btn-cta {
        padding: 0.6rem 1.2rem;
        font-size: 0.8rem;
    }
}


/* --- Blog Single Post Styles --- */

.blog-post-header {
    text-align: center;
    padding: 8rem 0 5rem;
    background: linear-gradient(to bottom, var(--secondary) 0%, white 100%);
}

.blog-post-header h1 {
    font-size: 3.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.2;
}

.blog-post-meta {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-family: 'Poppins', sans-serif;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
}

.blog-article-content {
    max-width: 850px;
    margin: 4rem auto 8rem;
    padding: 0 1.5rem;
    line-height: 1.9;
    color: #444;
    font-size: 1.15rem;
}

.blog-article-content p {
    margin-bottom: 2.2rem;
}

.blog-article-content h2, .blog-article-content h3 {
    color: var(--primary);
    margin-top: 4rem;
    margin-bottom: 1.5rem;
    font-family: 'Poppins', sans-serif;
    font-size: 2.2rem;
}

.blog-article-content ul {
    margin-bottom: 2.5rem;
    padding-left: 2rem;
}

.blog-article-content li {
    margin-bottom: 1.2rem;
    position: relative;
    list-style: none;
}

.blog-article-content li::before {
    content: '•';
    color: var(--primary);
    font-weight: bold;
    display: inline-block; 
    width: 1em;
    margin-left: -1em;
}

.blog-article-content strong {
    color: var(--text-main);
    font-weight: 700;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    margin-bottom: 4rem;
    transition: var(--transition);
    font-family: 'Poppins', sans-serif;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

.back-link:hover {
    transform: translateX(-8px);
    color: var(--accent);
}

.blog-featured-image {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: 30px;
    margin-bottom: 4rem;
    box-shadow: 0 30px 60px rgba(0,0,0,0.1);
}
/* --- Product & Store Revisions --- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2.5rem;
}

.product-category {
    display: inline-block;
    background: var(--secondary);
    color: var(--primary);
    padding: 0.3rem 0.8rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

.product-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

/* --- Contact Form --- */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 5rem;
    align-items: start;
}

@media (max-width: 992px) {
    .contact-container {
        grid-template-columns: 1fr;
        gap: 4rem;
    }
}

.contact-info-card {
    background: var(--bg-white);
    padding: 3rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

.contact-form {
    background: var(--bg-white);
    padding: clamp(2rem, 5vw, 4rem);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.6rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-main);
}

.form-group input, 
.form-group textarea {
    width: 100%;
    padding: 1rem 1.2rem;
    border: 1px solid rgba(0,0,0,0.1);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    background: #fcfcfc;
}

.form-group input:focus, 
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: white;
    box-shadow: 0 0 0 4px rgba(173, 31, 95, 0.05);
}

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

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

/* Footer Bottom Fix */
.footer-bottom {
    margin-top: 5rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    font-size: 0.9rem;
    opacity: 0.6;
}


/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--secondary);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-light);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* --- Floating WhatsApp Button --- */
.btn-whatsapp {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: white;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.3);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.btn-whatsapp:hover {
    transform: scale(1.1) rotate(10deg);
    background-color: #128c7e;
}

.btn-whatsapp img {
    width: 32px;
}

/* --- Responsive fixes for footer --- */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.8rem;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .btn-whatsapp {
        bottom: 20px;
        right: 20px;
        width: 55px;
        height: 55px;
    }
}

/* --- Office Carousel --- */

.office-carousel {
    position: relative;
    width: 100%;
    height: 500px;
    background: #fdf8f9;
    overflow: hidden;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
    background-size: cover;
    background-position: center;
    z-index: 1;
}

.carousel-slide.active {
    opacity: 1;
    z-index: 2;
}

@media (max-width: 768px) {
    .office-carousel {
        height: 350px;
    }
}
