/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800&family=Open+Sans:wght@400;600&display=swap');
@import url('modal.css');

:root {
    /* Color Palette - Tangram Logo */
    --color-pink: #E91E8C;
    --color-lime: #A4BF3D;
    --color-turquoise: #00A19B;
    --color-orange: #F47B20;
    --color-purple: #8B7FA8;
    --color-yellow: #FDB913;
    --color-green: #6FB43F;

    /* Neutrals */
    --color-white: #FFFFFF;
    --color-light-gray: #F9F9F9;
    --color-text-dark: #333333;
    --color-text-light: #666666;
    --color-border: #EEEEEE;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 8rem;

    /* Typography */
    --font-heading: 'Nunito', sans-serif;
    --font-body: 'Open Sans', sans-serif;

    /* UI Elements */
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 10px 25px rgba(0, 0, 0, 0.1);
    --transition-fast: 0.3s ease;
}

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

body {
    font-family: var(--font-body);
    color: var(--color-text-dark);
    line-height: 1.6;
    background-color: var(--color-white);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-sm);
    line-height: 1.2;
}

h1 {
    font-size: 2.5rem;
    font-weight: 800;
}

h2 {
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: var(--spacing-md);
    position: relative;
    display: inline-block;
    width: 100%;
}

/* Decorative underline for H2 */
h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--color-turquoise);
    margin: 0.5rem auto 0;
    border-radius: 2px;
}

p {
    margin-bottom: var(--spacing-sm);
    color: var(--color-text-light);
}

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

ul {
    list-style: none;
}

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

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

/* Buttons */
.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-weight: 700;
    text-align: center;
    cursor: pointer;
    transition: var(--transition-fast);
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--color-pink);
    color: var(--color-white);
    box-shadow: 0 4px 15px rgba(233, 30, 140, 0.3);
}

.btn-primary:hover {
    background-color: #D81B60;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(233, 30, 140, 0.4);
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid var(--color-turquoise);
    color: var(--color-turquoise);
}

.btn-secondary:hover {
    background-color: var(--color-turquoise);
    color: var(--color-white);
}

/* Section Spacing */
section {
    padding: var(--spacing-lg) 0;
}

section:nth-child(even) {
    background-color: var(--color-light-gray);
}

/* Header & Nav */
header {
    background: var(--color-white);
    padding: 0.2rem 0;
    /* Minimal padding */
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    /* Lighter shadow */
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1rem;
    color: var(--color-text-dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    flex-shrink: 0;
    min-width: 0;
}

.logo img {
    height: 35px;
    width: auto;
    min-height: 35px;
    flex-shrink: 0;
    transition: transform var(--transition-fast);
    display: block;
}

.logo img:hover {
    transform: scale(1.1);
    /* Slightly larger on hover for effect */
}

.logo span {
    color: var(--color-pink);
    /* Placeholder color for text logo if img fails */
}

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

nav a {
    font-weight: 600;
    font-size: 1rem;
    position: relative;
    white-space: nowrap;
}

nav a:hover,
nav a.active {
    color: var(--color-turquoise);
}

nav .btn-cta {
    padding: 10px 20px;
    font-size: 0.9rem;
    order: 999;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    padding-top: 250px;
    /* Accounts for larger logo header */
    padding-bottom: var(--spacing-lg);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.7) 100%), url('../assets/images/hero-bg-placeholder.jpg');
    /* Fallback */
    background-size: cover;
    background-position: center;
    min-height: 80vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

/* Visual shape decoration */
.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: url('data:image/svg+xml;utf8,<svg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"><path fill="%23EFFAFB" d="M44.7,-76.4C58.9,-69.2,71.8,-59.1,81.6,-46.6C91.4,-34.1,98.1,-19.2,95.8,-4.9C93.5,9.4,82.2,23.1,71.2,35.4C60.2,47.7,49.5,58.6,37,65.8C24.5,73,10.2,76.5,-3.3,79.9C-16.8,83.3,-29.5,86.6,-41.2,79.1C-52.9,71.6,-63.6,53.3,-73.1,35.7C-82.6,18.1,-90.9,1.2,-87.3,-14.2C-83.7,-29.6,-68.2,-43.5,-53.4,-50.2C-38.6,-56.9,-24.5,-56.4,-11.2,-58.5C2.1,-60.6,15.4,-65.3,30.5,-83.6L44.7,-76.4Z" transform="translate(100 100)" /></svg>') no-repeat right bottom;
    background-size: contain;
    z-index: -1;
    opacity: 0.6;
}

.hero-content {
    max-width: 600px;
    z-index: 1;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: var(--color-text-dark);
}

.hero h1 span {
    color: var(--color-pink);
    display: inline-block;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    color: var(--color-text-light);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

/* Nav en dos filas para anchos intermedios */
@media (min-width: 769px) and (max-width: 1280px) {
    .nav-container {
        flex-wrap: wrap;
        gap: 0.2rem 0;
        padding: 0.4rem 0;
    }

    nav {
        width: 100%;
        border-top: 1px solid var(--color-border);
        padding-top: 0.4rem;
        padding-bottom: 0.2rem;
    }

    nav ul {
        gap: 1rem;
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .hero {
        padding-top: 130px;
    }
}

/* Responsive */
@media (max-width: 768px) {
    h1 {
        font-size: 1.8rem;
        text-align: center;
        line-height: 1.2;
    }

    h2 {
        font-size: 1.5rem;
        text-align: center;
    }

    .logo img {
        height: 36px;
    }

    .menu-toggle {
        display: block;
    }

    nav ul {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background: var(--color-white);
        flex-direction: column;
        padding: 2rem;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
        transform: translateY(-150%);
        transition: transform 0.3s ease;
        gap: 1.5rem;
    }

    nav ul.active {
        transform: translateY(0);
    }

    .hero {
        padding-top: 100px;
        min-height: 60vh;
        text-align: center;
    }

    .hero-content {
        margin: 0 auto;
    }

    .hero-buttons {
        justify-content: center;
    }
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background: var(--color-white);
    padding: 2rem;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-soft);
    text-align: center;
    transition: var(--transition-fast);
    border-bottom: 4px solid transparent;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
    border-bottom-color: var(--color-turquoise);
}

.service-img-container {
    height: 120px;
    /* Increased height for images */
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.service-img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: transform var(--transition-fast);
}

.service-card:hover .service-img {
    transform: scale(1.1);
}

.service-card h3 {
    margin-bottom: 1rem;
    color: var(--color-text-dark);
}

/* Philosophy Section */
.bg-pattern {
    background-color: var(--color-white);
    background-image: radial-gradient(var(--color-border) 1px, transparent 1px);
    background-size: 20px 20px;
}

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

.lead {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--color-text-dark);
    margin-bottom: 1.5rem;
}

.stats-grid {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    /* Ensure it wraps on small screens */
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--color-text-light);
}

/* Gallery & Tour */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.gallery-item .img-placeholder {
    height: 150px;
    background-color: #ddd;
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-size: 0.8rem;
}

.virtual-tour-placeholder {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: var(--border-radius-md);
    padding: 4rem 2rem;
    text-align: center;
    border: 2px dashed #aaa;
    position: relative;
    overflow: hidden;
}

.virtual-tour-placeholder::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.5);
    z-index: 0;
}

.tour-content {
    position: relative;
    z-index: 1;
}

/* Team Section */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.team-member {
    text-align: center;
}

.member-photo {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    overflow: hidden;
    background-color: #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 4px solid var(--color-white);
    box-shadow: var(--shadow-soft);
}

.team-member h3 {
    margin-bottom: 0.5rem;
    font-size: 1.25rem;
}

.team-member .role {
    color: var(--color-turquoise);
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.team-member .bio {
    font-size: 0.9rem;
}

/* Resources Section */
.bg-light {
    background-color: var(--color-light-gray);
}

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

.resource-card {
    background: var(--color-white);
    padding: 2rem;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-soft);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.file-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.btn-download {
    margin-top: auto;
    color: var(--color-pink);
    font-weight: 700;
    text-decoration: underline;
}

.btn-download:hover {
    color: var(--color-text-dark);
}

/* Training / Courses */
.subsection-title {
    font-size: 1.5rem;
    color: var(--color-turquoise);
    margin: 2rem 0 1rem;
    padding-left: 1rem;
    border-left: 4px solid var(--color-orange);
}

.courses-container {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
    /* justify-content: flex-start;  Align left as requested */
}

.course-card {
    background: var(--color-white);
    padding: 2rem;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-soft);
    width: 100%;
    /* Fill the container */
    max-width: none;
    /* Remove any width restriction */
    box-sizing: border-box;
    /* Include padding in width */
    margin: 0;
    /* Remove auto margins as we are filling width */
    position: relative;
    border-top: 5px solid var(--color-orange);
    transition: var(--transition-fast);
}

.carousel-slide .course-card {
    height: 100%;
    /* Match height of slide if possible */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

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

.course-card.past {
    border-top-color: var(--color-text-light);
    filter: grayscale(0.8);
    opacity: 0.9;
}

.course-card.past:hover {
    filter: grayscale(0);
    opacity: 1;
    border-top-color: var(--color-turquoise);
}

.course-card.past .badge {
    background: var(--color-text-light);
}

.course-card.upcoming {
    border-top-color: var(--color-lime);
}

.course-card.upcoming .badge {
    background: var(--color-lime);
    color: #3a5200;
}

.course-card.upcoming:hover {
    border-top-color: var(--color-lime);
}

.course-card.featured .badge {
    position: absolute;
    top: -12px;
    right: 20px;
    background: var(--color-orange);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
}

.course-actions {
    margin-top: 1.5rem;
    display: flex;
    gap: 1rem;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.9rem;
}

/* Contact Section Refactor */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 0;
    /* Removing bottom margin as map is inside */
    align-items: stretch;
    /* Stretch to match height */
}

.contact-left-column {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-info {
    font-size: 1.1rem;
}

/* Social Icons */
.social-icons {
    margin-top: 1.5rem;
    display: flex;
    gap: 1.5rem;
    justify-content: flex-start;
    /* Aligned left with text */
    padding-left: 0;
}

.social-icon {
    width: 60px;
    /* Slightly larger for official feel */
    height: 60px;
    background: var(--color-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.social-icon svg {
    width: 30px;
    height: 30px;
}

/* Brand Colors Backgrounds */
.social-icon[title="Instagram"] {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    border-radius: 14px;
    /* Squircle shape */
}

.social-icon[title="Facebook"] {
    background: #1877F2;
    /* Facebook remains circle (50% from base class) */
}

.social-icon:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.contact-form-box {
    background: var(--color-white);
    padding: 1.5rem;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-soft);
    /* Make it fit nicely in the column */
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--color-text-dark);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-turquoise);
    box-shadow: 0 0 0 3px rgba(0, 161, 155, 0.1);
}

.btn-block {
    display: block;
    width: 100%;
}

.map-container {
    border-radius: var(--border-radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    height: 100%;
    min-height: 450px;
    /* Ensure logical minimum */
}

@media (max-width: 768px) {
    .contact-wrapper {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .map-container {
        min-height: 300px;
    }

    .social-icons {
        justify-content: center;
        /* Center on mobile */
    }

    .contact-info {
        text-align: center;
    }

    .contact-info p {
        justify-content: center;
    }
}

/* Social Media Buttons */
.btn-social {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    font-weight: 600;
    color: white;
    text-decoration: none;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
    font-size: 0.9rem;
}

.btn-social:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: white;
}

.btn-social i {
    font-size: 1.1rem;
}

.btn-facebook {
    background-color: #1877F2;
    /* Facebook Blue */
}

.btn-instagram {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    /* Instagram Gradient */
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp:hover {
    background-color: #128C7E;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

/* Footer */
footer {
    background: #333;
    color: white;
    padding: 3rem 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.footer-logo {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.5rem;
}

.footer-links a {
    margin: 0 1rem;
    font-weight: 600;
}

.footer-links a:hover,
.footer-legal a:hover {
    color: var(--color-turquoise);
}

.footer-legal a {
    color: #999;
    font-size: 0.9rem;
    margin: 0 0.5rem;
}

@media (max-width: 600px) {
    .contact-wrapper {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-content {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }

    .footer-links {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }

    .philosophy-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

/* CAROUSEL STYLES */
.carousel-container {
    position: relative;
    max-width: 400px;
    /* Width for vertical format */
    margin: 0 auto 3rem auto;
    overflow: hidden;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-md);
}

.carousel-track-container {
    overflow: hidden;
    height: 600px;
    /* Height for vertical format (2:3 approx) */
    position: relative;
    background: #f0f0f0;
}

.carousel-track {
    display: flex;
    padding: 0;
    margin: 0;
    list-style: none;
    transition: transform 0.5s ease-in-out;
    height: 100%;
}

.carousel-slide {
    min-width: 100%;
    height: 100%;
    position: relative;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Ensure image covers area */
    display: block;
}

/* Navigation Buttons */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.carousel-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

.carousel-btn.prev-btn {
    left: 10px;
}

.carousel-btn.next-btn {
    right: 10px;
}

/* Nav Indicators */
.carousel-nav {
    display: flex;
    justify-content: center;
    padding: 10px 0;
    position: absolute;
    bottom: 10px;
    width: 100%;
    z-index: 10;
}

.carousel-indicator {
    border: none;
    width: 10px;
    height: 10px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    margin: 0 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.carousel-indicator.current-slide {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.2);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .carousel-track-container {
        height: 300px;
        /* Smaller height on mobile */
    }
}

/* CAROUSEL STYLES */
.carousel-container {
    position: relative;
    max-width: 800px;
    margin: 0 auto 3rem auto;
    /* Centered with margin */
    overflow: hidden;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-md);
}

.carousel-track-container {
    overflow: hidden;
    height: 500px;
    /* Fixed height for carousel */
    position: relative;
    background: #f0f0f0;
}

.carousel-track {
    display: flex;
    padding: 0;
    margin: 0;
    list-style: none;
    transition: transform 0.5s ease-in-out;
    height: 100%;
}

.carousel-slide {
    min-width: 100%;
    height: 100%;
    position: relative;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Ensure image covers area without distortion */
    display: block;
}

/* Navigation Buttons */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: var(--color-orange);
    /* Orange background */
    color: white;
    border: none;
    width: 45px;
    /* Slightly larger */
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    opacity: 0.9;
}

.carousel-btn:hover {
    background: #e65100;
    /* Darker orange/reddish for hover */
    transform: translateY(-50%) scale(1.1);
    /* Slight grow effect, keep vertical center */
    opacity: 1;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

.carousel-btn i {
    color: white;
    font-size: 1.2rem;
}

.carousel-btn.prev-btn {
    left: 10px;
}

.carousel-btn.next-btn {
    right: 10px;
}

/* Nav Indicators */
.carousel-nav {
    display: flex;
    justify-content: center;
    padding: 10px 0;
    position: absolute;
    bottom: 10px;
    width: 100%;
    z-index: 10;
}

.carousel-indicator {
    border: none;
    width: 10px;
    height: 10px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    margin: 0 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.carousel-indicator.current-slide {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.2);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .carousel-track-container {
        height: 300px;
        /* Smaller height on mobile */
    }

    h1 {
        font-size: 1.5rem !important;
        /* Force reduction for mobile */
    }
}

/* Desktop Grid Layout for Courses */
@media (min-width: 769px) {
    .course-carousel.carousel-container {
        max-width: none;
        box-shadow: none;
        padding: 0;
        margin-bottom: 3rem;
        background: transparent;
    }

    .course-carousel .carousel-track {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 2rem;
        transform: none !important;
        /* Override JS transform */
        width: 100%;
        height: auto;
    }

    .course-carousel .carousel-track-container {
        height: auto !important;
        /* Override inline styles */
        overflow: visible;
        background: transparent;
    }

    .course-carousel .carousel-slide {
        min-width: 0;
        width: auto;
        height: auto;
        margin-bottom: 0;
    }

    .course-carousel .carousel-slide img {
        height: 200px;
        /* Limit height of images in grid cards if present */
    }

    .course-carousel .carousel-btn,
    .course-carousel .carousel-nav {
        display: none;
    }
}

/* ===== IA para TOdas ===== */

.ia-intro {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 2.5rem;
}
.ia-intro .lead { margin-bottom: 0.75rem; }
.ia-intro .ia-share-link {
    font-size: 0.95rem;
    color: #555;
}
.ia-intro .ia-share-link a {
    color: var(--color-turquoise);
    font-weight: 600;
}

/* Filter tabs */
.ia-tabs {
    display: flex;
    gap: 0.6rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}
.ia-tab {
    padding: 7px 20px;
    border-radius: 50px;
    border: 2px solid var(--color-border);
    background: white;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    color: var(--color-text-light);
    transition: all var(--transition-fast);
}
.ia-tab:hover { border-color: var(--color-turquoise); color: var(--color-turquoise); }
.ia-tab.active {
    background: var(--color-turquoise);
    border-color: var(--color-turquoise);
    color: white;
}

/* Cards grid */
.ia-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}
.ia-card {
    background: white;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-soft);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    border-top: 4px solid var(--color-border);
    transition: box-shadow var(--transition-fast), transform var(--transition-fast);
    position: relative;
}
.ia-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-3px); }
.ia-card[data-type="prompt"] { border-top-color: var(--color-purple); }
.ia-card[data-type="gem"]    { border-top-color: var(--color-lime); }
.ia-card[data-type="gpt"]    { border-top-color: var(--color-orange); }

.ia-card h3 { font-size: 1rem; margin: 0; }
.ia-card .ia-desc { font-size: 0.88rem; color: var(--color-text-light); flex-grow: 1; margin: 0; }

.ia-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    align-self: flex-start;
}
.badge-prompt { background: rgba(139,127,168,0.15); color: var(--color-purple); }
.badge-gem    { background: rgba(164,191,61,0.15);  color: #7a9a00; }
.badge-gpt    { background: rgba(244,123,32,0.15);  color: var(--color-orange); }

/* Prompt text box */
.ia-prompt-text {
    background: #f7f5ff;
    border: 1px solid rgba(139,127,168,0.25);
    border-radius: var(--border-radius-sm);
    padding: 0.85rem 1rem;
    font-size: 0.82rem;
    line-height: 1.6;
    color: #444;
    font-family: var(--font-body);
    max-height: 110px;
    overflow: hidden;
    position: relative;
}
.ia-prompt-text::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 36px;
    background: linear-gradient(transparent, #f7f5ff);
}

/* Copy button */
.btn-copiar {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 8px 16px;
    border-radius: 50px;
    border: 2px solid var(--color-purple);
    background: transparent;
    color: var(--color-purple);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.82rem;
    cursor: pointer;
    align-self: flex-start;
    transition: all var(--transition-fast);
}
.btn-copiar:hover { background: var(--color-purple); color: white; }
.btn-copiar.copiado { background: var(--color-green); border-color: var(--color-green); color: white; }

/* Coming-soon card overlay */
.ia-card.proximamente {
    opacity: 0.65;
    pointer-events: none;
}
.ia-card.proximamente::before {
    content: 'Próximamente';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.08);
    border-radius: 50px;
    padding: 6px 18px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.85rem;
    color: #555;
    white-space: nowrap;
}

/* Consulting CTA box */
.ia-consulting-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    background: linear-gradient(135deg, rgba(0,161,155,0.08), rgba(139,127,168,0.08));
    border: 1px solid rgba(0,161,155,0.2);
    border-radius: var(--border-radius-md);
    padding: 2rem 2.5rem;
    flex-wrap: wrap;
}
.ia-consulting-box h3 { font-size: 1.1rem; margin-bottom: 0.4rem; }
.ia-consulting-box p  { font-size: 0.9rem; color: var(--color-text-light); margin: 0; max-width: 500px; }
.ia-consulting-actions { display: flex; gap: 0.75rem; flex-shrink: 0; flex-wrap: wrap; }

@media (max-width: 768px) {
    .ia-consulting-box { flex-direction: column; text-align: center; }
    .ia-consulting-actions { justify-content: center; }
}

/* How to use */
.ia-howto {
    background: white;
    border: 1.5px solid var(--color-border);
    border-radius: var(--border-radius-md);
    padding: 1.4rem 1.75rem;
    margin-bottom: 2rem;
}
.ia-howto-title {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--color-text-dark);
    margin: 0 0 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.ia-howto-list {
    margin: 0 0 1rem;
    padding-left: 1.4rem;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}
.ia-howto-list li {
    font-size: 0.88rem;
    color: var(--color-text-dark);
    line-height: 1.55;
}
.ia-howto-list li strong { color: var(--color-turquoise); }
.ia-howto-list code {
    background: #f0f0f0;
    border-radius: 4px;
    padding: 1px 5px;
    font-size: 0.82rem;
    font-family: monospace;
    color: var(--color-text-dark);
}
.ia-howto-contact {
    margin: 0;
    font-size: 0.82rem;
    color: var(--color-text-light);
    border-top: 1px solid var(--color-border);
    padding-top: 0.75rem;
}
.ia-howto-contact a { color: var(--color-turquoise); }

/* Ethics notice */
.ia-etica-box {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    background: rgba(244,123,32,0.07);
    border: 1.5px solid rgba(244,123,32,0.3);
    border-radius: var(--border-radius-md);
    padding: 1.1rem 1.4rem;
    margin-bottom: 2rem;
}
.ia-etica-icon {
    flex-shrink: 0;
    color: var(--color-orange);
    margin-top: 2px;
}
.ia-etica-text strong:first-child {
    display: block;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    color: var(--color-orange);
    margin-bottom: 0.35rem;
}
.ia-etica-text p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--color-text-light);
    line-height: 1.65;
}
.ia-etica-text p strong { color: var(--color-text-dark); }

/* Filter bar (tabs + select + search) */
.ia-filtros-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}
.ia-filtros-bar .ia-tabs {
    justify-content: flex-start;
    margin-bottom: 0;
}
.ia-filtros-right {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    align-items: center;
}
.ia-select,
.ia-search {
    padding: 7px 14px;
    border-radius: 50px;
    border: 2px solid var(--color-border);
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--color-text-dark);
    background: white;
    outline: none;
    transition: border-color var(--transition-fast);
}
.ia-select:focus,
.ia-search:focus { border-color: var(--color-turquoise); }
.ia-search { min-width: 220px; }

/* Counter */
.ia-counter-text {
    font-size: 0.82rem;
    color: var(--color-text-light);
    margin: 0 0 1.25rem;
}

/* Card header row (badge + category chip) */
.ia-card-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.ia-cat-chip {
    font-size: 0.72rem;
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--color-text-light);
    background: var(--color-light-gray);
    border-radius: 50px;
    padding: 3px 10px;
}

/* Instruccion badge + border */
.badge-instruccion { background: rgba(0,161,155,0.12); color: var(--color-turquoise); }
.ia-card[data-type="instruccion"] { border-top-color: var(--color-turquoise); }

/* Empty state */
.ia-empty {
    grid-column: 1 / -1;
    text-align: center;
    color: var(--color-text-light);
    font-size: 0.95rem;
    padding: 3rem 1rem;
}

@media (max-width: 640px) {
    .ia-filtros-bar { flex-direction: column; align-items: stretch; }
    .ia-filtros-bar .ia-tabs { justify-content: center; }
    .ia-filtros-right { justify-content: stretch; }
    .ia-search { min-width: unset; width: 100%; }
    .ia-select { width: 100%; }
}

/* Collaborations / Internship Logos */
.collaborations-grid {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 3rem;
    flex-wrap: wrap;
}

.collaboration-logo {
    height: 60px;
    width: auto;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: all 0.3s ease;
    /* mix-blend-mode: multiply;  Better integration with white bg if logos have white bg */
}

.collaboration-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
    transform: scale(1.05);
}

/* Curso activo layout */
.curso-activo-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 3rem;
    align-items: start;
    max-width: 1000px;
    margin: 0 auto;
}

@media (max-width: 700px) {
    .curso-activo-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .curso-activo-layout img {
        max-width: 320px;
        margin: 0 auto;
        display: block;
    }
}