@import '../../../dist/css/theme/fonts.css';

/* --- Configurator landing pages (.landing-page-ui) --- */


/* Sticky footer (configurator flow) */
.sticky-submit-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: white;
    padding: 1rem 2rem;
    box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.08);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.sticky-submit-footer .submit-container {
    width: 100%;
    max-width: 1400px;
    margin: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-left {
    flex: 1;
    display: flex;
    justify-content: flex-start;
}

.footer-center {
    flex: 2;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
}

.footer-right {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.back-btn {
    font-family: 'Franklin Gothic Heavy', 'Franklin Gothic Demi', 'Libre Franklin', sans-serif !important;
    padding: 0.85rem 1rem !important;
    width: 150px !important;
    background: transparent !important;
    color: var(--text-secondary) !important;
    border: 2px solid var(--border) !important;
    border-radius: var(--radius-md) !important;
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.3s !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.6rem !important;
    text-decoration: none !important;
    text-transform: uppercase !important;
}

.back-btn:hover {
    border-color: var(--text-secondary) !important;
    color: var(--text-main) !important;
    background: #f8fafc !important;
    transform: translateX(-4px) !important;
}

/* Headings and main labels */
h1,
h2,
h3,
h4,
h5,
h6,
.selection-cta,
.title,
.main-title,
.user-greeting,
th {
    font-family: 'Franklin Gothic Heavy', 'Franklin Gothic Demi', 'Libre Franklin', sans-serif !important;
    text-transform: uppercase !important;
    font-weight: 800 !important;
}

.landing-page-ui {
    font-family: 'Franklin Gothic Demi', 'Franklin Gothic Heavy', 'Libre Franklin', Arial, sans-serif !important;
    background: url('../../../dist/img/ui/Background.png') no-repeat center center fixed !important;
    background-size: cover !important;
    min-height: 100vh;
    /*display: flex;*/
    flex-direction: column;
    color: #0f172a !important;
}

.landing-page-ui .header {
    background: #CE0E2D !important;
    padding: 0.3rem 2rem !important;
    display: flex;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
}

.landing-page-ui .logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    border-bottom: 2px solid transparent;
}

.landing-page-ui .logo-img {
    height: 40px !important;
    width: auto !important;
    object-fit: contain;
}

.landing-page-ui .landing-container {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: clamp(3.5rem, 6vh, 5rem) 1rem clamp(4.5rem, 7vh, 5.5rem) !important;
    min-height: 100dvh;
    box-sizing: border-box;
}

.landing-page-ui .landing-card {
    background: #ffffff !important;
    border-radius: 24px !important;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04) !important;
    padding: 3rem 2.5rem !important;
    width: 100%;
    max-width: 520px;
    border: 1px solid #e2e8f0 !important;
    border-top: 4px solid #CE0E2D !important;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
}

.landing-page-ui .landing-card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15) !important;
}

.landing-page-ui h1 {
    font-size: 1.6rem !important;
    font-weight: 700 !important;
    margin-bottom: 0.25rem !important;
    color: #0f172a !important;
    text-transform: uppercase !important;
    font-family: 'Franklin Gothic Heavy', 'Franklin Gothic Demi', 'Libre Franklin', sans-serif !important;
}

/* Global button & input typography */
button,
select,
select option,
input,
.submit-btn,
.btn-submit,
.btn-complete,
.back-btn {
    font-family: 'Franklin Gothic Demi', 'Franklin Gothic Heavy', 'Libre Franklin', sans-serif !important;
}

button,
input,
.submit-btn,
.btn-submit,
.btn-complete,
.back-btn {
    text-transform: uppercase !important;
}

.landing-page-ui .intro-text {
    color: #64748b !important;
    margin-bottom: 0.5rem !important;
    margin-top: 0 !important;
    line-height: 1.4 !important;
    font-size: 0.9rem !important;
}

.landing-page-ui .form-group {
    text-align: left;
    margin-bottom: 0.5rem !important;
    transition: transform 0.2s ease;
}

.landing-page-ui .form-group:focus-within {
    transform: translateX(4px);
}

.landing-page-ui .form-group label {
    display: block;
    margin-bottom: 0.25rem !important;
    font-weight: 500 !important;
    color: #0f172a !important;
    font-size: 0.85rem !important;
}

.landing-page-ui .form-group input {
    width: 100%;
    padding: 0.6rem 0.85rem !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 8px !important;
    background: #f8fafc !important;
    font-size: 0.95rem !important;
    color: #0f172a !important;
    transition: all 0.2s ease !important;
}

.landing-page-ui .form-group input:focus {
    outline: none !important;
    border-color: #CE0E2D !important;
    background: #fff !important;
    box-shadow: 0 0 0 4px rgba(206, 14, 45, 0.1) !important;
}

.landing-page-ui .btn-primary {
    font-family: 'Franklin Gothic Heavy', 'Franklin Gothic Demi', 'Libre Franklin', sans-serif !important;
    width: 100%;
    padding: 0.75rem !important;
    background: #CE0E2D !important;
    color: white !important;
    border: none !important;
    border-radius: 8px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    cursor: pointer;
    margin-top: 0.5rem !important;
    transition: all 0.2s ease !important;
    font-size: 1rem !important;
    box-shadow: 0 4px 6px -1px rgba(206, 14, 45, 0.2) !important;
}

.landing-page-ui .btn-primary:hover {
    background: #AB0C25 !important;
    transform: translateY(-3px) !important;
    box-shadow: 0 12px 20px -5px rgba(206, 14, 45, 0.4) !important;
}

.landing-page-ui .btn-primary:active {
    transform: translateY(-1px) !important;
}

.back-nav {
    width: 100%;
    max-width: 1100px;
    margin-bottom: 0.5rem;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s;
}

.back-link:hover {
    color: var(--primary);
}

.footer {
    text-align: center;
    margin: 2rem 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer a {
    color: var(--text-secondary);
    text-decoration: none;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.footer a:hover {
    opacity: 1;
}

.container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    /* Header ≈ 50px fixed top + 6px buffer, Footer ≈ 70px fixed bottom + 6px buffer */
    padding: 56px 1rem 76px;
    min-height: 0;
    box-sizing: border-box;
}

.header-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.no-header-actions .header-actions {
    display: none !important;
}

.user-greeting {
    color: white;
    font-weight: 500;
    font-size: 0.95rem;
    text-transform: uppercase;
}

.logout-btn,
.profile-btn {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-md);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.logout-btn:hover,
.profile-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: white;
    transform: translateY(-2px);
}

.logout-btn:active,
.profile-btn:active {
    transform: translateY(0);
}

.profile-btn {
    display: none;
}

.step-indicator {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0;
    margin-bottom: 1rem;
    width: 100%;
    max-width: 1400px;
    position: relative;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
}

.step {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    position: relative;
    z-index: 2;
    cursor: default;
    white-space: nowrap;
}

.step:not(:last-child) {
    flex: 1;
}

.step:last-child {
    flex: 0 0 auto;
}

.step:not(:last-child)::after {
    content: '';
    display: block;
    flex: 1;
    height: 2px;
    background: #e2e8f0;
    margin: 0 0.75rem;
    position: static;
    transform: none;
    width: auto;
}

.step i {
    width: 32px;
    height: 32px;
    background: #e2e8f0;
    border: 2px solid transparent;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-style: normal;
    color: white;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.step.active {
    color: var(--primary);
}

.step.active i {
    background: white;
    color: var(--primary);
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(206, 14, 45, 0.1);
}

.step i .fas.fa-check {
    font-size: 0.75rem;
}

/* ==================== MEDIA QUERIES ==================== */
@media (max-width: 768px) {
    .landing-page-ui .header {
        padding: 0.4rem 0.75rem !important;
    }

    .user-greeting {
        display: block !important;
        font-size: 0.78rem !important;
        font-weight: 600 !important;
        max-width: 130px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .header-actions {
        gap: 0.5rem;
    }
    
    .profile-btn,
    .logout-btn {
        padding: 0.4rem 0.6rem;
    }
    
    .profile-btn .btn-text,
    .logout-btn .btn-text {
        display: none;
    }

    .step-indicator {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
        gap: 0;
        justify-content: space-between;
        width: 100%;
        box-sizing: border-box;
    }

    .step span {
        display: none;
    }

    .step {
        display: flex;
        align-items: center;
    }

    .step:not(:last-child) {
        flex: 1;
    }

    .step:last-child {
        flex: 0 0 auto;
    }

    .step:not(:last-child)::after {
        content: '';
        display: block;
        flex: 1;
        height: 2px;
        background: #e2e8f0;
        margin: 0 0.35rem;
        position: static;
        transform: none;
        width: auto;
        left: auto;
        top: auto;
    }

    /* Get-started page: ensure content clears the fixed header */
    .landing-page-ui .container {
        padding-top: 72px !important;
        padding-bottom: 5rem !important;
    }

    .landing-page-ui .back-nav {
        margin-top: 0.75rem !important;
        margin-bottom: 1rem !important;
    }

    .landing-page-ui .welcome-header {
        overflow: hidden !important;
    }
}

/* Short height viewports (Laptops with 150%-200% scale or 720p-850p heights) */
@media (max-height: 850px) {
    .step-indicator {
        margin-bottom: 1.25rem !important;
    }
    .back-nav {
        margin-bottom: 1rem !important;
    }
    .landing-page-ui .landing-card {
        padding: 1.75rem 2rem !important;
    }
}

@media (max-height: 720px) {
    .container {
        padding-top: 75px;
        padding-bottom: 4.25rem !important;
    }
    .step-indicator {
        margin-bottom: 0.85rem !important;
    }
    .back-nav {
        margin-bottom: 0.5rem !important;
    }
}

/* Large 2K/3K screens at 100% scale (width >= 2000px) */
@media (min-width: 2000px) {
    .landing-page-ui .landing-card {
        max-width: 620px;
        padding: 3.5rem 3rem !important;
    }
}
