/* ============================================================
   Transportes Barrientos — Coming Soon
   ============================================================ */

:root {
    --tb-azul-oscuro: #0f1d33;
    --tb-azul: #1a2942;
    --tb-azul-claro: #4a7bb8;
    --tb-naranjo: #ff8c42;
    --tb-naranjo-claro: #ffb27d;
    --tb-amarillo: #fde047;
    --tb-blanco: #ffffff;
    --tb-gris-claro: rgba(255, 255, 255, 0.08);
    --tb-text: rgba(255, 255, 255, 0.92);
    --tb-text-soft: rgba(255, 255, 255, 0.65);
    --tb-text-faint: rgba(255, 255, 255, 0.4);

    --shadow-glow: 0 20px 60px rgba(255, 140, 66, 0.25);
    --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.25);
}

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

html, body {
    min-height: 100vh;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--tb-text);
    background: var(--tb-azul-oscuro);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

body {
    position: relative;
    display: flex;
    flex-direction: column;
}

/* ===== Background animado ===== */

.bg-gradient {
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(ellipse at top left, rgba(74, 123, 184, 0.4) 0%, transparent 40%),
        radial-gradient(ellipse at bottom right, rgba(255, 140, 66, 0.3) 0%, transparent 50%),
        radial-gradient(ellipse at center, rgba(26, 41, 66, 0.5) 0%, transparent 60%),
        linear-gradient(135deg, #0a1424 0%, #1a2942 50%, #0f1d33 100%);
    animation: gradientShift 20s ease-in-out infinite;
}

@keyframes gradientShift {
    0%, 100% { filter: hue-rotate(0deg); }
    50% { filter: hue-rotate(15deg); }
}

/* Particulas (cajas/paquetes flotando) */
.bg-particles {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}
.bg-particles span {
    position: absolute;
    bottom: -80px;
    width: 14px;
    height: 14px;
    background: var(--tb-naranjo);
    opacity: 0.15;
    border-radius: 2px;
    animation: float linear infinite;
}
.bg-particles span:nth-child(1)  { left:  4%; width: 18px; height: 18px; animation-duration: 22s; animation-delay: 0s;   background: var(--tb-naranjo); }
.bg-particles span:nth-child(2)  { left: 12%; width: 10px; height: 10px; animation-duration: 28s; animation-delay: 3s;   background: var(--tb-azul-claro); }
.bg-particles span:nth-child(3)  { left: 22%; width: 22px; height: 22px; animation-duration: 18s; animation-delay: 7s;   background: var(--tb-naranjo); }
.bg-particles span:nth-child(4)  { left: 32%; width: 12px; height: 12px; animation-duration: 26s; animation-delay: 1s;   background: var(--tb-amarillo); opacity: .1; }
.bg-particles span:nth-child(5)  { left: 42%; width: 16px; height: 16px; animation-duration: 24s; animation-delay: 5s;   background: var(--tb-naranjo); }
.bg-particles span:nth-child(6)  { left: 52%; width: 10px; height: 10px; animation-duration: 30s; animation-delay: 9s;   background: var(--tb-azul-claro); }
.bg-particles span:nth-child(7)  { left: 62%; width: 20px; height: 20px; animation-duration: 20s; animation-delay: 2s;   background: var(--tb-naranjo); }
.bg-particles span:nth-child(8)  { left: 70%; width: 14px; height: 14px; animation-duration: 27s; animation-delay: 6s;   background: var(--tb-naranjo-claro); }
.bg-particles span:nth-child(9)  { left: 78%; width: 18px; height: 18px; animation-duration: 23s; animation-delay: 8s;   background: var(--tb-naranjo); }
.bg-particles span:nth-child(10) { left: 86%; width: 12px; height: 12px; animation-duration: 25s; animation-delay: 4s;   background: var(--tb-azul-claro); }
.bg-particles span:nth-child(11) { left:  8%; width:  8px; height:  8px; animation-duration: 32s; animation-delay: 11s;  background: var(--tb-amarillo); opacity: .08; }
.bg-particles span:nth-child(12) { left: 28%; width: 14px; height: 14px; animation-duration: 21s; animation-delay: 13s;  background: var(--tb-naranjo); }
.bg-particles span:nth-child(13) { left: 48%; width:  6px; height:  6px; animation-duration: 35s; animation-delay: 15s;  background: var(--tb-azul-claro); opacity: .2; }
.bg-particles span:nth-child(14) { left: 68%; width: 16px; height: 16px; animation-duration: 19s; animation-delay: 10s;  background: var(--tb-naranjo); }
.bg-particles span:nth-child(15) { left: 92%; width: 10px; height: 10px; animation-duration: 29s; animation-delay: 14s;  background: var(--tb-naranjo-claro); }

@keyframes float {
    0% {
        transform: translateY(0) rotate(0deg);
        opacity: 0;
    }
    10% { opacity: 0.15; }
    50% { opacity: 0.25; }
    90% { opacity: 0.1; }
    100% {
        transform: translateY(-110vh) rotate(720deg);
        opacity: 0;
    }
}

/* ===== Topbar ===== */

.topbar {
    position: relative;
    z-index: 10;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 40px;
    max-width: 1280px;
    margin: 0 auto;
    width: 100%;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--tb-text);
}

.brand-mark {
    width: 44px; height: 44px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--tb-naranjo), var(--tb-naranjo-claro));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #fff;
    box-shadow: var(--shadow-glow);
    animation: pulse 3s ease-in-out infinite;
}
@keyframes pulse {
    0%, 100% { transform: scale(1); box-shadow: 0 8px 24px rgba(255, 140, 66, 0.25); }
    50%      { transform: scale(1.06); box-shadow: 0 16px 40px rgba(255, 140, 66, 0.45); }
}

.brand-text {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 18px;
    font-weight: 600;
    letter-spacing: 0.2px;
}
.brand-text strong {
    color: var(--tb-naranjo);
    font-weight: 800;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--tb-gris-claro);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    font-size: 13px;
    font-weight: 500;
    color: var(--tb-text-soft);
    backdrop-filter: blur(10px);
}
.status-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--tb-naranjo);
    box-shadow: 0 0 12px var(--tb-naranjo);
    animation: blink 1.5s ease-in-out infinite;
}
@keyframes blink {
    0%, 100% { opacity: 1; }
    50%      { opacity: 0.3; }
}

/* ===== Hero ===== */

.hero {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 24px 80px;
    position: relative;
    z-index: 1;
}

.hero-inner {
    max-width: 920px;
    width: 100%;
    text-align: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: linear-gradient(135deg, rgba(255, 140, 66, 0.18), rgba(255, 140, 66, 0.08));
    border: 1px solid rgba(255, 140, 66, 0.4);
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    color: var(--tb-naranjo-claro);
    margin-bottom: 28px;
    animation: badgeIn .8s ease-out;
}
.hero-badge i { font-size: 14px; }

@keyframes badgeIn {
    from { opacity: 0; transform: translateY(20px) scale(.9); }
    to   { opacity: 1; transform: translateY(0)    scale(1); }
}

.hero-title {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: clamp(2.4rem, 6vw, 4.5rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.03em;
    margin-bottom: 24px;
    animation: titleIn 1s ease-out .1s both;
}
.text-gradient {
    background: linear-gradient(135deg, var(--tb-naranjo) 0%, var(--tb-naranjo-claro) 50%, var(--tb-amarillo) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: gradientText 4s ease-in-out infinite;
}
@keyframes gradientText {
    0%, 100% { background-position: 0% 50%; }
    50%      { background-position: 100% 50%; }
}

@keyframes titleIn {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    line-height: 1.6;
    color: var(--tb-text-soft);
    max-width: 640px;
    margin: 0 auto 48px;
    animation: titleIn 1s ease-out .25s both;
}

/* ===== Countdown ===== */

.countdown {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-bottom: 48px;
    animation: titleIn 1s ease-out .4s both;
    flex-wrap: wrap;
}
.countdown-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    min-width: 88px;
    padding: 18px 12px;
    background: linear-gradient(180deg, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.03) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-card);
    transition: transform .3s ease;
}
.countdown-item:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 140, 66, 0.4);
}
.countdown-value {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    line-height: 1;
    color: #fff;
    font-variant-numeric: tabular-nums;
    background: linear-gradient(180deg, #fff 0%, var(--tb-naranjo-claro) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.countdown-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--tb-text-faint);
    font-weight: 600;
}
.countdown-sep {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 300;
    color: var(--tb-naranjo);
    margin: 0 -2px;
    align-self: flex-start;
    padding-top: 18px;
    animation: blink 1.5s ease-in-out infinite;
}

/* ===== Lead form ===== */

.lead-form {
    max-width: 560px;
    margin: 0 auto 80px;
    animation: titleIn 1s ease-out .55s both;
}
.lead-form-row {
    display: flex;
    gap: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    padding: 6px;
    backdrop-filter: blur(10px);
    transition: all .3s ease;
}
.lead-form-row:focus-within {
    border-color: var(--tb-naranjo);
    box-shadow: 0 0 0 4px rgba(255, 140, 66, 0.15);
}
.lead-form-input {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 16px;
}
.lead-form-input i {
    color: var(--tb-text-faint);
    font-size: 18px;
}
.lead-form-input input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #fff;
    font-size: 15px;
    padding: 14px 0;
    font-family: inherit;
}
.lead-form-input input::placeholder {
    color: var(--tb-text-faint);
}
.lead-form-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 24px;
    background: linear-gradient(135deg, var(--tb-naranjo), var(--tb-naranjo-claro));
    border: none;
    border-radius: 10px;
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: all .3s ease;
    font-family: inherit;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}
.lead-form-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--tb-naranjo-claro), var(--tb-naranjo));
    opacity: 0;
    transition: opacity .3s ease;
}
.lead-form-btn:hover::before { opacity: 1; }
.lead-form-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(255, 140, 66, 0.4);
}
.lead-form-btn .btn-label,
.lead-form-btn .btn-icon {
    position: relative;
    z-index: 1;
    transition: transform .3s ease;
}
.lead-form-btn:hover .btn-icon {
    transform: translateX(4px);
}
.lead-form-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.lead-form-msg {
    margin-top: 12px;
    font-size: 13px;
    min-height: 20px;
    text-align: center;
    transition: all .3s ease;
}
.lead-form-msg.success { color: #4ade80; }
.lead-form-msg.error   { color: #f87171; }

.lead-form-hint {
    margin-top: 8px;
    font-size: 12px;
    color: var(--tb-text-faint);
    text-align: center;
}

/* ===== Servicios ===== */

.services {
    margin-bottom: 80px;
}
.services-title {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 2.5px;
    color: var(--tb-text-faint);
    font-weight: 600;
    margin-bottom: 32px;
}
.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
.service-card {
    padding: 28px 20px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    backdrop-filter: blur(10px);
    transition: all .4s ease;
    animation: cardIn .8s ease-out var(--delay, 0s) both;
    position: relative;
    overflow: hidden;
}
.service-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 140, 66, 0.1), transparent);
    opacity: 0;
    transition: opacity .4s ease;
}
.service-card:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 140, 66, 0.4);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}
.service-card:hover::before { opacity: 1; }
.service-card:hover .service-icon {
    transform: scale(1.1) rotate(-5deg);
    color: var(--tb-naranjo);
}

.service-icon {
    width: 52px; height: 52px;
    border-radius: 12px;
    background: rgba(255, 140, 66, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--tb-naranjo-claro);
    margin: 0 auto 16px;
    transition: all .4s ease;
    position: relative;
    z-index: 1;
}
.service-card h3 {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 6px;
    position: relative;
    z-index: 1;
}
.service-card p {
    font-size: 13px;
    color: var(--tb-text-soft);
    line-height: 1.5;
    position: relative;
    z-index: 1;
}

@keyframes cardIn {
    from { opacity: 0; transform: translateY(40px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ===== Camion en carretera ===== */

.road-scene {
    position: relative;
    height: 100px;
    margin: 0 -24px 40px;
    overflow: hidden;
}
.road {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
}
.road-line {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    height: 2px;
    width: 100%;
    background-image: repeating-linear-gradient(
        to right,
        var(--tb-naranjo) 0px,
        var(--tb-naranjo) 20px,
        transparent 20px,
        transparent 40px
    );
    animation: roadMove 1.5s linear infinite;
}
@keyframes roadMove {
    from { background-position: 0 0; }
    to   { background-position: -40px 0; }
}

.truck {
    position: absolute;
    bottom: 8px;
    left: -200px;
    width: 160px;
    animation: truckDrive 14s linear infinite;
}
.truck svg { width: 100%; height: auto; display: block; }
.truck:hover { animation-play-state: paused; }

@keyframes truckDrive {
    0%   { transform: translateX(0); }
    100% { transform: translateX(calc(100vw + 200px)); }
}

.smoke {
    animation: smokePuff 1s ease-out infinite;
    transform-origin: center;
}
.smoke-2 { animation-delay: .15s; }
.smoke-3 { animation-delay: .3s; }
@keyframes smokePuff {
    0%   { opacity: .5; transform: translate(0, 0) scale(1); }
    100% { opacity: 0;  transform: translate(-15px, -15px) scale(1.6); }
}

/* ===== Footer ===== */

.footer {
    padding: 32px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
}
.footer-content {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}
.footer-info {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    font-size: 13px;
    color: var(--tb-text-soft);
}
.footer-info a {
    color: var(--tb-naranjo-claro);
    text-decoration: none;
    transition: color .2s ease;
}
.footer-info a:hover { color: var(--tb-naranjo); }
.footer-copy {
    font-size: 12px;
    color: var(--tb-text-faint);
}

/* ===== Responsive ===== */

@media (max-width: 768px) {
    .topbar { padding: 16px 20px; }
    .brand-text { font-size: 16px; }
    .hero { padding: 24px 16px 60px; }
    .countdown { gap: 4px; }
    .countdown-item { min-width: 70px; padding: 14px 8px; }
    .countdown-sep { display: none; }
    .lead-form-row { flex-direction: column; gap: 6px; }
    .lead-form-input { padding: 0 14px; }
    .lead-form-btn { width: 100%; justify-content: center; padding: 12px; }
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-content { flex-direction: column; text-align: center; }
}

@media (max-width: 420px) {
    .services-grid { grid-template-columns: 1fr; }
}

/* Reducir movimiento si el usuario lo prefiere */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
    .truck { animation: none; left: 50%; transform: translateX(-50%); }
}
