/* ========================================
   IAF CertSearch - Custom Styles
   Built with Bootstrap 5 + Custom Variables
   ======================================== */

/* ===== CSS VARIABLES (IAF Color Palette) ===== */
:root {
    /* Primary Colors */
    --color-primary: #5dc6c8;
    --color-primary-hover: #4ab5b7;
    --color-primary-light: rgba(93, 198, 200, 0.1);

    /* Text Colors */
    --color-foreground: #536d7a;
    --color-muted: #828485;
    --color-muted-bg: #f0f4f5;

    /* Background Colors */
    --color-bg-white: #ffffff;
    --color-bg-light: #f9f9fb;
    --color-bg-gradient-start: #f0f4f5;
    --color-bg-gradient-end: #ffffff;

    /* Border & Inputs */
    --color-border: #e5e7eb;
    --color-input-border: #d1d5db;

    /* Spacing */
    --border-radius: 0.5rem;
    --border-radius-lg: 1rem;
    --border-radius-pill: 50rem;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* ===== TYPOGRAPHY ===== */
body {
    font-family: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--color-foreground);
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--color-foreground);
}

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

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

/* ===== NAVIGATION ===== */
.navbar {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.navbar-brand img {
    transition: transform 0.3s ease;
}

.navbar-brand:hover img {
    transform: scale(1.05);
}

.nav-link-custom {
    color: var(--color-foreground) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    transition: color 0.2s ease;
    position: relative;
}

.nav-link-custom:hover {
    color: var(--color-primary) !important;
}

.nav-link-custom.active {
    color: var(--color-primary) !important;
    border-bottom: 2px solid var(--color-primary);
}

/* ===== BUTTONS ===== */
.btn-custom-primary {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
    font-weight: 600;
    padding: 0.625rem 1.5rem;
    border-radius: var(--border-radius);
    transition: all 0.2s ease;
}

.btn-custom-primary:hover {
    background-color: var(--color-primary-hover);
    border-color: var(--color-primary-hover);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(93, 198, 200, 0.3);
}

.btn-outline-primary.btn-custom-outline {
    border-color: var(--color-primary);
    color: var(--color-primary);
    font-weight: 600;
    padding: 0.625rem 1.5rem;
    border-radius: var(--border-radius);
    transition: all 0.2s ease;
}

.btn-outline-primary.btn-custom-outline:hover {
    background-color: var(--color-primary-light);
    border-color: var(--color-primary);
    color: var(--color-primary);
}

/* ===== HERO SECTION ===== */
.hero-section {
    background-image: url('../images/homepage-hero-bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    padding-top: 4rem;
    padding-bottom: 4rem;
}

/* Overlay opcional para mejorar legibilidad del texto */
.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, rgba(240, 244, 245, 0.85) 0%, rgba(255, 255, 255, 0.9) 100%);
    z-index: 1;
}

.hero-section > * {
    position: relative;
    z-index: 2;
}

.hero-section h1 {
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

/* ===== SEARCH BAR ===== */
.search-container {
    margin-bottom: 2rem;
}

.search-input {
    border: 2px solid var(--color-primary);
    border-radius: var(--border-radius-pill);
    padding: 0.875rem 180px 0.875rem 1.5rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: var(--color-primary-hover);
    box-shadow: 0 0 0 4px var(--color-primary-light);
}

.btn-search {
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--color-primary);
    border: none;
    border-radius: var(--border-radius-pill);
    padding: 0.625rem 1.5rem;
    color: white;
    font-weight: 600;
    transition: all 0.2s ease;
}

.btn-search:hover {
    background-color: var(--color-primary-hover);
    transform: translateY(-50%) scale(1.02);
}

/* ===== STATISTICS ===== */
.stat-link {
    transition: all 0.2s ease;
    display: block;
}

.stat-link:hover {
    transform: translateY(-2px);
}

.stat-link:hover h2 {
    text-decoration: underline;
}

/* ===== CARDS ===== */
.help-card {
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    background-color: white;
}

.help-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.testimonial-card {
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    background-color: white;
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    box-shadow: var(--shadow-md);
}

/* ===== ICONS ===== */
.icon-circle {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background-color: var(--color-primary-light);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.icon-circle i {
    font-size: 32px;
    color: var(--color-primary);
}

.icon-circle-sm {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--color-primary-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

/* ===== COMPANY LOGOS ===== */
.company-logo {
    height: 40px;
    opacity: 0.7;
    transition: opacity 0.2s ease;
    filter: grayscale(100%);
}

.company-logo:hover {
    opacity: 1;
    filter: grayscale(0%);
}

/* ===== CTA BOX ===== */
.cta-box {
    border: 2px solid var(--color-primary);
    border-radius: var(--border-radius-lg);
    background-color: white;
}

/* ===== INDUSTRIES SECTION ===== */
.industry-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: var(--border-radius);
    transition: background-color 0.2s ease;
}

.industry-item:hover {
    background-color: rgba(93, 198, 200, 0.05);
}

.industry-icon {
    font-size: 24px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-primary-light);
    border-radius: 50%;
    flex-shrink: 0;
}

.industry-text {
    font-weight: 500;
    color: var(--color-foreground);
}

/* ===== SOCIAL ICONS ===== */
.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--color-muted-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-foreground);
    text-decoration: none;
    transition: all 0.2s ease;
}

.social-icon:hover {
    background-color: var(--color-primary);
    color: white;
    transform: translateY(-2px);
}

.social-icon i {
    font-size: 18px;
}

/* ===== DROPDOWN MENU ===== */
.dropdown-menu {
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
    border-radius: var(--border-radius);
}

.dropdown-item {
    color: var(--color-foreground);
    font-weight: 500;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background-color: var(--color-primary-light);
    color: var(--color-primary);
}

/* ===== FOOTER ===== */
footer a:hover {
    color: var(--color-primary) !important;
    text-decoration: underline !important;
}

/* ===== RESPONSIVE ADJUSTMENTS ===== */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2.5rem !important;
    }

    .search-input {
        padding-right: 1.5rem;
        margin-bottom: 1rem;
    }

    .btn-search {
        position: static;
        transform: none;
        width: 100%;
        margin-top: 0.5rem;
    }

    .display-3 {
        font-size: 2.5rem;
    }

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

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

@media (min-width: 768px) {
    .search-container {
        max-width: 700px;
    }
}

/* ===== UTILITIES ===== */
.bg-gradient-custom {
    background: linear-gradient(180deg, var(--color-bg-gradient-start) 0%, var(--color-bg-gradient-end) 100%);
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.6s ease-out;
}

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

/* ===== FOCUS STATES (Accessibility) ===== */
a:focus,
button:focus,
input:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

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