/*
 * HostChecker.org — Red Theme Design System
 * Version: 2.0.0
*/

/* ============================================
   CSS Custom Properties
   ============================================ */
:root {
    --red-primary:   #C62828;
    --red-hover:     #AD1F1F;
    --red-dark:      #B71C1C;
    --red-light:     #EF5350;
    --red-xlight:    #FFCDD2;
    --red-bg:        #FFF5F5;
    --dark-900:      #0D0D0D;
    --dark-800:      #111111;
    --dark-700:      #1A1A1A;
    --body-text:     #4B5563;
    --heading-color: #111827;
    --border-color:  #E5E7EB;
    --light-bg:      #F9FAFB;
    --white:         #FFFFFF;
}

/* ============================================
   Reset / Base
   ============================================ */
html,
body,
header,
.view {
    height: 80%;
    min-height: 500px;
}

body {
    background-color: #fff;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.65;
    color: var(--body-text);
    font-family: 'Inter', 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ============================================
   Bootstrap Primary Override → RED
   ============================================ */
.btn-primary {
    background-color: var(--red-primary) !important;
    border-color: var(--red-primary) !important;
    color: #fff !important;
    font-weight: 600;
    letter-spacing: 0.2px;
}
.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--red-hover) !important;
    border-color: var(--red-hover) !important;
    box-shadow: none !important;
}
.btn-primary:not(:disabled):not(.disabled).active,
.btn-primary:not(:disabled):not(.disabled):active,
.show > .btn-primary.dropdown-toggle {
    background-color: var(--red-dark) !important;
    border-color: var(--red-dark) !important;
}
.text-primary   { color: var(--red-primary) !important; }
.bg-primary     { background-color: var(--red-primary) !important; }
.border-primary { border-color: var(--red-primary) !important; }
.badge-primary  { background-color: var(--red-primary) !important; }

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-weight: 700;
    line-height: 1.3;
    color: var(--heading-color);
    margin-bottom: 0.65rem;
}
h1, .h1 { font-size: 2.5rem; }
h2, .h2 { font-size: 1.75rem; }
h3, .h3 { font-size: 1.35rem; }
h4, .h4 { font-size: 1.15rem; }
h5, .h5 { font-size: 1.0rem; }
h6, .h6 { font-size: 0.9rem; }

small, .small { font-size: 0.875em; font-weight: 400; }
.lead { font-size: 1.05rem; font-weight: 400; }
.font-weight-100 { font-weight: 100 !important; }
.font-weight-400 { font-weight: 400 !important; }
.white-text  { color: #fff !important; }
.grey-text   { color: #9CA3AF !important; }
.text-gray   { color: #9CA3AF !important; }
.text-yellow { color: #F59E0B !important; }

/* ============================================
   Navbar
   ============================================ */
.navbar {
    padding: 0.85rem 1rem;
    background: rgba(10, 5, 5, 0.88) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.navbar-brand {
    font-size: 1.35rem;
    font-weight: 800;
    color: #fff !important;
    padding-top: 0;
    letter-spacing: -0.3px;
}
.navbar-brand .brand-accent {
    color: var(--red-light);
}
.nav-item .nav-link {
    font-weight: 500;
    font-size: 0.88rem;
    letter-spacing: 0.2px;
}
.navbar.navbar-dark .navbar-nav .nav-item .nav-link {
    color: rgba(255, 255, 255, 0.85);
    transition: color 0.2s;
    border-radius: 5px;
    cursor: pointer;
}
.navbar.navbar-dark .navbar-nav .nav-item .nav-link:hover {
    color: var(--red-light);
}
.navbar .dropdown-menu a { padding: 8px 10px; }
.navbar .dropdown-menu a:hover {
    background-color: var(--red-primary);
    color: #fff;
    transition: all 0.1s ease-in-out;
}
@media only screen and (max-width: 991px) {
    .navbar {
        background: var(--dark-800) !important;
        backdrop-filter: none !important;
    }
    .navbar .nav-item .nav-link {
        padding-right: 6px;
        padding-left: 6px;
    }
}
.navbar-dark .navbar-toggler { border: none; color: #fff; }
button.navbar-toggler:focus  { outline: none; }
.navbar-dark .navbar-toggler-icon {
    background-image: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(255,255,255,1.0)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 8h24M4 16h24M4 24h24'/%3E%3C/svg%3E");
}
.dropdown-toggle::after { margin-left: .355em; vertical-align: 0.15em; }
.navbar-brand { padding-top: 0; }
@media (min-width: 600px) {
    .navbar.scrolling-navbar .navbar-nav > li { transition-duration: 1s; }
}

/* ============================================
   Hero / View
   ============================================ */
.view {
    position: relative;
    overflow: hidden;
    height: 100%;
}
.full-page-intro {
    background-color: var(--dark-900);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center center;
    color: #fff;
}
.view .mask {
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: linear-gradient(
        160deg,
        rgba(8, 4, 4, 0.96) 0%,
        rgba(28, 8, 8, 0.93) 50%,
        rgba(8, 4, 4, 0.96) 100%
    );
}
.hero-inner {
    position: relative;
    z-index: 2;
}
.hero-eyebrow {
    display: inline-block;
    background: rgba(198, 40, 40, 0.14);
    border: 1px solid rgba(198, 40, 40, 0.38);
    color: #FFCDD2;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    padding: 0.3rem 0.85rem;
    border-radius: 20px;
    margin-bottom: 1.25rem;
}
.title {
    color: #fff;
    font-size: 2.9rem;
    font-weight: 800;
    letter-spacing: -0.6px;
    line-height: 1.2;
    text-shadow: 0 2px 30px rgba(0, 0, 0, 0.6);
}
.hero-desc {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.68);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.65;
}
.hero-trust {
    margin-top: 1.4rem;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.38);
    letter-spacing: 0.4px;
}
.hero-trust span { margin: 0 0.6rem; }
.hero-trust i {
    color: var(--red-light);
    margin-right: 4px;
}

/* ============================================
   Search Form
   ============================================ */
.main-search {
    background: #fff;
    border-radius: 50px !important;
    padding: 5px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255,255,255,0.05);
    max-width: 620px;
    margin: 0 auto;
}
.main-search input[type=text] {
    border: none !important;
    box-shadow: none !important;
    border-radius: 50px !important;
    height: 50px;
    font-size: 0.975rem;
    padding-left: 1.5rem;
    color: var(--heading-color);
    background: transparent;
}
.main-search input[type=text]:focus,
.main-search input[type=text]:active,
.main-search input[type=text]:hover {
    border: none !important;
    box-shadow: none !important;
}
.main-search .input-group-append button {
    border-radius: 50px !important;
    height: 50px;
    min-width: 56px;
    background-color: var(--red-primary) !important;
    border-color: var(--red-primary) !important;
    font-size: 1rem;
    transition: background-color 0.2s;
}
.main-search .input-group-append button:hover {
    background-color: var(--red-hover) !important;
    border-color: var(--red-hover) !important;
}
.main-search button { margin: 0; }
.homepage-universal-search .main-search {
    width: 100%;
    max-width: 620px;
    display: inline-flex;
}
@media (max-width: 992px) {
    .homepage-universal-search .main-search {
        width: 100% !important;
        margin-bottom: 0 !important;
        align-items: center;
    }
}
@media (max-width: 580px) {
    .title { font-size: 1.95rem; }
}
@media (max-width: 768px) {
    .title { font-size: 2.2rem; }
    h1, .h1 { font-size: 2rem; }
    h2, .h2 { font-size: 1.5rem; }
}

/* SVG Wave Divider */
.svg-border-rounded svg {
    position: inherit;
    bottom: 0;
    left: 0;
    height: 3rem;
    width: 100%;
}

/* ============================================
   Content Section
   ============================================ */
#content-section {
    background: #fff;
}
#content-section h2 {
    font-size: 1.45rem;
    font-weight: 700;
    color: var(--heading-color);
    margin-top: 2.25rem;
    margin-bottom: 0.65rem;
    padding-top: 0.25rem;
}
#content-section h2:first-child { margin-top: 0; }
#content-section h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--heading-color);
    margin-top: 1.35rem;
    margin-bottom: 0.45rem;
}
#content-section p {
    color: var(--body-text);
    line-height: 1.75;
    margin-bottom: 0.85rem;
}
#content-section ul {
    padding-left: 1.1rem;
    margin-bottom: 1rem;
}
#content-section ul li {
    margin-bottom: 0.4rem;
    color: var(--body-text);
    line-height: 1.7;
}
#content-section a {
    color: var(--red-primary);
    text-decoration: none;
    font-weight: 500;
}
#content-section a:hover { text-decoration: underline; }

/* Step list */
.step-row {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
    margin-bottom: 0.85rem;
}
.step-num {
    flex-shrink: 0;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--red-primary);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 2px;
}
.step-text { color: var(--body-text); line-height: 1.65; }

/* ============================================
   FAQ Section
   ============================================ */
.faq-section {
    background: var(--light-bg);
    padding: 3.5rem 0;
}
.faq-section-header {
    text-align: center;
    margin-bottom: 2.25rem;
}
.faq-section-header h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--heading-color);
    margin-bottom: 0.4rem;
}
.faq-section-header p {
    color: var(--body-text);
    font-size: 0.95rem;
}
.faq { overflow: hidden; }
.faq .faq-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1rem;
    padding-bottom: 1rem;
}
.faq .card {
    border: 1px solid var(--border-color) !important;
    border-radius: 8px !important;
    margin-bottom: 0.55rem;
    box-shadow: none;
    overflow: hidden;
}
.faq .card .card-header {
    cursor: pointer;
    background-color: #fff;
    border-bottom: 1px solid var(--border-color);
    padding: 0;
}
.faq .faq-item .card-header .faq-item-heading {
    color: var(--heading-color);
    font-weight: 600;
    font-size: 0.95rem;
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.faq .faq-item a[aria-expanded="false"] .faq-item-heading::after {
    content: '+';
    font-size: 1.35rem;
    font-weight: 300;
    color: var(--red-primary);
    flex-shrink: 0;
    margin-left: 1rem;
    line-height: 1;
}
.faq .faq-item a[aria-expanded="true"] .faq-item-heading::after {
    content: '−';
    font-size: 1.35rem;
    font-weight: 300;
    color: var(--red-primary);
    flex-shrink: 0;
    margin-left: 1rem;
    line-height: 1;
}
.faq .faq-item a:hover { text-decoration: none; }
.faq .card-body {
    padding: 1rem 1.25rem;
    color: var(--body-text);
    font-size: 0.93rem;
    line-height: 1.72;
    background: #fff;
    border-bottom: none !important;
}
.faq .faq-item-heading-arrow { display: none; }
.collapsing { max-height: 160px; }

/* ============================================
   Map / Results Section
   ============================================ */
#map-section {
    background: #fff;
}

/* Result Cards */
.result-wrap {
    padding: 2.5rem 0 3rem;
}
.result-domain-title {
    font-size: 1.65rem;
    font-weight: 700;
    margin-bottom: 1.75rem;
    color: var(--heading-color);
}
.result-domain-title span {
    color: var(--red-primary);
}
.result-card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 1.15rem 1.35rem;
    margin-bottom: 0.85rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}
.result-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: var(--red-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.result-card-icon i {
    color: var(--red-primary);
    font-size: 1.05rem;
}
.result-card-body { flex: 1; }
.result-card-body .rc-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.7px;
    color: #9CA3AF;
    margin-bottom: 0.25rem;
}
.result-card-body .rc-value {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--heading-color);
    margin-bottom: 0.2rem;
    line-height: 1.3;
}
.result-card-body .rc-meta {
    font-size: 0.83rem;
    color: var(--body-text);
    margin-bottom: 0;
    line-height: 1.6;
}
.result-card-body .rc-meta a {
    color: var(--red-primary);
    font-weight: 500;
    text-decoration: none;
}
.result-card-body .rc-meta a:hover { text-decoration: underline; }
.result-actions { margin-top: 1.5rem; }
.result-actions .btn {
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.875rem;
    padding: 0.5rem 1.1rem;
}
.btn-success {
    background-color: #059669 !important;
    border-color: #059669 !important;
    color: #fff !important;
}
.btn-success:hover {
    background-color: #047857 !important;
    border-color: #047857 !important;
}
.result-map-wrap { position: relative; }
.result-map-label {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.7px;
    color: #9CA3AF;
    margin-bottom: 0.6rem;
}
#map {
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

/* ============================================
   Affiliate Section
   ============================================ */
#affiliate-list { background: var(--light-bg); }
.affiliate {
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.07);
    border-radius: 10px !important;
    transition: box-shadow 0.15s ease-in-out, transform 0.15s ease-in-out;
}
.affiliate:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.11);
}
.card.affiliate { text-decoration: none; color: inherit; }

/* ============================================
   List Group (legacy info template)
   ============================================ */
.list-group-information .list-group-item {
    padding-left: 0;
    padding-right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ============================================
   Cards (global)
   ============================================ */
.card {
    border: 1px solid var(--border-color);
    border-radius: 8px;
}
.card-header {
    padding: 1rem 1.25rem;
    background-color: #fff;
    border-bottom: 1px solid var(--border-color);
}
.card-footer {
    padding: 0.875rem 1.25rem;
    background-color: #fafafa;
    border-top: 1px solid var(--border-color);
}
.bg-light { background-color: var(--light-bg) !important; }

/* ============================================
   Footer
   ============================================ */
footer {
    background-color: var(--dark-800);
    color: rgba(255, 255, 255, 0.55);
}
.footer-brand {
    font-size: 1.25rem;
    font-weight: 800;
    color: #fff;
    display: block;
    margin-bottom: 0.5rem;
    text-decoration: none;
}
.footer-brand .brand-accent { color: var(--red-light); }
.footer-tagline {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.38);
    line-height: 1.6;
    max-width: 260px;
}
.footer-col-title {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.1px;
    color: rgba(255, 255, 255, 0.3);
    margin-bottom: 0.9rem;
}
footer ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0;
}
footer ul li { margin-bottom: 0.45rem; }
footer a {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.2s;
}
footer a:hover {
    color: var(--red-light);
    text-decoration: none;
}
.footer-divider {
    border-color: rgba(255, 255, 255, 0.07);
    margin: 1.75rem 0 1.25rem;
}
.footer-bottom-text {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.25);
}

/* ============================================
   Go-to-Top Button
   ============================================ */
#go-to-top-btn {
    display: inline-block;
    background-color: var(--red-primary);
    width: 40px;
    height: 40px;
    text-align: center;
    border-radius: 40px;
    position: fixed;
    bottom: 30px;
    right: 30px;
    opacity: 0;
    visibility: hidden;
    z-index: 1000;
    padding-top: 9px;
    transition: opacity 0.3s, visibility 0.3s, background-color 0.2s;
}
#go-to-top-btn:hover {
    cursor: pointer;
    background-color: var(--red-hover);
}
#go-to-top-btn.show { opacity: 1; visibility: visible; }

/* ============================================
   Loader / Spinner
   ============================================ */
.loader {
    animation: spin 1s linear infinite;
}
@keyframes spin {
    0%   { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ============================================
   Form Focus
   ============================================ */
button:focus,
.form-control:focus,
.btn-info:not(:disabled):not(.disabled).active:focus,
.btn-info:not(:disabled):not(.disabled):active:focus,
.show > .btn-info.dropdown-toggle:focus {
    box-shadow: none !important;
}

/* ============================================
   Alert
   ============================================ */
.alert { border: none !important; }

/* ============================================
   Page Header (slug pages)
   ============================================ */
.page-header h1 {
    color: #fff;
    font-size: 2.5rem;
}

/* ============================================
   User info (legacy)
   ============================================ */
#user-info { min-height: 326px; }
#user-info .list-group-item.default { min-height: 326px; }

/* ============================================
   Misc helpers
   ============================================ */
.divider-new,
.navbar .nav-flex-icons { flex-direction: row; }

/* ============================================
   Language Switcher
   ============================================ */
.lang-switcher .lang-toggle {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 0.4rem 0.6rem;
}
.lang-switcher .lang-flag  { font-size: 1rem; line-height: 1; }
.lang-switcher .lang-code  { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.5px; color: rgba(255,255,255,0.85); }
.lang-switcher .dropdown-toggle::after { vertical-align: 0.1em; }

.lang-dropdown-menu {
    min-width: 200px;
    max-height: 340px;
    overflow-y: auto;
    padding: 0.35rem 0;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.45);
}
.lang-dropdown-menu .dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.83rem;
    font-weight: 400;
    color: rgba(255,255,255,0.7);
    padding: 0.45rem 1rem;
    transition: background 0.15s, color 0.15s;
}
.lang-dropdown-menu .dropdown-item:hover,
.lang-dropdown-menu .dropdown-item:focus {
    background-color: var(--red-primary);
    color: #fff;
}
.lang-dropdown-menu .dropdown-item.active {
    background-color: rgba(198,40,40,0.18);
    color: var(--red-light);
    font-weight: 600;
}
.lang-dropdown-menu .lang-flag-sm { font-size: 1rem; line-height: 1; }

/* Scrollbar for lang dropdown */
.lang-dropdown-menu::-webkit-scrollbar { width: 4px; }
.lang-dropdown-menu::-webkit-scrollbar-track { background: transparent; }
.lang-dropdown-menu::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 4px; }

@media (max-width: 991px) {
    .lang-dropdown-menu {
        max-height: 260px;
        min-width: 180px;
        background: rgba(255,255,255,0.05);
        border: none;
        box-shadow: none;
    }
    .lang-dropdown-menu .dropdown-item { color: rgba(255,255,255,0.65); }
}

/* ============================================
   RTL Overrides (Arabic)
   ============================================ */
[dir="rtl"] body { text-align: right; }

[dir="rtl"] .navbar-brand { margin-right: 0; margin-left: auto; }
[dir="rtl"] .navbar-nav   { padding-right: 0; }
[dir="rtl"] .navbar-nav.ml-auto { margin-left: 0 !important; margin-right: auto !important; }
[dir="rtl"] .ml-lg-2 { margin-left: 0 !important; margin-right: 0.5rem !important; }
[dir="rtl"] .dropdown-menu-right { right: auto; left: 0; }

[dir="rtl"] .hero-desc { margin: 0 auto; }
[dir="rtl"] .hero-trust span { margin: 0 0.6rem; }
[dir="rtl"] .hero-trust i  { margin-right: 0; margin-left: 4px; }

[dir="rtl"] .step-row { flex-direction: row-reverse; }
[dir="rtl"] .step-text { text-align: right; }

[dir="rtl"] .result-card   { flex-direction: row-reverse; text-align: right; }
[dir="rtl"] .rc-meta i     { margin-right: 0; margin-left: 4px; }
[dir="rtl"] .rc-meta .mr-1 { margin-right: 0 !important; margin-left: 0.25rem !important; }

[dir="rtl"] .faq .faq-item .card-header .faq-item-heading { flex-direction: row-reverse; }
[dir="rtl"] .faq .faq-item a[aria-expanded="false"] .faq-item-heading::after,
[dir="rtl"] .faq .faq-item a[aria-expanded="true"]  .faq-item-heading::after {
    margin-left: 0;
    margin-right: 1rem;
}

[dir="rtl"] footer ul { padding-right: 0; }
[dir="rtl"] .footer-tagline { max-width: 100%; }
[dir="rtl"] .text-md-right { text-align: left !important; }

[dir="rtl"] .mr-2 { margin-right: 0 !important; margin-left: 0.5rem !important; }
[dir="rtl"] .mr-1 { margin-right: 0 !important; margin-left: 0.25rem !important; }
[dir="rtl"] .ml-1 { margin-left: 0  !important; margin-right: 0.25rem !important; }
[dir="rtl"] #go-to-top-btn { right: auto; left: 30px; }

[dir="rtl"] #content-section ul { padding-left: 0; padding-right: 1.1rem; }
