@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');

/* =========================================
   1. VARIABLES, BASE & TYPOGRAPHY
   ========================================= */
:root {
    --c-dark-bg: #181818;
    --c-darker-bg: #111111;
    --c-light-bg: #f5f5f5;
    --c-danger: #b00020;
    --c-text-muted: #666;
    --border-rad-md: 0.7rem;
    --border-rad-lg: 1rem;
    --font-main: "Montserrat", sans-serif;
    --shadow-sm: 0 0.125rem 0.3125rem rgba(0, 0, 0, 0.1);
    --shadow-md: 0 0.25rem 0.9375rem rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 0.5rem 1.5625rem rgba(0, 0, 0, 0.1);
}

body {
    color: #000;
    font-family: var(--font-main);
    margin: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a {
    text-decoration: none;
    color: white;
}

a img {
  display: block;
}

footer,
input,
textarea,
select,
.btn-block,
.blog-main,
.catalog-main,
.home-main,
.content-container,
.blog-header,
main.catalog {
    box-sizing: border-box;
}

.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

/* =========================================
   2. UTILITIES
   ========================================= */

.color-444 {
    color: #444;
}

.flex-1 {
    flex: 1;
}

.flex-2 {
    flex: 2;
}

.mb-0 {
    margin-bottom: 0;
}

.mb-1 {
    margin-bottom: 1rem;
}

.mb-1-5 {
    margin-bottom: 1.5rem;
}

.mt-0 {
    margin-top: 0;
}

.mt-0-5 {
    margin-top: 0.5rem;
}

.mt-1-5 {
    margin-top: 1.5rem;
}

.mt-4 {
    margin-top: 4rem;
}

.pt-0 {
    padding-top: 0;
}

.d-none {
    display: none !important;
}

.text-center {
    text-align: center;
}

.help-text {
    color: var(--c-text-muted);
    font-weight: 400;
    font-size: 0.9rem;
}

.danger-text {
    color: var(--c-danger);
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.3125rem;
    white-space: nowrap;
}

.link-muted {
    color: var(--c-text-muted);
    font-size: 0.9rem;
    transition: color 0.2s;
}

.link-muted:hover {
    text-decoration: underline;
    color: black;
}

.form-section-mb {
    margin-bottom: 1.5rem;
}

.auto-link {
    text-decoration: underline;
}

.d-flex {
    display: flex
}

.gap-1 {
    gap: 1rem;
}

/* =========================================
   3. LAYOUTS
   ========================================= */
main {
    display: flex;
    flex: 1;
    margin-top: 4rem;
}

.blog-main,
.catalog-main,
.home-main,
main.catalog {
    flex-direction: column;
    align-items: center;
    width: 100%;
}

main.catalog {
    padding: 0 2rem 2rem;
}

main.catalog h1 {
    margin: 2rem 0 0.5rem;
}

.content-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(20rem, 25rem));
    justify-content: center;
    gap: 3rem 2rem;
    width: 100%;
    padding: 4rem 2rem;
}

.tags-content-container {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* Headers & Footers */
header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: var(--c-dark-bg);
    height: 3rem;
    padding: 0.5rem 2rem;
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 100;
}

footer {
    background-color: var(--c-dark-bg);
    padding: 1.5rem 2rem;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
}

/* Container Styling */
.visitor-stats-box {
    background-color: var(--c-dark-bg);
    border: 1px solid #333; 
    border-radius: 8px;
    padding: 0.75rem 1.25rem; /* Reduced from 1.5rem to shrink top/bottom height */
    color: #e0e0e0;
    box-shadow: var(--shadow-md);
    width: 20vw;
    font-family: inherit;
}

/* Header/Title */
.visitor-stats-box h4 {
    margin-top: 0;
    margin-bottom: 0.5rem; /* Reduced from 1.25rem to pull the numbers closer to the title */
    color: var(--c-text-muted);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--c-text-muted);
    margin-bottom: 0;
    margin-right: 0.1rem;
}

nav {
    display: flex;
    gap: 1rem;
}

.nav-logout {
    color: #ff4d4d;
    margin-left: 1rem;
    font-weight: bold;
}

header>a {
    display: flex;
    align-items: center;
    height: 100%;
}

/* 1. THE FIX FOR THE BOTTOM SPACE */
.custom-dropdown svg {
    display: block;
}

/* 2. Update the container width since you don't have text anymore */
.custom-dropdown {
    position: relative;
    display: flex;
    user-select: none;
}

.dropdown-selected {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.625rem;
    border: 0.0625rem solid #ccc;
    border-radius: 0.4rem;
    background-color: none;
    cursor: pointer;
}

.dropdown-selected::after {
    font-size: 0.8em;
    color: #666;
}

.dropdown-options {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin: 0.3125rem 0 0 0;
    padding: 0;
    list-style: none;
    border: 0.0625rem solid #ccc;
    border-radius: 0.25rem;
    background-color: #fff;
    box-shadow: 0 0.25rem 0.375rem rgba(0, 0, 0, 0.1);
    z-index: 100;
}

.dropdown-options.open {
    display: block;
}

/* Center the icons in the dropdown list */
.dropdown-options li {
    display: flex;
    justify-content: center;
    padding: 0.625rem;
    cursor: pointer;
}

.dropdown-options li:hover {
    background-color: #f0f0f0;
}

/* Target the images inside your custom dropdown */
.custom-dropdown img {
    width: 1.5rem;
    height: 1.125rem;
    display: block;
    object-fit: cover;
    border-radius: 0.125rem;
}

.header-logo {
    height: 100%;
    border-radius: 0.25rem;
}

.blog-header {
    width: 100%;
    background: radial-gradient(circle at center top, #1f1f1f 0%, var(--c-darker-bg) 100%);
    color: white;
    text-align: center;
    padding: 5rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 35vh;
    justify-content: center;
}

.blog-header h1 {
    font-size: 2.8rem;
    margin: 0 0 1rem;
    font-weight: 700;
}

.blog-header p {
    color: #a0a0a0;
    font-size: 1.1rem;
    max-width: 37.5rem;
    line-height: 1.5;
    margin: 0 0 2.5rem;
}

/* Empty States & Errors */
.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    background: #f0f0f0;
    border-radius: var(--border-rad-md);
    color: var(--c-text-muted);
    font-size: 1.2rem;
}

.empty-state-large {
    height: 20vh;
}

#noCatalogResultsMsg {
    display: none;
}

.error-title {
    margin-top: 0;
    color: var(--c-danger);
}

.alert-error {
    background: #ffebee;
    border: 0.0625rem solid #c62828;
    color: #c62828;
    padding: 1rem;
    border-radius: 0.5rem;
    text-align: center;
}

.alert-error-sm {
    background: #ffebee;
    color: #c62828;
    padding: 0.8rem;
    border-radius: 0.4rem;
    margin-bottom: 1.5rem;
    text-align: center;
    font-size: 0.9rem;
}

/* =========================================
   4. FORMS & BUTTONS
   ========================================= */
input,
textarea,
select {
    padding: 0.4rem;
    border-radius: 0.3rem;
    border: 0.0625rem solid #ccc;
}

.hidden-textarea {
    display: none;
}

.inline-form {
    margin: 0;
    display: inline;
}

.checkbox-auto {
    width: auto;
    margin: 0;
}

.card-btn,
.contact-btn,
.btn-hero-primary,
.btn-hero-secondary,
.btn-outline-dark,
.btn-outline-light,
.lang-dropdown {
    display: inline-block;
    border-radius: 0.5rem;
    border: none;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s ease;
}

.card-btn {
    padding: 0.75rem;
    color: white;
    background: #363636;
}

.card-btn:hover {
    background: #111;
}

.contact-btn {
    padding: 0.75rem;
    background: var(--c-dark-bg);
    color: white;
}

.contact-btn:hover {
    background: black;
}

.btn-inline {
    padding: 0.6rem 1.5rem;
}

.btn-inline-large {
    padding: 0.6rem 1.5rem;
    width: auto;
    margin-top: 1.5rem;
}

.btn-inline-block {
    display: inline-block;
    margin-top: 0;
}

.btn-block {
    display: block;
    width: 100%;
}

.btn-full-mt {
    width: 100%;
    margin-top: 1rem;
}

.btn-full-large {
    width: 100%;
    margin-top: 1.5rem;
    padding: 0.8rem;
}

.btn-outline-dark {
    padding: 0.8rem 2rem;
    border: 0.0625rem solid #111;
    color: #111;
}

.btn-outline-dark:hover {
    background: #111;
    color: white;
}

.btn-outline-light,
.lang-dropdown {
    padding: 0.8rem 2rem;
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: #fff;
    background: none;
}

.btn-outline-light:hover,
.lang-dropdown:hover {
    background: #fff;
    color: #111;
}

.btn-hero-primary {
    background: white;
    color: #111;
    padding: 0.8rem 1.5rem;
}

.btn-hero-primary:hover {
    background: #e0e0e0;
}

.btn-hero-secondary {
    background: transparent;
    color: white;
    padding: 0.8rem 1.5rem;
    border: 0.0625rem solid rgba(255, 255, 255, 0.3);
}

.btn-hero-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
}

/* =========================================
   5. UNIFIED CARDS
   ========================================= */
.blog-card,
.product-card,
.card,
.login-card {
    display: flex;
    flex-direction: column;
    position: relative;
    border-radius: var(--border-rad-lg);
    overflow: hidden;
}

.blog-card,
.product-card {
    background: #fff;
    box-shadow: var(--shadow-md);
    transition: transform 0.3s, box-shadow 0.3s;
    border: 0.0625rem solid #eee;
}

.blog-card:hover,
.product-card:hover {
    transform: translateY(-0.3125rem);
    box-shadow: var(--shadow-hover);
}

.card,
.login-card {
    background: var(--c-light-bg);
    border-radius: var(--border-rad-md);
    box-shadow: var(--shadow-sm);
}

.card {
    height: 100%;
}

.card-body {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.social-button {
    display: flex;
}

.social-button img {
    width: 3rem;
}

.card-body h3 {
    margin: 0.5rem 0 1.5rem;
}

.card-body p {
    font-size: 0.9rem;
    color: #555;
}

.blog-card-image,
.product-card-image {
    display: block;
    width: 100%;
    overflow: hidden;
    background: var(--c-light-bg);
}

.blog-card-image {
    aspect-ratio: 16/9;
}

.product-card-image {
    aspect-ratio: 4/3;
    display: flex;
    align-items: center;
    justify-content: center;
}

.blog-card-image img,
.product-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}

.blog-card:hover .blog-card-image img,
.product-card:hover .product-card-image img {
    transform: scale(1.03);
}

.blog-card-content,
.product-card-content {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    padding: 1.5rem;
}

.blog-card-content h2,
.product-card-content h2 {
    font-weight: 700;
    line-height: 1.4;
    color: var(--c-dark-bg);
    margin: 0 0 0.8rem;
}

.blog-card-content h2 {
    font-size: 1.2rem;
}

.product-card-content h2 {
    font-size: 1.25rem;
    margin: 0;
}

.blog-card-content h2 a,
.product-card-content h2 a {
    color: inherit;
    transition: color 0.2s;
}

.blog-card-content h2 a:hover,
.product-card-content h2 a:hover {
    color: #555;
}

.blog-card-content h2 a::after,
.product-card-content h2 a::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
}

.blog-excerpt {
    color: var(--c-text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.2rem;
    flex-grow: 1;
}

.blog-read-more,
.product-read-more {
    display: inline-flex;
    align-items: center;
    color: var(--c-dark-bg);
    font-size: 0.9rem;
    margin-top: auto;
    transition: color 0.2s;
}

.blog-card:hover .blog-read-more,
.product-card:hover .product-read-more {
    color: #555;
}

.blog-meta,
.product-meta {
    display: flex;
    align-items: center;
    margin-bottom: 0.8rem;
    font-size: 0.85rem;
    color: #888;
    gap: 0.4rem;
}

.blog-author {
    color: #555;
    font-weight: 500;
}

.badge-band {
    background: #555;
    color: white;
    padding: 0.3rem 0.6rem;
    border-radius: 0.3rem;
    font-size: 0.7rem;
    align-self: flex-start;
    margin-bottom: 0.5rem;
}

/* =========================================
   6. SEARCH BARS
   ========================================= */
.blog-search-bar {
    display: flex;
    gap: 0.5rem;
    width: 100%;
}

.search-input-wrapper {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

.search-input-wrapper svg {
    position: absolute;
    left: 1rem;
    color: #888;
}

.search-input-wrapper input {
    width: 100%;
    background: #1e1e1e;
    border: 0.0625rem solid #333;
    color: white;
    padding: 0.8rem 1rem 0.8rem 2.8rem;
    border-radius: 0.5rem;
    margin: 0;
    transition: border-color 0.2s;
}

.search-input-wrapper input:focus,
select.custom-select:focus {
    outline: none;
    border-color: #555;
}

.search-input-wrapper input::placeholder {
    color: #888;
}

.tags-btn {
    background: #1e1e1e;
    border: 0.0625rem solid #333;
    color: white;
    padding: 0.75rem;
    border-radius: 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: background 0.2s;
}

.tags-btn:hover {
    background: #2a2a2a;
}

select.custom-select option {
    background: #1e1e1e;
    color: white;
}

/* =========================================
   7. DETAIL PAGES
   ========================================= */
.antenna-detail,
.post-page {
    display: flex;
    justify-content: center;
    padding: 2rem;
    color: black;
}

.antenna-detail-column {
    flex-direction: column;
    align-items: center;
}

.detail-container,
.description-container {
    width: 100%;
}

.detail-container {
    display: flex;
    gap: 3rem;
    align-items: center;
}

.detail-image,
.detail-info {
    width: 50%;
}

.detail-image img {
    width: 100%;
    max-height: 60vh;
    background: var(--c-light-bg);
    border-radius: var(--border-rad-md);
}

.detail-no-image {
    height: 30rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eee;
    border-radius: var(--border-rad-md);
    color: #888;
    font-size: 1.2rem;
}

.detail-info {
    display: flex;
    flex-direction: column;
}

.detail-info h1 {
    margin: 0;
}

.detail-content-row {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
    width: 100%;
    margin-top: 3rem;
    align-items: flex-start;
}

.detail-content-row .description-container,
.detail-content-row .detail-carousel {
    flex: 1;
    min-width: 18.75rem;
    margin-top: 0;
    width: 100%;
}

.description {
    color: #555;
    line-height: 1.5;
}

.description img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-rad-md);
    margin: 1rem 0;
}

.contact-box {
    margin: 1rem 0;
    padding: 1.5rem;
    background: #f0f0f0;
    border-radius: var(--border-rad-md);
    text-align: center;
}

.contact-box-2 {
    margin: 1rem 0;
    padding: 1.5rem;
    background: #f0f0f0;
    border-radius: var(--border-rad-md);
    text-align: left;
}

.contact-box-2 a {
    color: black;
}

.post-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 80vw;
    margin: 0 auto;
}

.post-content {
    width: 100%;
    overflow-wrap: break-word;
    word-wrap: break-word;
    box-sizing: border-box;
}

.post-container h1 {
    margin: 0 0 0.25rem;
}

.post-meta {
    color: #777;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.post-image {
    height: 40vh;
    background: #eee;
    border-radius: var(--border-rad-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-content img {
    height: 40vh;
    display: block;
    border-radius: var(--border-rad-lg);
    align-self: flex-start;
}

/* =========================================
   8. HOMEPAGE & CATALOG COMPONENTS
   ========================================= */
.hero-carousel-section {
    width: 100%;
    height: 70vh;
    background: var(--c-darker-bg);
}

.hero-carousel {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(17, 17, 17, 0.3) 0%, rgba(17, 17, 17, 0.1) 50%, rgba(17, 17, 17, 0) 100%);
    z-index: 1;
}

.hero-content {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 80%;
    background: rgba(0, 0, 0, 0.65);
    padding: 0.8rem 1.2rem;
    border-radius: 0.5rem;
    box-shadow: 0 0.25rem 0.9375rem rgba(0, 0, 0, 0.5);
}

.hero-content h2 {
    font-size: 1.4rem;
    margin: 0;
    font-family: 'Oswald', sans-serif;
}

.hero-content p {
    font-size: 0.9rem;
    margin: 0;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.home-section {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 5rem 0;
    background: #fff;
}

.home-section-header {
    text-align: center;
    margin-bottom: 1rem;
    padding: 0 2rem;
}

.home-section-header h2, .home-section-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.home-section-header p {
    color: var(--c-text-muted);
    font-size: 1.1rem;
    margin: 0;
}

.home-section-header p:first-of-type {
    margin-bottom: 0.5rem;
}

.home-section-footer {
    margin-top: 1rem;
    text-align: center;
}

.catalog-band-header {
    grid-column: 1 / -1;
    margin-top: 1.5rem;
    margin-bottom: -1.5rem;
    padding-bottom: 0.5rem;
}

/* =========================================
   9. CAROUSEL & LIGHTBOX
   ========================================= */
.antenna-carousel,
.blog-carousel {
    text-align: center;
    color: black;
    width: 50%;
}

.carousel-box-small {
    position: relative;
    width: 100%;
    aspect-ratio: 4/3;
    border-radius: var(--border-rad-lg);
    margin: 0 auto;
    overflow: hidden;
    background: #eee;
}

.carousel-item {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.carousel-item.active {
    opacity: 1;
    z-index: 1;
}

.carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.carousel-overlay {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(50, 50, 50, 0.85);
    border-radius: 0.5rem;
    color: white;
    width: 30%;
    z-index: 2;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.6);
    border: none;
    color: white;
    font-size: 2rem;
    padding: 0.5rem 1rem;
    cursor: pointer;
    z-index: 2;
    border-radius: 0.5rem;
}

.carousel-btn.prev {
    left: 0.625rem;
}

.carousel-btn.next {
    right: 0.625rem;
}

.carousel-btn:hover {
    background: black;
}

[onclick*="openLightbox"] {
    cursor: pointer;
}

/* =========================================
   10. ADMIN & DASHBOARD
   ========================================= */
.admin-container,
.admin-container-sm {
    width: 100%;
}

.dashboard-subtitle {
    color: var(--c-text-muted);
    margin-top: 0.5rem;
}

.dashboard-cards {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 3rem;
    width: 100%;
}

.dashboard-card {
    width: 18.75rem;
    text-align: center;
}

.dashboard-card-body {
    padding: 2.5rem 1.5rem;
}

.dashboard-card-text {
    font-size: 1.1rem;
    margin: 1.5rem 0;
}

.admin-category-header {
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    cursor: default;
}

#sortableList {
    width: 100%;
}

.admin-header-actions {
    display: flex;
    gap: 0.625rem;
}

.sortable-item {
    cursor: grab;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.sortable-item:active {
    cursor: grabbing;
}

.sortable-item.dragging {
    opacity: 0.5;
    box-shadow: 0 0.3125rem 0.9375rem rgba(0, 0, 0, 0.1);
}

.list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 1rem;
    background: var(--c-light-bg);
    border-radius: 0.6rem;
    margin-bottom: 0.7rem;
}

.list-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.list-info.flex-row {
    flex-direction: row;
    align-items: center;
}

.list-item-thumbnail {
    width: 3.125rem;
    height: 3.125rem;
    object-fit: cover;
    border-radius: 0.25rem;
    margin-right: 0.9375rem;
    border: 0.0625rem solid #ddd;
    pointer-events: none;
}

.list-item-thumbnail-placeholder {
    width: 3.125rem;
    height: 3.125rem;
    background: #f4f4f4;
    border-radius: 0.25rem;
    margin-right: 0.9375rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.625rem;
    color: #aaa;
    border: 0.0625rem solid #ddd;
    pointer-events: none;
}

.list-item-details {
    display: flex;
    flex-direction: column;
    pointer-events: none;
}

.list-item-category {
    font-size: 0.9em;
    color: #666;
}

.list-actions {
    display: flex;
    gap: 0.5rem;
}

.list-actions button,
.list-actions a {
    padding: 0.4rem 0.8rem;
    border-radius: 0.4rem;
    border: none;
    cursor: pointer;
    background: var(--c-dark-bg);
    color: white;
}

.list-actions .danger {
    background: var(--c-danger);
}

.gallery-row {
    display: flex;
    gap: 0.625rem;
    margin-bottom: 0.5rem;
    align-items: center;
}

.remove-row-btn {
    background: transparent;
    color: var(--c-danger);
    border: 0.0625rem solid var(--c-danger);
    border-radius: 0.3rem;
    cursor: pointer;
    font-weight: bold;
    padding: 0.4rem 0.8rem;
    height: 100%;
}

.remove-row-btn:hover {
    background: var(--c-danger);
    color: white;
}

.existing-photo-row {
    display: flex;
    gap: 0.9375rem;
    margin-bottom: 0.8rem;
    align-items: center;
    background: #f9f9f9;
    padding: 0.8rem;
    border-radius: 0.5rem;
    border: 0.0625rem solid #eee;
}

.existing-photo-row img {
    height: 3.125rem;
    width: 4.375rem;
    object-fit: contain;
    border-radius: 0.3rem;
    background: white;
    border: 0.0625rem solid #ddd;
}

input[type="file"] {
    width: 100%;
    border: none;
    padding: 0;
}

#editor {
    height: 25rem;
    background: white;
    border-radius: 0 0 0.3rem 0.3rem;
    font-family: var(--font-main);
}

.ql-toolbar {
    background: var(--c-light-bg);
    border-radius: 0.3rem 0.3rem 0 0;
}

/* =========================================
   11. MODALS & UTILS
   ========================================= */
.login-body {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: var(--c-light-bg);
    margin: 0;
}

.login-card-pad {
    padding: 2rem;
    width: 100%;
    max-width: 25rem;
}

.login-form {
    display: flex;
    flex-direction: column;
}

.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-rad-md);
    width: 18.75rem;
}

.modal-content-large {
    width: 56.25rem;
    max-width: 95%;
}

.modal-content-scrollable {
    width: 43.75rem;
    max-width: 95%;
    max-height: 85vh;
    overflow-y: auto;
}

.modal-divider {
    margin: 1.5rem 0;
    border-top: 0.0625rem solid #ddd;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.modal-actions button {
    flex: 1;
    margin: 0;
    cursor: pointer;
}

.modal form label {
    display: block;
    margin: 1rem 0 0.3rem;
}

.modal form input[type="text"],
.modal form select,
.modal form textarea {
    width: 100%;
    margin-bottom: 0.5rem;
}

.modal form input[type="checkbox"] {
    width: auto;
    margin-right: 0.5rem;
}

#existing-cover-container,
#existing-gallery-container,
#existing-photo-container,
#multi-file-input,
#existing-cover {
    display: none;
}

#existing-img {
    max-height: 9.375rem;
    border-radius: 0.25rem;
}

#coverPreview {
    max-height: 5rem;
    border-radius: 0.25rem;
    border: 0.0625rem solid #ccc;
}

#lightboxModal {
    flex-direction: column;
}

.lightbox-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 90%;
}

#lightboxImg {
    max-width: 100%;
    max-height: 70vh;
    border-radius: var(--border-rad-md);
    object-fit: contain;
}

#lightboxDesc {
    color: white;
    margin-top: 1rem;
    font-size: 1.2rem;
    text-align: center;
}

.section-divider {
    border: none;
    border-top: 0.0625rem solid #eaeaea;
    width: 80vw;
}

.slide-thumbnail {
    width: 5rem;
    height: 3.125rem;
    object-fit: cover;
    border-radius: 0.25rem;
    margin-right: 0.9375rem;
    pointer-events: none;
}

.slide-title {
    pointer-events: none;
}

/* =========================================
   12. MOBILE RESPONSIVENESS
   ========================================= */
@media (max-width: 48em) {
    main {
        margin-top: 5rem;
    }

    .content-container {
        max-width: 100vw;
        padding: 2rem 1.5rem;
        grid-template-columns: 1fr;
    }

    main.catalog {
        padding: 0 1rem 1rem;
    }

    header {
        height: auto;
        min-height: 4rem;
        flex-wrap: wrap;
        padding: 0.5rem 1.5rem;
    }

    .header-logo {
        height: 2.5rem;
        width: auto;
    }

    .mobile-menu-toggle {
        display: block;
    }

    nav {
        display: none;
        width: 100%;
        flex-direction: column;
        gap: 0.8rem;
        padding-top: 1rem;
        padding-bottom: 1rem;
    }

    nav.nav-open {
        display: flex;
    }

    .nav-link.btn-outline-light {
        width: 100%;
        text-align: center;
        box-sizing: border-box;
    }

    .custom-dropdown {
        margin: 0 auto;
    }

    .nav-logout {
        margin-left: 0;
        text-align: center;
        width: 100%;
    }

    footer {
        flex-direction: column;
        text-align: center;
        padding: 2rem 1.5rem;
    }

    .blog-header {
        min-height: 40vh;
        padding: 3rem 1.5rem;
    }

    .blog-header h1 {
        font-size: 2rem;
    }

    .blog-search-bar {
        flex-direction: column;
    }

    .hero-carousel-section {
        height: 60vh;
        min-height: 25rem;
    }

    .hero-content {
        bottom: 1.5rem;
        width: 80%;
        padding: 0.6rem 1rem;
    }

    .hero-content h2 {
        font-size: 1rem;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-gradient {
        position: absolute;
        inset: 0;
        background: linear-gradient(to top, rgba(17, 17, 17, 0.3) 0%, rgba(17, 17, 17, 0.1) 50%, rgba(17, 17, 17, 0) 100%);
        z-index: 1;
    }

    .detail-container,
    .detail-content-row {
        flex-direction: column;
        gap: 2rem;
    }

    .detail-image,
    .detail-info,
    .antenna-carousel,
    .blog-carousel {
        width: 100%;
    }

    .detail-image img {
        max-height: 50vh;
        object-fit: cover;
    }

    .carousel-overlay {
        width: 80%;
    }

    .dashboard-cards {
        flex-direction: column;
        align-items: center;
    }

    .dashboard-card {
        width: 100%;
        max-width: 21.875rem;
    }

    .list-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .list-actions {
        width: 100%;
        flex-wrap: wrap;
    }

    .list-actions button,
    .list-actions form {
        flex: 1;
        text-align: center;
    }

    .modal-content,
    .modal-content-large,
    .modal-content-scrollable {
        width: 95%;
        padding: 1.5rem 1rem;
    }

    .existing-photo-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .existing-photo-row img {
        width: 100%;
        height: auto;
        max-height: 9.375rem;
    }

    .home-section-header h2 {
        font-size: 1.75rem;
    }

    .login-card-pad {
        padding: 1.5rem;
        width: 90%;
    }

    input,
    textarea,
    select {
        padding: 0.75rem;
        font-size: 1rem;
    }

    .login-form label {
        margin-top: 1.2rem;
        margin-bottom: 0.4rem;
    }

    .btn-full-large {
        padding: 1rem;
        font-size: 1.1rem;
    }

    .visitor-stats-box {
        width: 100%;
        box-sizing: border-box;
    }
}

/*=========================================
   13. DARK MODE OVERRIDES
   ========================================= */
[data-theme="dark"] {
    --c-light-bg: #2a2a2a; 
    --c-dark-bg: #1e1e1e;
    --c-darker-bg: #121212;
    --c-darkest-bg: #0f0f0f;
    --c-text-muted: #aaa;
    --c-text-main: #e0e0e0;
    --c-border: #333;
    --shadow-sm: 0 0.125rem 0.3125rem rgba(0, 0, 0, 0.5);
    --shadow-md: 0 0.25rem 0.9375rem rgba(0, 0, 0, 0.5);
    --shadow-hover: 0 0.5rem 1.5625rem rgba(0, 0, 0, 0.7);
}

/* Base Body & Layouts */
[data-theme="dark"] body,
[data-theme="dark"] .login-body {
    background-color: var(--c-darker-bg);
    color: var(--c-text-main);
}

[data-theme="dark"] header,
[data-theme="dark"] footer {
    background-color: var(--c-darkest-bg);
}

[data-theme="dark"] main,
[data-theme="dark"] section,
[data-theme="dark"] .home-section,
[data-theme="dark"] .hero-carousel-section {
    background-color: var(--c-darker-bg);
    color: var(--c-text-main);
}

/* Global Typography Fixes */
[data-theme="dark"] .antenna-detail,
[data-theme="dark"] .post-page,
[data-theme="dark"] .blog-card-content h2,
[data-theme="dark"] .product-card-content h2,
[data-theme="dark"] .card-body p,
[data-theme="dark"] .description,
[data-theme="dark"] .contact-box p,
[data-theme="dark"] .contact-box-2 p,
[data-theme="dark"] .home-section-header h2,
[data-theme="dark"] .list-item-category,
[data-theme="dark"] .color-444 {
    color: var(--c-text-main);
}

[data-theme="dark"] .blog-author,
[data-theme="dark"] .blog-read-more,
[data-theme="dark"] .product-read-more,
[data-theme="dark"] .link-muted {
    color: var(--c-text-muted);
}

[data-theme="dark"] .blog-card-content h2 a:hover,
[data-theme="dark"] .product-card-content h2 a:hover {
    color: #fff;
}

/* Cards & Modals */
[data-theme="dark"] .blog-card,
[data-theme="dark"] .product-card,
[data-theme="dark"] .modal-content,
[data-theme="dark"] #editor {
    background-color: var(--c-dark-bg);
    border-color: var(--c-border);
}

[data-theme="dark"] .empty-state,
[data-theme="dark"] .empty-state-large,
[data-theme="dark"] .contact-box,
[data-theme="dark"] .contact-box-2,
[data-theme="dark"] .existing-photo-row,
[data-theme="dark"] .list-item-thumbnail-placeholder,
[data-theme="dark"] .detail-no-image {
    background-color: var(--c-light-bg);
    border-color: var(--c-border);
    color: var(--c-text-main);
}

[data-theme="dark"] .contact-box a,
[data-theme="dark"] .contact-box-2 a {
    color: var(--c-text-main);
}

/* Inputs, Forms & Dropdowns */
[data-theme="dark"] input:not([type="checkbox"]),
[data-theme="dark"] textarea,
[data-theme="dark"] select {
    background-color: var(--c-dark-bg);
    color: var(--c-text-main);
    border-color: var(--c-border);
}

[data-theme="dark"] .dropdown-options li:hover {
    background-color: var(--c-light-bg);
}

/* Admin / Dashboard Fixes */
[data-theme="dark"] .ql-toolbar {
    background: var(--c-light-bg);
    border-bottom: 1px solid var(--c-border);
}

/* Dividers & Borders */
[data-theme="dark"] .modal-divider,
[data-theme="dark"] .section-divider {
    border-top-color: var(--c-border);
}

/* Buttons */
[data-theme="dark"] .btn-outline-dark {
    border-color: var(--c-text-main);
    color: var(--c-text-main);
}

[data-theme="dark"] .btn-outline-dark:hover {
    background-color: var(--c-text-main);
    color: var(--c-dark-bg);
}

[data-theme="dark"] .card-btn,
[data-theme="dark"] .contact-btn {
    background: #333;
}

[data-theme="dark"] .card-btn:hover,
[data-theme="dark"] .contact-btn:hover {
    background: #444;
}

/* 1. Fix the Toolbar Background and Border */
[data-theme="dark"] .ql-toolbar.ql-snow {
  background-color: #2b2b2b; /* Match your dark background */
  border-color: #444 !important;
}

/* 2. Fix the Editor Container */
[data-theme="dark"] .ql-container.ql-snow {
  background-color: #1e1e1e;
  border-color: #444 !important;
  color: var(--c-text-main); /* Ensure text inside the editor is white */
}

/* 3. Fix the Toolbar Icons (The most important part) */
[data-theme="dark"] .ql-snow .ql-stroke {
  stroke: var(--c-text-main) !important;
}

[data-theme="dark"].ql-snow .ql-fill {
  fill: var(--c-text-main) !important;
}

[data-theme="dark"] .ql-snow .ql-picker {
  color: var(--c-text-main) !important;
}

/* 4. Fix Dropdown/Picker Menus */
[data-theme="dark"] .ql-snow .ql-picker-options {
  background-color: #333 !important;
  color: #fff !important;
  border: 1px solid #444 !important;
}

.ql-snow .ql-fill, .ql-snow .ql-stroke.ql-fill {
    fill: var(--c-text-main) !important;
}

/* Remove margins and paddings for all standard elements inside the description */
.description p, 
.description h1, 
.description h2, 
.description h3, 
.description ul, 
.description ol {
    margin: 0 !important;
}

.description p, .description li {
    font-size: 1.1rem;
}

.ql-editor {
    padding: 0 !important;
    white-space: normal !important;
}

.desc-note {
    display: inline;
    font-style: italic;
    font-size: 0.8rem;
    font-weight: 400;
    margin: 0;
}

.lang-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-color: transparent;
    color: #fff;
    padding: 8px 38px 8px 14px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 1.5rem;
    padding: 0.5rem 1rem 0.5rem 1rem;
}

.lang-select option {
    text-align: center;
}

.ql-editor li[data-list="bullet"] {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.ql-editor li[data-list="bullet"]::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: currentColor;
  display: inline-block;
  flex-shrink: 0;
  margin-top: 0.55em;
}

.ql-editor li[data-list="bullet"] > .ql-ui::before {
    content: none;
    padding: 0;
}