/* ===== Variables ===== */
:root {
    --rotary-blue:        #003478;
    --rotary-blue-dark:   #002560;
    --rotary-yellow:      #F6A100;
    --rotary-yellow-dark: #d88e00;
    --navbar-height:      4rem;
    --footer-height:      3rem;
}

/* ===== Layout ===== */
body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: transparent;
}

main { flex: 1; }

main > .section:first-child {
    padding-top: calc(1.5rem + var(--navbar-height));
}

/* ===== Fond global flou (couvre toute la page, footer inclus) ===== */
.page-bg {
    position: fixed;
    inset: -20px;
    z-index: -2;
    background-size: cover;
    background-position: center;
    filter: blur(6px);
}

.page-overlay {
    position: fixed;
    inset: 0;
    z-index: -1;
    background: rgba(0, 20, 50, 0.38);
}

/* ===== Navbar ===== */
.navbar-rotary {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: var(--navbar-height);
    background: transparent !important;
}

/* Tous les liens navbar */
.navbar-rotary .navbar-item {
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.88rem;
    letter-spacing: 0.3px;
    transition: color 0.15s, background-color 0.15s, border-color 0.15s;
}

/* Pills — liens centraux + Connexion */
.navbar-center .navbar-item,
.navbar-rotary .nav-pill {
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 0.35rem 1rem;
    margin: auto 0.2rem;
}

.navbar-center .navbar-item:hover,
.navbar-center .navbar-item:focus,
.navbar-rotary .nav-pill:hover,
.navbar-rotary .nav-pill:focus {
    background-color: rgba(255, 255, 255, 0.12) !important;
    border-color: rgba(255, 255, 255, 0.6) !important;
    color: #fff !important;
}

.navbar-center .navbar-item.is-active,
.navbar-rotary .nav-pill.is-active {
    background-color: transparent !important;
    border-color: var(--rotary-yellow) !important;
    color: var(--rotary-yellow) !important;
    font-weight: 600;
}

/* Aligne la taille des boutons navbar sur celle des pills */
.navbar-rotary .button {
    font-size: 0.88rem;
    height: auto;
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
}

/* Retire le hover sur les wrappers de boutons */
.navbar-rotary .navbar-end div.navbar-item:hover,
.navbar-rotary .navbar-end div.navbar-item:focus {
    background-color: transparent !important;
    cursor: default;
}

/* Centrage desktop */
@media screen and (min-width: 1024px) {
    .navbar-rotary .navbar-menu {
        display: flex;
        flex: 1;
        align-items: stretch;
    }
    .navbar-center {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        height: var(--navbar-height);
        display: flex;
        align-items: stretch;
    }
    .navbar-rotary .navbar-end {
        display: flex;
        align-items: center;
        margin-left: auto;
        padding-right: 1rem;
    }
}

/* Mobile */
@media screen and (max-width: 1023px) {
    .navbar-rotary .navbar-menu.is-active {
        background: rgba(0, 30, 70, 0.97);
    }
    .navbar-rotary .navbar-menu.is-active .navbar-item {
        color: rgba(255, 255, 255, 0.85);
    }
}

.navbar-rotary .navbar-burger span {
    background-color: #fff;
    height: 2px;
}

/* ===== Logo ===== */
.logo-item {
    gap: 0 !important;
    padding: 0 1.25rem !important;
    align-items: center !important;
    height: var(--navbar-height) !important;
}
.logo-img {
    height: 42px;
    width: auto;
    margin-right: 0.65rem;
}
.logo-rotary {
    font-size: 1.25rem;
    font-weight: 800;
    color: #fff;
    white-space: nowrap;
    letter-spacing: 0.3px;
}
.logo-sep {
    display: inline-block;
    width: 1px;
    height: 26px;
    background: rgba(255, 255, 255, 0.3);
    margin: 0 0.65rem;
    flex-shrink: 0;
    align-self: center;
}
.logo-club-block {
    font-size: 0.9rem;
    font-weight: 800;
    color: #fff;
    line-height: 1.2;
}

/* ===== Buttons ===== */
.button.is-primary {
    background-color: var(--rotary-blue);
    border-color: transparent;
    transition: background-color 0.15s;
}
.button.is-primary:hover { background-color: var(--rotary-blue-dark); border-color: transparent; }
.button.is-primary:focus,
.button.is-primary:active {
    background-color: var(--rotary-blue-dark);
    border-color: transparent;
    box-shadow: 0 0 0 3px rgba(0, 52, 120, 0.25);
}
.button.is-primary.is-outlined {
    background-color: transparent;
    border-color: rgba(255, 255, 255, 0.8);
    color: #fff;
}
.button.is-primary.is-outlined:hover {
    background-color: rgba(255, 255, 255, 0.15);
    color: #fff;
    border-color: #fff;
}

.button.is-warning {
    background-color: var(--rotary-yellow);
    border-color: transparent;
    color: var(--rotary-blue);
    font-weight: 700;
    transition: background-color 0.15s;
}
.button.is-warning:hover { background-color: var(--rotary-yellow-dark); border-color: transparent; color: var(--rotary-blue); }
.button.is-warning:focus,
.button.is-warning:active {
    background-color: var(--rotary-yellow-dark);
    border-color: transparent;
    color: var(--rotary-blue);
    box-shadow: 0 0 0 3px rgba(246, 161, 0, 0.3);
}

/* ===== Text helpers ===== */
.has-text-primary { color: var(--rotary-blue) !important; }
.has-text-warning { color: var(--rotary-yellow) !important; }

/* ===== Footer — override Bulma whitesmoke ===== */
.footer {
    background-color: transparent !important;
    background: transparent !important;
    padding: 0;
    height: var(--footer-height);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.footer .content p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.78rem;
    margin: 0;
}

/* ===== Hero pleine page ===== */
.hero-fullpage {
    position: relative;
    height: calc(100vh - var(--footer-height));
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: calc(var(--navbar-height) + 2rem) 2rem 2rem;
}

.hero-text-block {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-overlay-box {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(6px);
    border-radius: 10px;
    padding: 2.5rem 3rem;
    max-width: 620px;
    width: 100%;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
}

.hero-bottom-cards {
    display: flex;
    gap: 1rem;
    flex-shrink: 0;
    max-width: 860px;
    width: 100%;
    margin: 0 auto;
}

.hero-card {
    flex: 1;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(6px);
    border-radius: 8px;
    padding: 1rem 1.1rem;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}
.hero-card-icon {
    color: var(--rotary-yellow);
    font-size: 1.2rem;
    flex-shrink: 0;
    margin-top: 2px;
}
.hero-card-body p:first-child {
    font-weight: 700;
    font-size: 0.83rem;
    color: var(--rotary-blue);
    margin-bottom: 0.15rem;
}
.hero-card-body p:last-child {
    font-size: 0.78rem;
    color: #444;
    line-height: 1.4;
}

/* ===== Tabs (panel admin + classement public) ===== */
.tabs.is-boxed li a:hover {
    background-color: rgba(0, 52, 120, 0.25) !important;
    border-color: rgba(0, 52, 120, 0.45) !important;
    color: #fff !important;
}

/* ===== Boutons texte (panel admin) ===== */
.btn-text {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font-size: 0.8rem;
    text-decoration: underline;
    text-underline-offset: 2px;
    white-space: nowrap;
}
.btn-text:hover { opacity: 0.7; }

/* ===== Toasts ===== */
#toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 9999;
    width: 320px;
    pointer-events: none;
}
#toast-container .notification {
    pointer-events: auto;
    margin-bottom: 0.75rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transition: opacity 0.4s ease;
}
#toast-container .notification.is-hiding { opacity: 0; }
