/* Page mécanique — armes */

.armes-general-info {
    display: flex;
    gap: 25px;
    align-items: center;
    width: 100%;
}

.armes-image {
    flex: 0 0 60%;
    max-width: 60%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.armes-image img {
    max-width: 500px;
    max-height: 500px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    border-radius: 15px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.armes-description {
    flex: 1;
    min-width: 0;
}

.armes-description p {
    color: rgba(255, 255, 255, 0.95);
    font-size: 1.05rem;
    line-height: 1.65;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
    margin: 0;
}

.sub-section-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-bottom: 25px;
}

.sub-section-btn.is-active {
    background: rgba(255, 255, 255, 0.35);
    border-color: rgba(255, 255, 255, 0.55);
}

.sub-section-panel {
    display: none;
}

.sub-section-panel.is-visible {
    display: block;
}

.sub-section-content {
    width: 100%;
}

.armes-text-panel {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 24px 28px;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.armes-text-panel p,
.armes-text-panel ul {
    color: rgba(255, 255, 255, 0.95);
    font-size: 1rem;
    line-height: 1.65;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.armes-text-panel p {
    margin: 0 0 12px;
}

.armes-text-panel p:last-child {
    margin-bottom: 0;
}

.armes-text-panel ul {
    margin: 0 0 16px 1.25rem;
    padding: 0;
}

.armes-text-panel li {
    margin-bottom: 4px;
}

.armes-text-panel a {
    color: rgba(255, 255, 255, 0.95);
    text-decoration: underline;
}

.armes-text-panel a:hover {
    color: white;
}

.tableau-armes-offensives,
.tableau-armes-defensives {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    border: 2px solid rgba(255, 255, 255, 0.15);
    margin-top: 8px;
}

.tableau-armes-offensives th,
.tableau-armes-offensives td,
.tableau-armes-defensives th,
.tableau-armes-defensives td {
    padding: 12px 14px;
    text-align: left;
    color: rgba(255, 255, 255, 0.95);
    font-size: 0.9rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    vertical-align: top;
}

.tableau-armes-offensives thead,
.tableau-armes-defensives thead {
    position: sticky;
    top: 0;
    z-index: 2;
}

.tableau-armes-offensives thead th,
.tableau-armes-defensives thead th {
    background: rgba(0, 0, 0, 0.6);
    font-weight: 600;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.12);
    white-space: normal;
    overflow-wrap: normal;
    word-break: normal;
    line-height: 1.35;
    vertical-align: bottom;
}

.tableau-armes-offensives thead th:first-child,
.tableau-armes-defensives thead th:first-child {
    border-top-left-radius: 12px;
}

.tableau-armes-offensives thead th:last-child,
.tableau-armes-defensives thead th:last-child {
    border-top-right-radius: 12px;
}

.tableau-armes-offensives tbody tr:last-child td:first-child,
.tableau-armes-defensives tbody tr:last-child td:first-child {
    border-bottom-left-radius: 12px;
}

.tableau-armes-offensives tbody tr:last-child td:last-child,
.tableau-armes-defensives tbody tr:last-child td:last-child {
    border-bottom-right-radius: 12px;
}

.tableau-armes-offensives tbody tr:hover td,
.tableau-armes-defensives tbody tr:hover td {
    background: rgba(255, 255, 255, 0.06);
}

.tableau-armes-offensives tbody tr:last-child td,
.tableau-armes-defensives tbody tr:last-child td {
    border-bottom: none;
}

.tableau-armes-offensives tbody td:last-child,
.tableau-armes-defensives tbody td:last-child {
    white-space: normal;
    overflow-wrap: break-word;
}

@media (max-width: 768px) {
    .armes-general-info {
        flex-direction: column;
    }

    .armes-image {
        flex: none;
        max-width: 100%;
        width: 100%;
    }

    .armes-description p {
        font-size: 1rem;
    }

    .armes-text-panel {
        padding: 18px 20px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .tableau-armes-offensives,
    .tableau-armes-defensives {
        width: max-content;
        min-width: 100%;
    }

    .tableau-armes-offensives th,
    .tableau-armes-offensives td,
    .tableau-armes-defensives th,
    .tableau-armes-defensives td {
        padding: 10px 12px;
        font-size: 0.85rem;
    }

    .tableau-armes-offensives tbody td:not(:last-child),
    .tableau-armes-defensives tbody td:not(:last-child) {
        white-space: nowrap;
    }
}
