/**
 * Стили для Teokratia
 */

/* Подключаем шрифт Roboto */
body {
    font-family: 'Roboto', 'Arial', sans-serif;
    background-color: #f5f5f5;
}

.title {
    color: #3273dc;
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.subtitle {
    color: #4a4a4a;
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.section {
    background: white;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.buttons .button {
    margin-bottom: 0.5rem;
}

.buttons .button i {
    margin-right: 0.5rem;
}

.title i {
    margin-right: 0.5rem;
    color: #ffd700;
}

.subtitle i {
    margin-right: 0.5rem;
    color: #3273dc;
}

.db-info {
    margin: 2rem 0;
}

.db-info .message {
    margin-bottom: 0;
}

.header-section {
    margin-bottom: 2rem;
}

.user-info {
    margin: 1.5rem 0;
}

.user-info .message {
    margin-bottom: 0;
}

.auth-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.auth-buttons .button {
    margin-bottom: 0.5rem;
}

.auth-buttons .button i {
    margin-right: 0.5rem;
}

/* Bulma-like container and section styles */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 3rem 1.5rem;
}

@media screen and (min-width: 1024px) {
    .container {
        padding: 0 40px;
    }
}

/* Топбар стили */
.navbar-brand .navbar-item {
    font-weight: bold;
    font-size: 1.2rem;
}

.navbar-title {
    margin-left: 0.5rem;
}

.navbar-item i {
    margin-right: 0.5rem;
}

.navbar-burger {
    color: white;
}

.navbar-burger span {
    background-color: white;
}

/* Герой секция */
.hero-section {
    text-align: center;
    padding: 4rem 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    margin-bottom: 2rem;
    border-radius: 0 0 20px 20px;
}

.hero-content .title {
    color: white;
    margin-bottom: 1rem;
}

.hero-content .title i {
    color: #ffd700;
    margin-right: 1rem;
}

.hero-content .subtitle {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
}

.hero-content .subtitle i {
    color: #87ceeb;
    margin-right: 0.5rem;
}

.welcome-message {
    max-width: 600px;
    margin: 0 auto;
}

/* Системная информация */
.system-info {
    margin: 2rem 0;
}

.system-info .message {
    height: 100%;
}

/* Кнопки действий */
.action-buttons {
    margin: 3rem 0;
}

.action-buttons .button {
    margin: 0.5rem;
}

/* Модальные окна */
.modal-card-foot .level {
    margin-bottom: 1rem;
}

.modal-card-foot .level a {
    cursor: pointer;
    text-decoration: none;
}

.modal-card-foot .level a:hover {
    text-decoration: underline;
}

.modal-card-foot .level a i {
    margin-right: 0.5rem;
}

/* Индикатор загрузки */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.loading-spinner {
    text-align: center;
    color: #3273dc;
}

.loading-spinner i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.loading-spinner p {
    font-size: 1.2rem;
    font-weight: 500;
}

/* Скрытие контента до загрузки Vue.js */
#app > *:not(#loading-indicator) {
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

#app.vue-loaded > *:not(#loading-indicator) {
    opacity: 1;
}

/* Скрытие модальных окон до загрузки Vue.js */
.modal {
    display: none !important;
}

.modal.is-active {
    display: flex !important;
}

/* Адаптивность */
@media screen and (max-width: 768px) {
    .hero-section {
        padding: 2rem 0;
    }
    
    .hero-content .title {
        font-size: 2rem;
    }
    
    .hero-content .subtitle {
        font-size: 1.2rem;
    }
    
    .action-buttons .buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .action-buttons .button {
        width: 100%;
        max-width: 300px;
    }
}

/* Sticky навбар */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    min-height: 3.25rem;
}

/* Обеспечиваем правильную высоту навбара */
.navbar-brand,
.navbar-menu {
    min-height: 3.25rem;
}

.navbar-item {
    min-height: 3.25rem;
    display: flex !important;
    align-items: center !important;
}

/* Добавляем отступ для контента, чтобы он не скрывался под sticky навбаром */
body {
    padding-top: 0; /* Bulma навбар уже имеет правильную высоту */
}

/* Улучшаем внешний вид sticky навбара */
.navbar.is-primary {
    background-color: #3273dc !important;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

/* Анимация для плавного появления тени при скролле */
.navbar {
    transition: box-shadow 0.3s ease;
}

.navbar.scrolled {
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}
.navbar-brand .navbar-item  {
    padding-left:0 !important;
}
/* Вертикальное центрирование кнопки входа - более агрессивные правила */
.navbar .navbar-end .navbar-item {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 3.25rem !important;
    padding: 0 !important;
}

.navbar .navbar-end .buttons {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 100% !important;
    margin: 0 !important;
}

/* Дополнительное центрирование для кнопки */
.navbar .navbar-end .button {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 2.25rem !important;
    margin: 0 !important;
}

/* Принудительное центрирование для всех элементов навбара */
.navbar .navbar-menu .navbar-end {
    display: flex !important;
    align-items: center !important;
    height: 3.25rem !important;
}

/* ===== ПРИНУДИТЕЛЬНОЕ ПРИМЕНЕНИЕ ROBOTO ===== */
/* Переопределяем все шрифты Buefy/Bulma в конце файла для максимальной специфичности */

/* Основное переопределение шрифтов */
body, button, input, optgroup, select, textarea, p, div, span, h1, h2, h3, h4, h5, h6 {
    font-family: 'Roboto', 'Arial', sans-serif;
}

/* Специфичные селекторы для переопределения Buefy */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
    font-family: 'Roboto', 'Arial', sans-serif;
}

/* Переопределение для всех элементов форм */
body, button, input, optgroup, select, textarea {
    font-family: 'Roboto', 'Arial', sans-serif;
}

/* Специально для Buefy/Bulma компонентов с высокой специфичностью */
.button, .input, .textarea, .select select, .file-input,
.card, .card-header, .card-content, .card-footer,
.navbar, .navbar-item, .navbar-brand, .navbar-menu,
.tabs, .tab-content, .tab-item,
.modal, .modal-card, .modal-card-head, .modal-card-body, .modal-card-foot,
.notification, .message, .field, .label,
.table, .dropdown, .dropdown-item,
.switch, .checkbox, .radio,
.b-field, .b-input, .b-button, .b-switch, .b-checkbox, .b-select {
    font-family: 'Roboto', 'Arial', sans-serif;
}

/* Дополнительные селекторы для Vue компонентов */
#app, #app * {
    font-family: 'Roboto', 'Arial', sans-serif;
}

/* ===== НАВБАР ===== */

/* Sticky навбар */
.navbar {
    position: sticky !important;
    top: 0 !important;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: box-shadow 0.3s ease;
}

.navbar.scrolled {
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* Выравнивание контейнера навбара с основным контентом */
.navbar .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Кнопка входа - центрирование */
.navbar-end .navbar-item {
    display: flex !important;
    align-items: center !important;
    height: 3.25rem !important;
}

.navbar-end .button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.field-label.is-wide {
    flex-grow: 2;
}
