/* ---- FUENTES Y ESTILOS BASE ---- */
body {
    font-family: 'Inter', sans-serif;
    background-color: #121212;
}

h1, h2, h3, h4, h5, .navbar-brand, .card-title {
    font-family: 'Fira Sans', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
}

.text-muted {
    color: rgba(255, 255, 255, 0.5) !important;
}


/* ---- COMPONENTES GLOBALES ---- */

.navbar {
    backdrop-filter: blur(10px);
    transition: background-color 0.4s ease, padding 0.4s ease;
}

.navbar-scrolled {
    background-color: rgba(18, 18, 18, 0.95) !important;
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

.nav-link {
    text-transform: uppercase;
    font-weight: bold;
    color: #f0f0f0;
    transition: color 0.3s ease;
}

.nav-link:hover, .nav-link.active {
    color: #2007ff;
}

.hero-section {
    border-bottom: 3px solid;
    border-image-slice: 1;
    border-image-source: linear-gradient(to right, #007bff, #2007ff);
}

.hero-section .lead {
    color: #e0e0e0;
}

.card {
    background: rgba(35, 35, 40, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

.btn-primary {
    background: linear-gradient(45deg, #007bff, #2007ff);
    border: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px 0 rgba(0, 123, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px 0 rgba(32, 7, 255, 0.4);
}

/* ---- REGLAS DE COLOR PARA TARJETAS ---- */

.card .card-title,
.card h3,
.card h5,
.card .form-label {
  color: #f8f9fa !important;
}

.card .card-text,
.card p,
.card .blockquote,
.card .blockquote-footer {
    color: #ced4da !important;
}

/* ---- ESTILOS DE SECCIONES ESPECÍFICAS ---- */

/* Galería de Proyectos */
.gallery-item {
    text-decoration: none;
    display: block;
}

.gallery-item:hover .card {
    transform: scale(1.05) translateY(-5px);
    box-shadow: 0 8px 40px rgba(32, 7, 255, 0.5);
    border-color: rgba(0, 123, 255, 0.5);
    will-change: transform, box-shadow;
}

.feature-icon-box .fas,
.card .info-directa .fas { /* Usamos una clase nueva para ser más específicos */
    color: #2007ff !important; /* Forzamos el color azul brillante */
    transition: color 0.3s ease, transform 0.3s ease;
}

.card .info-directa .fas {
    width: 20px;
    text-align: center;
}

.card:hover .feature-icon-box .fas {
    color: #ffffff !important;
    transform: scale(1.1);
}

/* Formulario de Contacto */
.card .form-control,
.card .form-select {
    background-color: rgba(0, 0, 0, 0.25);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.form-control:focus,
.form-select:focus {
    background-color: #343a40;
    color: #fff;
    border-color: #007bff;
    box-shadow: 0 0 15px 0 rgba(0, 123, 255, 0.5);
}

.form-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23ced4da' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}

.card .ratio iframe {
    border-radius: var(--bs-card-inner-border-radius, 0.375rem);
}

/* ---- UTILIDADES Y HELPERS ---- */

#backToTopBtn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#backToTopBtn.visible {
    opacity: 1;
    visibility: visible;
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #121212;
}

::-webkit-scrollbar-thumb {
    background-color: #343a40;
    border-radius: 20px;
    border: 2px solid #121212;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #2007ff;
}

.gradient-text {
    background: linear-gradient(to right, #ffffff, #b3b3b3);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}