/* --- Design Variables --- */
:root {
    --hik-red: #c4161c;
    --hik-red-hover: #9c1216;
    --hik-red-light: rgba(196, 22, 28, 0.1);

    --hik-blue: #0b192c;
    --hik-blue-light: #1a2a40;

    --bg-main: #f0f2f5;
    --bg-app: #ffffff;

    --text-main: #1a1a2e;
    --text-muted: #6c757d;

    --radius-app: 20px;
    --radius-card: 16px;
    --radius-btn: 10px;
}

/* --- Global Reset & Typography --- */
body {
    background-color: var(--bg-main);
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
}

.fs-sm {
    font-size: 0.875rem;
}

/* --- Colors & Utilities --- */
.text-hik-red {
    color: var(--hik-red) !important;
}

.bg-hik-red-light {
    background-color: var(--hik-red-light) !important;
}

.text-hik-red-light {
    color: #ff6b6b !important;
}

.text-hik-blue {
    color: var(--hik-blue) !important;
}

.bg-hik-blue {
    background-color: var(--hik-blue) !important;
}

.hover-text-white:hover {
    color: #ffffff !important;
}

/* Primary Button */
.btn-hik-primary {
    background-color: var(--hik-red);
    color: white;
    border: none;
    border-radius: var(--radius-btn);
    font-weight: 500;
    transition: all 0.2s ease-in-out;
}

.btn-hik-primary:hover,
.btn-hik-primary:focus {
    background-color: var(--hik-red-hover);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(196, 22, 28, 0.3);
}

.btn-outline-dark {
    border-radius: var(--radius-btn);
    font-weight: 500;
}

/* --- App Container (App-like feel) --- */
.app-container {
    background-color: var(--bg-app);
    max-width: 1400px;
    margin: 20px auto;
    border-radius: var(--radius-app);
    box-shadow: 0 10px 40px rgba(11, 25, 44, 0.1);
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 40px);
}

@media (max-width: 1440px) {
    .app-container {
        margin: 0;
        border-radius: 0;
        min-height: 100vh;
        box-shadow: none;
    }
}

/* --- Navigation --- */
.header .nav-link {
    font-weight: 500;
    transition: color 0.2s;
}

.header .nav-link:hover {
    color: var(--hik-red) !important;
}

.header-inner {
    row-gap: 0.5rem;
}

.header-nav-list {
    flex-wrap: wrap;
}

.header-contact {
    flex-shrink: 0;
    white-space: nowrap;
}

.header-contact .btn-hik-primary {
    max-width: 100%;
    padding: 0.7rem 1.25rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: none;
}

.header-contact .btn-hik-primary:hover,
.header-contact .btn-hik-primary:focus {
    background-color: #ffffff;
    color: var(--hik-blue);
    border-color: #ffffff;
    transform: none;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

.logo-wrapper {
    flex-wrap: nowrap;
    min-width: 0;
}

.logo-brand,
.logo-subtitle {
    line-height: 1;
}

@media (min-width: 1200px) {
    .header-inner {
        display: grid !important;
        grid-template-columns: auto minmax(0, 1fr) auto;
        align-items: center;
        column-gap: 1rem;
        flex-wrap: nowrap !important;
    }

    .header-logo {
        margin-right: 0;
    }

    .header-nav-list {
        display: flex;
        justify-content: center;
        flex-wrap: nowrap;
        margin: 0;
        min-width: 0;
    }

    .header-nav-list .nav-link {
        white-space: nowrap;
        padding-left: 0.65rem !important;
        padding-right: 0.65rem !important;
        font-size: 0.9rem;
    }

    .header-contact {
        margin-left: 0;
    }
}

@media (max-width: 1199.98px) {
    .header-nav-list {
        order: 3;
        margin-top: 0.25rem;
        width: 100%;
        justify-content: center;
    }

    .header-contact {
        margin-left: 0;
    }

    .header-contact .btn {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

@media (max-width: 575.98px) {
    .header-inner {
        justify-content: space-between !important;
        align-items: flex-start !important;
    }

    .header-logo {
        margin-bottom: 0 !important;
        flex: 1 1 auto;
        min-width: 0;
    }

    .logo-wrapper {
        max-width: 100%;
    }

    .logo-brand {
        font-size: 1.1rem !important;
        letter-spacing: 0.02em;
    }

    .header-contact {
        flex: 0 0 auto;
        margin-left: 0.75rem !important;
    }

    .header-contact .btn-hik-primary {
        padding: 0.55rem 0.9rem;
        font-size: 0.95rem;
        line-height: 1.2;
        white-space: nowrap;
    }

    .header-nav-list {
        margin-top: 0.75rem;
    }
}

@media (min-width: 576px) and (max-width: 767.98px) {
    .logo-wrapper {
        align-items: flex-start !important;
    }

    .logo-brand {
        font-size: 1.3rem !important;
    }

    .logo-subtitle {
        margin-left: 0.5rem !important;
        padding-left: 0.5rem !important;
        font-size: 0.8rem !important;
        line-height: 1.15;
        white-space: normal;
    }
}

/* --- Advantages Grid --- */
.advantage-card {
    border-radius: var(--radius-card);
    transition: transform 0.3s ease;
}

.advantage-card:hover {
    transform: translateY(-5px);
}

/* --- Accordion Fixes --- */
.accordion-item {
    border-color: #eaeaea;
}

.accordion-button:not(.collapsed) {
    color: var(--hik-red);
    background-color: transparent;
    box-shadow: none;
}

.accordion-button:focus {
    box-shadow: none;
    border-color: transparent;
}

.accordion-button::after {
    background-size: 1rem;
}

/* --- Floating Button --- */
.floating-phone-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: var(--hik-red);
    z-index: 999;
    transition: transform 0.2s;
}

.floating-phone-btn:hover {
    transform: scale(1.1);
}

@media (max-width: 768px) {
    .floating-phone-btn {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }
}

/* Form inputs Focus */
.form-control:focus {
    border-color: rgba(196, 22, 28, 0.5);
    box-shadow: 0 0 0 0.25rem rgba(196, 22, 28, 0.1);
}

/* Remote assessment form: reduce oversized input text */
#assessment-form .form-control.form-control-lg {
    font-size: 1rem;
    line-height: 1.4;
    padding-top: 0.625rem;
    padding-bottom: 0.625rem;
}

#assessment-form textarea.form-control.form-control-lg {
    min-height: 120px;
}

.assessment-info-panel .assessment-list li {
    margin-bottom: 0.4rem;
}
