/**
 * Club Section Styles - MotoForma.cz
 * Modular styles for the club member area
 */

/* ==========================================
   LAYOUT
   ========================================== */

.club-layout {
    display: flex;
    min-height: 60vh;
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.club-sidebar {
    width: 240px;
    flex-shrink: 0;
    background: white;
    border-right: 1px solid var(--mf-border);
    padding: 1.25rem 0;
}

.club-sidebar__nav {
    list-style: none;
    margin: 0;
    padding: 0;
}

.club-sidebar__item {
    margin: 0 0.75rem 0.25rem;
}

.club-sidebar__link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: var(--mf-gray-600);
    text-decoration: none;
    font-weight: var(--font-medium);
    font-size: 1rem;
    transition: all var(--transition-fast);
    border-radius: var(--radius-md);
}

.club-sidebar__link:hover {
    background: var(--mf-surface-hover);
    color: var(--mf-red);
}

.club-sidebar__link.is-active {
    background: var(--mf-red);
    background: linear-gradient(135deg, var(--mf-red) 0%, var(--mf-red-dark) 100%);
    color: #fff;
    box-shadow: var(--shadow-red);
}

.club-sidebar__link i {
    width: 20px;
    text-align: center;
    font-size: 1rem;
    transition: transform var(--transition-fast);
}

.club-sidebar__link:hover i {
    transform: scale(1.1);
}

.club-sidebar__link.is-active i {
    transform: none;
}

.club-sidebar__divider {
    height: 1px;
    background: var(--mf-border);
    margin: 0.75rem 1.25rem;
}

.club-sidebar__logout {
    margin-top: 0.5rem;
}

.club-sidebar__link--danger {
    color: var(--mf-gray-500);
}

.club-sidebar__link--danger:hover {
    background: var(--mf-danger-light);
    color: var(--mf-danger);
}

.club-content {
    flex: 1;
    padding: 2rem;
    min-width: 0;
    background: var(--mf-surface-subtle);
}

/* Mobile sidebar */
@media (max-width: 991px) {
    .club-layout {
        flex-direction: column;
        border-radius: 0;
        box-shadow: none;
    }

    .club-sidebar {
        width: 100%;
        padding: 0.75rem 0;
        border-right: none;
        border-bottom: 1px solid var(--mf-border);
        background: white;
    }

    .club-sidebar__nav {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem;
        padding: 0 0.75rem;
    }

    .club-sidebar__item {
        margin: 0;
    }

    .club-sidebar__link {
        padding: 0.5rem 0.875rem;
        border-radius: var(--radius-pill);
        font-size: 1rem;
        background: var(--mf-surface-hover);
    }

    .club-sidebar__link:hover {
        background: var(--mf-border);
    }

    .club-sidebar__link.is-active {
        background: var(--mf-red);
        background: linear-gradient(135deg, var(--mf-red) 0%, var(--mf-red-dark) 100%);
        color: #fff;
        box-shadow: var(--shadow-red);
    }

    .club-sidebar__link--danger {
        background: transparent;
    }

    .club-sidebar__link--danger:hover {
        background: var(--mf-danger-light);
    }

    .club-sidebar__divider {
        display: none;
    }

    .club-content {
        padding: 1.5rem;
    }
}

/* ==========================================
   LOGOUT MODAL
   ========================================== */

.club-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: var(--z-modal);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.club-modal__backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}

.club-modal__dialog {
    position: relative;
    background: white;
    border-radius: var(--radius-xl);
    padding: 2rem;
    max-width: 380px;
    width: 100%;
    text-align: center;
    box-shadow: var(--shadow-xl);
}

.club-modal__icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.25rem;
    background: linear-gradient(135deg, var(--mf-danger-light) 0%, var(--mf-danger-bg) 100%);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--mf-red);
}

.club-modal__title {
    font-size: 1.5rem;
    font-weight: var(--font-bold);
    margin: 0 0 0.5rem;
    color: var(--text);
}

.club-modal__text {
    color: var(--mf-gray-500);
    margin: 0 0 1.5rem;
    line-height: 1.5;
}

.club-modal__actions {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

.club-modal__btn {
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-md);
    font-weight: var(--font-semibold);
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
}

.club-modal__btn--cancel {
    background: var(--mf-lighter);
    color: var(--text-strong);
}

.club-modal__btn--cancel:hover {
    background: var(--mf-lighter);
}

.club-modal__btn--confirm {
    background: linear-gradient(135deg, var(--mf-red) 0%, var(--mf-red-dark) 100%);
    color: #fff;
}

.club-modal__btn--confirm:hover {
    background: linear-gradient(135deg, var(--mf-red-dark) 0%, var(--mf-red-darker) 100%);
    box-shadow: var(--shadow-red);
}

/* Modal transitions */
.club-modal--enter {
    transition: all var(--transition-normal);
}

.club-modal--enter-start {
    opacity: 0;
    transform: scale(0.9) translateY(-20px);
}

.club-modal--enter-end {
    opacity: 1;
    transform: scale(1) translateY(0);
}

.club-modal--leave {
    transition: all var(--transition-fast);
}

.club-modal--leave-start {
    opacity: 1;
    transform: scale(1);
}

.club-modal--leave-end {
    opacity: 0;
    transform: scale(0.9);
}

/* ==========================================
   COMMON COMPONENTS
   ========================================== */

.badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: var(--font-medium);
}

.badge--yellow { background: var(--mf-warning-light); color: var(--mf-warning-dark); }
.badge--blue { background: var(--mf-info-light); color: var(--mf-info-dark); }
.badge--green { background: var(--mf-success-light); color: var(--mf-success-dark); }
.badge--red { background: var(--mf-danger-light-bg); color: var(--mf-danger-dark-text); }

/* ==========================================
   ADMIN TABLE
   ========================================== */

.admin-table {
    border-collapse: collapse;
    width: 100%;
}

.admin-table th,
.admin-table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid var(--mf-border-dark);
}

.admin-table th {
    background: var(--mf-surface-hover);
    font-weight: var(--font-semibold);
}

.admin-table tr:hover {
    background: var(--mf-surface-subtle);
}

/* ==========================================
   FEATURE CARDS
   ========================================== */

.feature-card__badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-pill);
    font-size: 1rem;
    font-weight: var(--font-semibold);
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.feature-card__badge--primary {
    background: var(--mf-red);
    color: white;
}

.feature-card__badge--secondary {
    background: var(--mf-secondary);
    color: white;
}

/* ==========================================
   FORM ENHANCEMENTS
   ========================================== */

.contact-form__submit--secondary {
    background: var(--mf-secondary);
    color: #fff;
}

.contact-form__submit--secondary:hover {
    background: var(--mf-secondary-dark);
}

/* ==========================================
   CLUB HEADER (for logged-in state)
   ========================================== */

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

.club-header__title {
    font-size: 1.75rem;
    margin: 0 0 0.5rem 0;
}

.club-header__subtitle {
    color: var(--mf-gray-500);
    margin: 0;
}

/* ==========================================
   PROFILE SECTION
   ========================================== */

.club-profile {
    max-width: 600px;
}

.club-profile__section {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--mf-lighter);
}

.club-profile__section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.club-profile__section-title {
    font-size: 1.25rem;
    margin: 0 0 1rem 0;
}

/* ==========================================
   ORDERS SECTION
   ========================================== */

.club-orders__empty {
    text-align: center;
    padding: 3rem 1rem;
}

.club-orders__empty p {
    margin-bottom: 1rem;
    color: var(--mf-gray-500);
}

/* ==========================================
   UPCOMING EVENTS
   ========================================== */

.club-upcoming__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.club-upcoming__empty {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--mf-gray-500);
}

/* ==========================================
   MOTORCYCLES LIST (Profile)
   ========================================== */

.motorcycles-list {
    margin-bottom: 0.75rem;
}

.motorcycles-list__loading,
.motorcycles-list__empty {
    padding: 1rem;
    text-align: center;
    color: var(--mf-gray-500);
    font-size: 1rem;
    background: var(--mf-light);
    border-radius: var(--radius-sm);
    border: 1px dashed var(--mf-border-dark);
}

.motorcycles-list__item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: white;
    border: 1px solid var(--mf-lighter);
    border-radius: var(--radius-sm);
    margin-bottom: 0.5rem;
    transition: all var(--transition-fast);
}

.motorcycles-list__item:hover {
    border-color: var(--mf-red);
    box-shadow: var(--shadow-sm);
}

.motorcycles-list__icon {
    color: var(--mf-red);
    font-size: 1rem;
}

.motorcycles-list__name {
    flex: 1;
    font-weight: var(--font-medium);
    color: var(--text);
}

.motorcycles-list__delete {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--mf-gray-300);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.motorcycles-list__delete:hover {
    background: var(--mf-danger-light);
    color: var(--mf-danger);
}

.motorcycles-list__delete:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.motorcycles-add {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.motorcycles-add__input {
    flex: 1;
}

.motorcycles-add__button {
    padding: 0.6rem 1rem;
    background: linear-gradient(135deg, var(--mf-red) 0%, var(--mf-red-dark) 100%);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: var(--font-medium);
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
}

.motorcycles-add__button:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-red);
}

.motorcycles-add__button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.contact-form__hint {
    display: block;
    color: var(--mf-gray-500);
    font-size: 1rem;
}

/* ==========================================
   FACELIFT 2027 — club area refresh
   ========================================== */

/* --- Auth card (login / reset / set password) --- */
.club-auth {
    max-width: 30rem;
    margin-inline: auto;
    padding: clamp(1.75rem, 3vw, 2.5rem);
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--r-xl);
    box-shadow: var(--shadow-md);
}

.club-auth .section-title {
    font-size: var(--step-3);
    text-align: center;
}

.club-auth .section__text {
    text-align: center;
    font-size: var(--step-0);
    margin-inline: auto;
}

.club-auth .contact-form__submit {
    margin-top: 0.5rem;
}

/* --- Member shell --- */
.club-layout {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--r-xl);
    box-shadow: none;
}

.club-sidebar {
    background: var(--paper);
    border-right: 1px solid var(--line);
}

.club-sidebar__link {
    font-size: var(--step--1);
    border-radius: var(--r-sm);
    color: var(--text-2);
}

.club-sidebar__link:hover {
    background: var(--bone);
    color: var(--text);
}

.club-sidebar__link.is-active {
    background: var(--ink-900);
    color: #fff;
    box-shadow: none;
}

.club-sidebar__divider {
    background: var(--line);
}

.club-content {
    background: var(--bone);
    padding: clamp(1.5rem, 3vw, 2.25rem);
}

@media (max-width: 991px) {
    .club-sidebar {
        border-bottom: 1px solid var(--line);
    }

    .club-sidebar__link {
        background: var(--bone);
    }

    .club-sidebar__link.is-active {
        background: var(--ink-900);
        box-shadow: none;
    }
}

/* --- Header --- */
.club-header__title {
    font-family: var(--font-display);
    font-size: var(--step-4);
    font-weight: var(--font-extrabold);
    letter-spacing: var(--track-display);
}

.club-header__subtitle {
    color: var(--text-2);
}

.club-profile__section {
    border-bottom-color: var(--line);
}

.club-profile__section-title {
    font-family: var(--font-display);
    font-size: var(--step-2);
    font-weight: var(--font-bold);
    letter-spacing: var(--track-tight);
}

/* --- Badges --- */
.badge {
    font-family: var(--font-display);
    font-size: var(--step--2);
    font-weight: var(--font-bold);
    letter-spacing: var(--track-wide);
    text-transform: uppercase;
    padding: 0.28rem 0.6rem;
    border-radius: var(--r-pill);
}

/* --- Tables --- */
.admin-table th {
    background: var(--bone);
    font-family: var(--font-display);
    font-size: var(--step--2);
    letter-spacing: var(--track-wide);
    text-transform: uppercase;
    color: var(--text-3);
}

.admin-table th,
.admin-table td {
    border-bottom-color: var(--line);
}

.admin-table tr:hover {
    background: var(--bone);
}

/* --- Modal --- */
.club-modal__dialog {
    border-radius: var(--r-xl);
}

.club-modal__icon {
    background: var(--brand-tint);
    color: var(--brand);
    border-radius: var(--r-lg);
}

.club-modal__title {
    font-family: var(--font-display);
    letter-spacing: var(--track-tight);
}

.club-modal__btn {
    border-radius: var(--r-pill);
    font-family: var(--font-display);
    font-weight: var(--font-bold);
}

.club-modal__btn--cancel {
    background: var(--bone-2);
    color: var(--text);
}

.club-modal__btn--confirm {
    background: var(--brand);
}

.club-modal__btn--confirm:hover {
    background: var(--brand-deep);
}

/* --- Motorcycles --- */
.motorcycles-list__item {
    border-color: var(--line);
    border-radius: var(--r-sm);
}

.motorcycles-list__item:hover {
    border-color: var(--line-strong);
    box-shadow: var(--shadow-sm);
}

.motorcycles-add__button {
    background: var(--ink-900);
    border-radius: var(--r-pill);
    padding: 0.7rem 1.2rem;
    font-family: var(--font-display);
    font-weight: var(--font-bold);
}

.motorcycles-add__button:hover {
    background: var(--ink-700);
    box-shadow: var(--shadow-md);
}

.motorcycles-list__loading,
.motorcycles-list__empty {
    background: var(--bone);
    border-color: var(--line-strong);
    border-radius: var(--r-sm);
    font-size: var(--step--1);
}

.contact-form__hint {
    font-size: var(--step--1);
    color: var(--text-3);
}

.club-page-head {
    padding-bottom: 0;
}

.club-panel-head {
    padding-top: 0;
}

.club-panel-head .section-title {
    font-size: var(--step-3);
}
