/* =============================================================
   DNS Panel — Custom Styles
   Bootstrap 5 + dark mode via data-bs-theme
   ============================================================= */

/* ---------------------------------------------------------------
   Layout
--------------------------------------------------------------- */
body {
    min-height: 100vh;
}

/* ---------------------------------------------------------------
   Sidebar
--------------------------------------------------------------- */
.sidebar {
    min-height: calc(100vh - 56px);
    border-right: 1px solid var(--bs-border-color);
}

@media (max-width: 767.98px) {
    .sidebar {
        min-height: auto;
        border-right: none;
        border-bottom: 1px solid var(--bs-border-color);
    }
}

.sidebar .nav-link {
    color: var(--bs-body-color);
    border-radius: 6px;
    padding: .45rem .85rem;
    font-size: .9rem;
    transition: background .15s, color .15s;
}

.sidebar .nav-link:hover {
    background: var(--bs-secondary-bg);
}

.sidebar .nav-link.active {
    background: rgba(13, 110, 253, .12);
    color: var(--bs-primary);
    font-weight: 600;
}

.sidebar-heading {
    font-size: .72rem;
    letter-spacing: .04em;
}

/* ---------------------------------------------------------------
   Navbar
--------------------------------------------------------------- */
.navbar {
    background-color: var(--bs-body-bg);
    border-bottom: 1px solid var(--bs-border-color);
}

/* ---------------------------------------------------------------
   Auth Layout
--------------------------------------------------------------- */
.auth-body {
    background: var(--bs-tertiary-bg);
}

.auth-card {
    padding: 1.5rem;
}

/* ---------------------------------------------------------------
   Cards
--------------------------------------------------------------- */
.card {
    border-radius: 10px;
}

.zone-card {
    transition: transform .15s, box-shadow .15s;
    cursor: default;
}

.zone-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,.1) !important;
}

/* ---------------------------------------------------------------
   Stat Cards (Dashboard)
--------------------------------------------------------------- */
.stat-icon {
    width: 58px;
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* ---------------------------------------------------------------
   DNS Record Type Badges
--------------------------------------------------------------- */
.record-type-badge {
    font-size: .7rem;
    letter-spacing: .05em;
    font-weight: 700;
    padding: .3em .6em;
    border-radius: 4px;
}

.type-a      { background:#198754; color:#fff; }
.type-aaaa   { background:#0d6efd; color:#fff; }
.type-cname  { background:#6f42c1; color:#fff; }
.type-mx     { background:#fd7e14; color:#fff; }
.type-txt    { background:#6c757d; color:#fff; }
.type-ns     { background:#20c997; color:#fff; }
.type-srv    { background:#0dcaf0; color:#000; }
.type-caa    { background:#d63384; color:#fff; }

/* ---------------------------------------------------------------
   Font-monospace helper
--------------------------------------------------------------- */
.font-monospace {
    font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
                 "Courier New", monospace !important;
    font-size: .875em;
}

/* ---------------------------------------------------------------
   Table improvements
--------------------------------------------------------------- */
.table > :not(caption) > * > * {
    vertical-align: middle;
}

/* ---------------------------------------------------------------
   Dark Mode Overrides
   Bootstrap handles most via data-bs-theme="dark", but
   some custom colors need explicit adjustment.
--------------------------------------------------------------- */
[data-bs-theme="dark"] .sidebar .nav-link.active {
    background: rgba(99, 166, 255, .18);
    color: #6ea8fe;
}

[data-bs-theme="dark"] .type-srv { color: #000; }

[data-bs-theme="dark"] .zone-card:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,.4) !important;
}

/* ---------------------------------------------------------------
   Scrollbar (Webkit)
--------------------------------------------------------------- */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--bs-secondary-bg-subtle);
    border-radius: 99px;
}

/* ---------------------------------------------------------------
   Transitions
--------------------------------------------------------------- */
html {
    transition: background-color .2s ease, color .2s ease;
}

/* ---------------------------------------------------------------
   Responsive tweaks
--------------------------------------------------------------- */
@media (max-width: 575.98px) {
    .auth-card {
        padding: 1rem;
    }

    h4.fw-semibold {
        font-size: 1.1rem;
    }
}
