/* Homepage styles. Builds on model-page.css (load that first). */

/* ---------- HERO SLIDER ---------- */
.hm-hero {
    position: relative;
    height: clamp(560px, 86vh, 880px);
    overflow: hidden;
    background: #050505;
}

.hm-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 1.2s ease, visibility 1.2s ease;
}

.hm-slide.active {
    opacity: 1;
    visibility: visible;
    z-index: 1;
}

.hm-slide > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.18);
    transition: transform 7s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.hm-slide.active > img {
    transform: scale(1);
}

.hm-slide::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(5, 5, 5, 0.94) 0%, rgba(5, 5, 5, 0.7) 40%, rgba(5, 5, 5, 0.15) 100%),
        linear-gradient(0deg, #050505 0%, transparent 35%),
        radial-gradient(circle at 15% 60%, rgba(225, 6, 0, 0.25), transparent 45%);
}

.hm-hero-content {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
}

.hm-hero-text {
    max-width: 640px;
    padding-bottom: 110px;
}

.hm-hero-text .hx-hero-title {
    font-size: clamp(40px, 6.5vw, 84px);
}

.hm-hero-text .hx-lead {
    color: #d0d0d0;
    font-size: clamp(15px, 1.4vw, 18px);
    max-width: 520px;
}

.hm-anim {
    opacity: 0;
    transform: translateY(30px);
}

.hm-slide.active .hm-anim {
    animation: hmUp 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}

.hm-slide.active .hm-anim:nth-child(2) { animation-delay: 0.15s; }
.hm-slide.active .hm-anim:nth-child(3) { animation-delay: 0.3s; }
.hm-slide.active .hm-anim:nth-child(4) { animation-delay: 0.45s; }

@keyframes hmUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hm-hero-watermark {
    position: absolute;
    right: -2%;
    bottom: 6%;
    z-index: 2;
    font-size: clamp(80px, 14vw, 220px);
    font-weight: 900;
    font-style: italic;
    letter-spacing: -6px;
    line-height: 1;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.08);
    pointer-events: none;
    user-select: none;
}

.hm-hero-controls {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 90px;
    z-index: 3;
}

.hm-hero-controls .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.hm-dots {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hm-dot {
    position: relative;
    width: 56px;
    height: 4px;
    border: 0;
    padding: 0;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.25);
    overflow: hidden;
    cursor: pointer;
}

.hm-dot span {
    position: absolute;
    inset: 0;
    width: 0;
    background: var(--hx-red);
}

.hm-dot.active span {
    animation: hmProgress var(--hm-delay, 6s) linear forwards;
}

.hm-hero.is-paused .hm-dot.active span {
    animation-play-state: paused;
}

@keyframes hmProgress {
    to {
        width: 100%;
    }
}

.hm-counter {
    color: #9a9a9a;
    font-weight: 700;
    letter-spacing: 2px;
    font-size: 14px;
    margin-left: 10px;
}

.hm-counter strong {
    color: #fff;
}

/* ---------- FEATURES STRIP ---------- */
.hm-features {
    position: relative;
    z-index: 4;
    margin-top: -60px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.hm-feature {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 22px;
    background: rgba(16, 16, 16, 0.92);
    backdrop-filter: blur(8px);
    border: 1px solid var(--hx-border);
    border-top: 3px solid var(--hx-red);
    border-radius: 14px;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.hm-feature:hover {
    transform: translateY(-4px);
    border-color: var(--hx-red);
}

.hm-feature i {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(225, 6, 0, 0.12);
    color: var(--hx-red);
    font-size: 18px;
}

.hm-feature strong {
    display: block;
    font-size: 16px;
    color: #fff;
    margin-bottom: 2px;
}

.hm-feature span {
    color: #8f8f8f;
    font-size: 13px;
    line-height: 1.5;
}

/* ---------- NEW ARRIVALS ---------- */
.hm-launch-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.hm-launch {
    position: relative;
    display: flex;
    flex-direction: column;
    border-radius: 22px;
    overflow: hidden;
    text-decoration: none;
    color: #fff;
    background:
        radial-gradient(ellipse at 50% 38%, rgba(225, 6, 0, 0.35), transparent 60%),
        repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.015) 0 2px, transparent 2px 6px),
        #0c0c0c;
    border: 1px solid var(--hx-border);
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

.hm-launch:hover {
    color: #fff;
    transform: translateY(-6px);
    border-color: rgba(225, 6, 0, 0.6);
    box-shadow: 0 25px 50px rgba(225, 6, 0, 0.2);
}

.hm-launch-media {
    padding: 50px 30px 0;
    aspect-ratio: 16 / 10;
    min-height: 0;
}

.hm-launch-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 25px 30px rgba(0, 0, 0, 0.7));
    transform: scale(1.2);
    transition: transform 1.4s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.hm-launch.in-view .hm-launch-media img {
    transform: scale(1);
}

.hm-launch.in-view:hover .hm-launch-media img {
    transform: scale(1.06) translateY(-6px);
    transition-duration: 0.8s;
}

.hm-launch-body {
    padding: 10px 30px 30px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 16px;
}

.hm-launch-body h3 {
    font-size: clamp(26px, 3vw, 36px);
    font-weight: 900;
    margin: 6px 0 4px;
    text-transform: uppercase;
}

.hm-launch-body p {
    color: #a9a9a9;
    margin: 0;
    font-size: 14px;
}

.hm-new-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 2;
    padding: 6px 14px;
    border-radius: 50px;
    background: var(--hx-red);
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    box-shadow: 0 0 0 0 rgba(225, 6, 0, 0.6);
    animation: hmPulse 2s infinite;
}

@keyframes hmPulse {
    70% {
        box-shadow: 0 0 0 12px rgba(225, 6, 0, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(225, 6, 0, 0);
    }
}

.hm-go {
    width: 50px;
    height: 50px;
    flex: 0 0 50px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--hx-red);
    color: #fff;
    transition: transform 0.3s ease, background 0.3s ease;
}

.hm-launch:hover .hm-go,
.hm-bike:hover .hm-go {
    transform: translateX(4px) rotate(-45deg);
    background: #fff;
    color: var(--hx-red);
}

/* ---------- RANGE ---------- */
.hm-filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.hm-filter {
    padding: 10px 20px;
    border-radius: 50px;
    border: 1px solid #333;
    background: transparent;
    color: #bdbdbd;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.25s ease;
}

.hm-filter span {
    display: inline-block;
    min-width: 22px;
    margin-left: 6px;
    padding: 1px 6px;
    border-radius: 50px;
    background: rgba(255, 255, 255, 0.08);
    font-size: 12px;
}

.hm-filter:hover {
    color: #fff;
    border-color: #666;
}

.hm-filter.active {
    background: var(--hx-red);
    border-color: var(--hx-red);
    color: #fff;
}

.hm-filter.active span {
    background: rgba(0, 0, 0, 0.25);
}

.hm-range {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.hm-bike {
    position: relative;
    display: flex;
    flex-direction: column;
    border-radius: 18px;
    overflow: hidden;
    text-decoration: none;
    color: #fff;
    background: var(--hx-surface);
    border: 1px solid var(--hx-border);
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

.hm-bike:hover {
    color: #fff;
    transform: translateY(-6px);
    border-color: rgba(225, 6, 0, 0.6);
    box-shadow: 0 20px 45px rgba(225, 6, 0, 0.18);
}

.hm-bike::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 3px;
    background: var(--hx-red);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

.hm-bike:hover::after {
    transform: scaleX(1);
}

.hm-bike.is-hidden {
    display: none;
}

.hm-bike.is-shown {
    animation: hmFadeIn 0.5s ease backwards;
}

@keyframes hmFadeIn {
    from {
        opacity: 0;
        transform: translateY(16px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.hm-bike-stage {
    position: relative;
    aspect-ratio: 16 / 11;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background:
        radial-gradient(ellipse at 50% 60%, rgba(225, 6, 0, 0.22), transparent 65%),
        #0b0b0b;
    overflow: hidden;
}

.hm-bike-stage img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 18px 22px rgba(0, 0, 0, 0.7));
    transform: scale(1.18);
    transition: transform 1.4s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.hm-bike.in-view .hm-bike-stage img {
    transform: scale(1);
}

.hm-bike.in-view:hover .hm-bike-stage img {
    transform: scale(1.08);
    transition-duration: 0.8s;
}

.hm-bike-tag {
    position: absolute;
    top: 14px;
    left: 14px;
    padding: 4px 10px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    background: rgba(255, 255, 255, 0.08);
    color: #cfcfcf;
}

.hm-bike-tag.is-new {
    background: var(--hx-red);
    color: #fff;
}

.hm-bike-body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 20px 22px 22px;
    border-top: 1px solid var(--hx-border);
}

.hm-bike-body h3 {
    font-size: 20px;
    font-weight: 800;
    margin: 0 0 4px;
}

.hm-bike-price {
    color: #9a9a9a;
    font-size: 13px;
}

.hm-bike-price strong {
    color: #fff;
    font-size: 15px;
}

.hm-bike-price.is-prebook strong {
    color: var(--hx-red);
}

.hm-bike .hm-go {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
    font-size: 14px;
}

/* ---------- ACTION BAND ---------- */
.hm-actions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    margin-top: 34px;
}

.hm-action {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 22px;
    border-radius: 16px;
    background: rgba(0, 0, 0, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
}

.hm-action:hover {
    background: #fff;
    color: var(--hx-red);
    transform: translateY(-4px);
}

.hm-action i {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    font-size: 18px;
    transition: background 0.3s ease;
}

.hm-action:hover i {
    background: rgba(225, 6, 0, 0.12);
}

.hm-action strong {
    display: block;
    font-size: 17px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hm-action span {
    font-size: 13px;
    opacity: 0.85;
}

/* ---------- GALLERY ---------- */
.hm-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 220px;
    gap: 16px;
}

.hm-gallery .hx-card:hover {
    transform: none;
}

.hm-g-lg {
    grid-column: span 2;
    grid-row: span 2;
}

.hm-g-tall {
    grid-row: span 2;
}

.hm-g-wide {
    grid-column: span 2;
}

.hm-gallery .hx-card-body {
    padding: 50px 18px 16px;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.hm-gallery .hx-card:hover .hx-card-body,
.hm-gallery .hx-card:focus-within .hx-card-body {
    opacity: 1;
    transform: none;
}

.hm-gallery .hx-card-body h3 {
    font-size: 17px;
    margin: 0;
}

/* ---------- CONTACT ---------- */
.hm-contact {
    background: var(--hx-surface);
    border: 1px solid var(--hx-border);
    border-radius: 24px;
    overflow: hidden;
}

.hm-contact-info {
    height: 100%;
    display: flex;
    flex-direction: column;
    background:
        radial-gradient(circle at 0% 0%, rgba(225, 6, 0, 0.18), transparent 50%),
        #0b0b0b;
    border-right: 1px solid var(--hx-border);
}

.hm-contact-list {
    list-style: none;
    padding: 30px 30px 10px;
    margin: 0;
}

.hm-contact-list li {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 12px 0;
    color: #bdbdbd;
    font-size: 15px;
}

.hm-contact-list i {
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(225, 6, 0, 0.12);
    color: var(--hx-red);
}

.hm-contact-list strong {
    display: block;
    color: #fff;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hm-contact-list a {
    color: #bdbdbd;
    text-decoration: none;
    overflow-wrap: anywhere;
}

.hm-contact-list a:hover {
    color: var(--hx-red);
}

.hm-map {
    flex: 1;
    min-height: 260px;
    margin: 10px 30px 30px;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--hx-border);
}

.hm-map iframe {
    width: 100%;
    height: 100%;
    min-height: 260px;
    border: 0;
    display: block;
    filter: grayscale(0.4) contrast(1.05);
}

.hm-form {
    padding: 40px;
}

.hm-form h3 {
    font-size: clamp(24px, 3vw, 32px);
    font-weight: 800;
    margin: 10px 0 8px;
}

.hm-form h3 span {
    color: var(--hx-red);
}

.hm-form > p {
    color: var(--hx-text);
    margin-bottom: 26px;
}

.hm-field {
    position: relative;
    margin-bottom: 16px;
}

.hm-field i {
    position: absolute;
    left: 18px;
    top: 18px;
    color: #666;
    transition: color 0.25s ease;
}

.hm-field input,
.hm-field textarea {
    width: 100%;
    padding: 15px 18px 15px 48px;
    background: #0a0a0a;
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    color: #fff;
    font-size: 15px;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.hm-field textarea {
    resize: vertical;
    min-height: 130px;
}

.hm-field input::placeholder,
.hm-field textarea::placeholder {
    color: #6d6d6d;
}

.hm-field input:focus,
.hm-field textarea:focus {
    outline: none;
    border-color: var(--hx-red);
    box-shadow: 0 0 0 4px rgba(225, 6, 0, 0.15);
}

.hm-field:focus-within i {
    color: var(--hx-red);
}

.hm-form button[type="submit"] {
    border: 2px solid var(--hx-red);
    cursor: pointer;
}

.hm-form button[type="submit"]:disabled {
    opacity: 0.7;
    cursor: wait;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1199.98px) {
    .hm-features {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 991.98px) {
    .hm-hero {
        height: clamp(540px, 80vh, 760px);
    }

    .hm-slide::after {
        background:
            linear-gradient(0deg, #050505 0%, rgba(5, 5, 5, 0.75) 45%, rgba(5, 5, 5, 0.45) 100%),
            radial-gradient(circle at 50% 60%, rgba(225, 6, 0, 0.2), transparent 55%);
    }

    .hm-hero-text {
        margin: 0 auto;
        text-align: center;
    }

    .hm-hero-text .hx-lead {
        margin-left: auto;
        margin-right: auto;
    }

    .hm-hero-text .hx-actions {
        justify-content: center;
    }

    .hm-range {
        grid-template-columns: repeat(2, 1fr);
    }

    .hm-actions {
        grid-template-columns: 1fr;
    }

    .hm-gallery {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 200px;
    }

    .hm-g-tall {
        grid-row: span 1;
    }

    .hm-contact-info {
        border-right: none;
        border-bottom: 1px solid var(--hx-border);
    }
}

@media (max-width: 767.98px) {
    .hm-launch-grid {
        grid-template-columns: 1fr;
    }

    .hm-hero-controls {
        bottom: 80px;
    }

    .hm-hero-controls .container {
        justify-content: center;
    }

    .hm-hero-controls .hx-scroller-nav {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .hm-hero-text {
        padding-bottom: 120px;
    }

    .hm-hero-text .hx-actions .hx-btn {
        padding: 12px 22px;
        font-size: 14px;
    }

    .hm-features {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .hm-feature {
        padding: 16px 18px;
    }

    .hm-range {
        gap: 12px;
    }

    .hm-bike {
        border-radius: 14px;
    }

    .hm-bike-stage {
        padding: 30px 10px 10px;
    }

    .hm-bike-tag {
        top: 8px;
        left: 8px;
        padding: 3px 8px;
        font-size: 9px;
        letter-spacing: 1px;
    }

    .hm-bike-body {
        padding: 12px;
    }

    .hm-bike-body h3 {
        font-size: 15px;
    }

    .hm-bike-price,
    .hm-bike-price strong {
        font-size: 12px;
    }

    .hm-bike .hm-go {
        display: none;
    }

    .hm-filters {
        flex-wrap: nowrap;
        overflow-x: auto;
        scrollbar-width: none;
        padding-bottom: 4px;
    }

    .hm-filters::-webkit-scrollbar {
        display: none;
    }

    .hm-filter {
        flex: 0 0 auto;
    }

    .hm-launch-media {
        padding: 44px 16px 0;
    }

    .hm-launch-body {
        padding: 10px 20px 22px;
    }

    .hm-gallery {
        grid-auto-rows: 150px;
        gap: 10px;
    }

    .hm-gallery .hx-card-body {
        opacity: 1;
        transform: none;
        padding: 40px 12px 10px;
    }

    .hm-gallery .hx-card-body h3 {
        font-size: 14px;
    }

    .hm-contact-list {
        padding: 24px 20px 6px;
    }

    .hm-map {
        margin: 6px 20px 20px;
    }

    .hm-form {
        padding: 28px 20px;
    }
}

@media (prefers-reduced-motion: reduce) {

    .hm-slide > img,
    .hm-launch-media img,
    .hm-bike-stage img {
        transition: none;
        transform: none !important;
    }

    .hm-anim {
        opacity: 1;
        transform: none;
        animation: none !important;
    }

    .hm-new-badge {
        animation: none;
    }
}
