/* ===========================
   TRRD Consultores - Custom Styles
   Bootstrap 5 Enhancement
   =========================== */

/* --- VARIABLES CSS --- */
:root {
    --primary-color: #14b8a6;
    --primary-dark: #0d9488;
    --primary-light: #5eead4;
    --secondary-color: #0f172a;
    --success-color: #10b981;
    --info-color: #7baed4;
    --dark-bg: #0f172a;
    --dark-surface: #1e293b;
    --spacing-unit: 5rem;
}

/* --- FONTS --- */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: 'Montserrat', sans-serif;
}

/* --- UTILITIES --- */
.py-6 {
    padding-top: var(--spacing-unit);
    padding-bottom: var(--spacing-unit);
}

.ls-wider {
    letter-spacing: 0.1em;
}

.text-white-75 {
    color: rgba(255, 255, 255, 0.75);
}

/* --- CUSTOM BOOTSTRAP COLORS --- */
.bg-info {
    background-color: var(--info-color) !important;
}

.text-primary {
    color: var(--primary-color) !important;
}

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

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

.border-primary {
    border-color: var(--primary-color) !important;
}

/* --- BADGES --- */
.badge-primary-soft {
    background-color: rgba(20, 184, 166, 0.1);
    color: var(--primary-color);
    padding: 0.5rem 1rem;
    border-radius: 50rem;
    border: 1px solid rgba(20, 184, 166, 0.2);
}

.badge-success-soft {
    background-color: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
    padding: 0.5rem 1rem;
    border-radius: 50rem;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

/* --- NAVBAR --- */
.navbar {
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.navbar-brand {
    font-family: 'Montserrat', sans-serif;
    transition: transform 0.3s ease;
}

.navbar-brand:hover {
    transform: translateY(-2px);
}

.brand-icon {
    width: 40px;
    height: 40px;
    background-color: rgba(20, 184, 166, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.nav-link {
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* --- HERO SECTION --- */
.hero-section {
    min-height: 100vh;
    padding-top: 80px;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(15, 23, 42, 0.7) 100%);
    z-index: 1;
}

.check-circle {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(16, 185, 129, 0.1);
    border-radius: 50%;
    flex-shrink: 0;
}

/* --- CONTACT CARD --- */
.contact-card {
    border-radius: 2.5rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
}

.form-control,
.form-control:focus {
    border: 1px solid #e2e8f0;
}

.form-control:focus {
    box-shadow: 0 0 0 0.2rem rgba(20, 184, 166, 0.25);
    border-color: var(--primary-color);
}

/* --- SERVICE CARDS --- */
.service-card {
    border-radius: 2.5rem;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25) !important;
}

.card-img-wrapper {
    height: 220px;
    overflow: hidden;
}

.card-img-wrapper img {
    transition: transform 0.7s ease;
}

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

/* --- STEP CARDS --- */
.step-card {
    position: relative;
    padding: 3rem 2rem;
    background-color: #f8fafc;
    border-radius: 2rem;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.step-card:hover {
    background-color: #fff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-color: rgba(20, 184, 166, 0.1);
    transform: translateY(-5px);
}

.step-number {
    position: absolute;
    top: -1.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 3.5rem;
    height: 3.5rem;
    background-color: var(--primary-color);
    color: white;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.25rem;
    box-shadow: 0 8px 16px rgba(20, 184, 166, 0.3);
    transition: transform 0.3s ease;
}

.step-card:hover .step-number {
    transform: translateX(-50%) scale(1.1);
}

.divider-primary {
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

/* --- FEATURE CARDS --- */
.feature-card {
    padding: 2.5rem;
    background-color: #fff;
    border-radius: 2.5rem;
    border-left: 10px solid var(--success-color);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.feature-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    transform: translateX(-5px);
}

.feature-card:hover h3 {
    color: var(--success-color);
}

.standards-logos {
    opacity: 0.4;
    filter: grayscale(100%);
    transition: all 0.5s ease;
}

.standards-logos:hover {
    opacity: 1;
    filter: grayscale(0%);
}

.standard-logo {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

/* --- PRICING CARDS --- */
.pricing-card {
    border-radius: 2.5rem;
    transition: all 0.5s ease;
    position: relative;
}

.pricing-card:hover {
    transform: translateY(-10px);
}

.pricing-card-featured {
    transform: scale(1.05);
}

.pricing-badge {
    position: absolute;
    top: -1rem;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--primary-color);
    color: white;
    padding: 0.5rem 1.5rem;
    border-radius: 50rem;
    font-size: 0.7rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    box-shadow: 0 4px 12px rgba(20, 184, 166, 0.4);
}

.pricing-icon {
    width: 60px;
    height: 60px;
    border-radius: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    background-color: #f8fafc;
    transition: transform 0.5s ease;
}

.pricing-card:hover .pricing-icon {
    transform: scale(1.1) rotate(5deg);
}

/* --- STATS SECTION --- */
.stat-card {
    padding: 3rem;
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.5s ease;
}

.stat-card:hover {
    transform: scale(1.05);
}

/* --- TEAM SECTION --- */
.team-img-wrapper {
    position: relative;
    border-radius: 2rem;
    overflow: hidden;
}

.team-img-wrapper img {
    transition: transform 0.5s ease;
}

.team-img-wrapper:hover img {
    transform: scale(1.05);
}

.team-badge {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 0.75rem 1.25rem;
    border-radius: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feature-box {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    background-color: #f8fafc;
    border-radius: 1.5rem;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.feature-box:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* --- FAQ ACCORDION --- */
.accordion-item {
    border: none;
    margin-bottom: 1rem;
    border-radius: 1.5rem;
    overflow: hidden;
    background-color: #f8fafc;
    transition: all 0.3s ease;
}

.accordion-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.accordion-button {
    background-color: transparent;
    border: none;
    border-radius: 1.5rem;
    padding: 1.5rem;
    font-size: 1rem;
}

.accordion-button:not(.collapsed) {
    background-color: transparent;
    color: var(--primary-color);
    box-shadow: none;
}

.accordion-button::after {
    background-image: none;
    content: '+';
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.accordion-button:not(.collapsed)::after {
    content: '−';
    transform: rotate(0deg);
}

.accordion-button:focus {
    box-shadow: none;
    border-color: transparent;
}

.accordion-body {
    padding: 0 1.5rem 1.5rem 1.5rem;
}

/* --- CONTACT INFO SECTION --- */
.contact-info-section {
    background-color: var(--info-color);
}

.contact-image-wrapper {
    height: 100%;
    min-height: 500px;
}

.contact-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.contact-info-content {
    padding: 4rem;
    color: white;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.contact-info-item {
    margin-bottom: 1rem;
}

.contact-link {
    color: white;
    text-decoration: none;
    font-weight: 300;
    transition: all 0.3s ease;
    display: inline-block;
}

.contact-link:hover {
    color: white;
    text-decoration: underline;
    text-underline-offset: 4px;
    transform: translateX(5px);
}

/* --- FOOTER --- */
.footer {
    background-color: var(--dark-bg);
    color: #cbd5e1;
}

.footer .text-muted {
    color: #cbd5e1 !important;
}

.footer a {
    color: #cbd5e1;
}

.footer a:hover {
    color: var(--primary-color);
}

/* --- DARK MODE --- */
[data-bs-theme="dark"] body {
    background-color: var(--dark-bg);
    color: #e2e8f0;
}

[data-bs-theme="dark"] .navbar {
    background-color: rgba(15, 23, 42, 0.9) !important;
}

[data-bs-theme="dark"] .contact-card {
    background: rgba(30, 41, 59, 0.95);
}

[data-bs-theme="dark"] .service-card,
[data-bs-theme="dark"] .pricing-card,
[data-bs-theme="dark"] .feature-card,
[data-bs-theme="dark"] .feature-box {
    background-color: var(--dark-surface);
    border-color: #334155;
}

[data-bs-theme="dark"] .step-card {
    background-color: var(--dark-surface);
}

[data-bs-theme="dark"] .step-card:hover {
    background-color: #1e293b;
}

[data-bs-theme="dark"] .accordion-item {
    background-color: var(--dark-surface);
}

[data-bs-theme="dark"] .form-control {
    background-color: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-bs-theme="dark"] .pricing-icon {
    background-color: #1e293b;
}

/* --- SMOOTH SCROLL --- */
html {
    scroll-behavior: smooth;
}

/* Scroll padding for fixed navbar */
section {
    scroll-margin-top: 80px;
}

/* --- ANIMATIONS --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

/* --- RESPONSIVE --- */
@media (max-width: 991px) {
    .hero-section {
        padding-top: 100px;
    }

    .contact-info-content {
        padding: 3rem 2rem;
    }

    .contact-image-wrapper {
        min-height: 300px;
    }

    .py-6 {
        padding-top: 4rem;
        padding-bottom: 4rem;
    }
}

@media (max-width: 767px) {
    .display-1 {
        font-size: 3rem;
    }

    .display-4 {
        font-size: 2rem;
    }

    .display-5 {
        font-size: 1.75rem;
    }

    .pricing-card-featured {
        transform: scale(1);
    }

    .py-6 {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }
}

/* --- PRINT STYLES --- */
@media print {
    .navbar,
    .footer {
        display: none;
    }
}