/* --- Базові стилі --- */
body {
    font-size: 14px;
    line-height: 1.5;
    background-color: #121212;
    color: #f1f1f1;
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
}

h1, h2, h3, h4, h5 {
    font-family: 'Montserrat', sans-serif;
    color: #ffffff;
}
h1 { font-size: 2rem; }

/* --- Навігація --- */
.navbar {
    background-color: #1e1e1e; /* залишено як у продакшені */
    padding: 1rem 0;
    min-height: 60px;
}

.navbar-brand {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 1.5rem;
    color: #ffffff !important;
    text-transform: uppercase;
}

.navbar-nav .nav-link {
    color: #f8f9fa !important;
    font-weight: 500;
    text-transform: uppercase;
    margin-right: 1rem;
    transition: color 0.3s ease;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: #ffc107 !important;
}

/* пункт 1 — зменшено висоту */
.navbar-collapse {
    min-height: auto;
}

/* --- Кнопки --- */
.btn-primary {
    background-color: #ffc107;
    border-color: #ffc107;
    color: #000;
    font-weight: 600;
    text-transform: uppercase;
}

.btn-primary:hover {
    background-color: #e0a800;
    border-color: #d39e00;
    color: #000;
}

.btn-outline-primary {
    color: #ffc107;
    border-color: #ffc107;
    text-transform: uppercase;
}

.btn-outline-primary:hover {
    background-color: #ffc107;
    color: #000;
}

/* --- Картки --- */
.card {
    background-color: #1e1e1e;
    border: none;
    color: #f1f1f1;
    min-height: 250px;
}

.card img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block;
}

.card-title {
    font-weight: 600;
    color: #ffffff;
}

.card-text {
    color: #ccc;
}

.card-footer {
    background-color: #2c2c2c;
    border-top: none;
    color: #999;
}

.card-title a {
    transition: all 0.2s ease;
    color: inherit;
    text-decoration: none;
}

.card-title a:hover {
    text-decoration: underline;
    font-weight: 500;
}

/* --- Footer --- */
footer {
    background-color: #1e1e1e;
    color: #ccc;
    padding: 2rem 0;
    text-align: center;
}

footer a {
    color: #ffc107;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* --- Адаптивність --- */
@media (min-width: 992px) {
    .navbar-nav {
        justify-content: center;
    }
}

@media (max-width: 991.98px) {
    .navbar-collapse {
        background-color: #2c2c2c;
        padding: 1rem;
        border-radius: 0.5rem;
    }

    .btn-nav {
        display: block;
        width: 100%;
        text-align: left;
        margin-bottom: 0.5rem;
    }
}

/* --- Glassmorphism background --- */
.glass {
    background: rgba(30, 30, 30, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1030;
    min-height: 60px;
}

/* --- Nav link animation --- */
.btn-nav {
    color: #f8f9fa;
    padding: 8px 16px;
    font-weight: 500;
    border-radius: 0.5rem;
    position: relative;
    transition: color 0.3s ease;
}

.btn-nav::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 100%;
    height: 2px;
    background: #ffc107;
    transform: translateX(-50%) scaleX(0);
    transform-origin: center;
    transition: transform 0.3s ease;
}

.btn-nav:hover::after {
    transform: translateX(-50%) scaleX(1);
}

/* --- Dark & Light Mode --- */
body.dark-mode {
    background-color: #121212;
    color: #f0f0f0;
}

body.dark-mode .glass {
    background: rgba(0, 0, 0, 0.5);
}

body.dark-mode .btn-nav {
    color: #f8f9fa;
}

body.dark-mode .navbar-brand {
    color: #ffc107;
}

/* --- Small button --- */
.small-btn {
    font-size: 0.5rem;
    padding: 0.25rem 0.5rem;
}

/* --- Глобальні елементи мультимедіа --- */
img, video, iframe {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ==========================
   Navbar Adaptive Styles
========================== */

.navbar-brand {
    font-size: 1.3rem;
    font-weight: 700;
    white-space: nowrap;
    display: inline-block;
    max-width: 80%;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 991.98px) {
    .navbar-brand {
        font-size: 1.3rem;
    }
}

@media (max-width: 575.98px) {
    .navbar-brand {
        font-size: 1.1rem;
    }
}

.navbar {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

@media (max-width: 991.98px) {
    .navbar {
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
    }
}

@media (max-width: 575.98px) {
    .navbar {
        padding-top: 0.4rem;
        padding-bottom: 0.4rem;
    }
}

.navbar .btn,
.navbar .navbar-toggler {
    font-size: 0.9rem;
}

@media (max-width: 991.98px) {
    .navbar-collapse {
        text-align: center;
    }

    .navbar-nav {
        margin-top: 0.5rem;
    }
}

/* --- пункт 8: адаптивний логотип --- */
.navbar-brand img {
    height: 40px;
    width: auto;
    max-height: 100%;
    object-fit: contain;
}

@media (max-width: 992px) {
    .navbar-brand img {
        height: 32px;
    }
}

.navbar-brand {
    display: flex;
    align-items: center;
}

.navbar {
    min-height: 56px;
}
