/*! AVU CSS v1.4.1 | CC BY-NC-SA 4.0 Licence */

/* 
V 1.4.1 - AVU CSS - 03/12/2024
- Logo and Icons Update
    - Moved all icon in the new icon category.
    - Added a new "formal" icon.
    - Added a new "combat" icon.
- Added "center-links" class to center links.

V 1.4 - AVU CSS - 29/11/2024
- added Icons in the "topnav" category.
- added a new "guide" icon.
 */

/*
V 1.3/1.3.1 - AVU CSS - 28/11/2024
- adding new terminal headers
- modernizing the design

- added tables
- reorganizing the code
    - changing img others -> images
    - made slight changes
*/

/* Fonts ========================================================================== */

/* Porky is used for the page title */
@font-face {
    font-family: 'porky';
    src: url('/font/title/porky.ttf') format('ttf');
    font-weight: normal;
    font-style: normal;
}

/* Monaspace Krypton is used for titles. */
@font-face {
    font-family: 'MonaspaceKrypton-Regular';
    src: url('/font/title/MonaspaceKrypton-Regular.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}

/* Monaspace Argon is used for text. */
@font-face {
    font-family: 'MonaspaceArgon-Regular';
    src: url('/font/text/MonaspaceArgon-Regular.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}

/* Computer Modern is used for math (LaTeX). */
@font-face {
    font-family: 'ComputerModern';
    src: url('/font/math/cmunbi.ttf') format('woff');
    font-weight: bold;
    font-style: normal;
}

/* Pages ========================================================================== */

body {
    font-family: 'Courier New', monospace;
    background-color: #000000;
    color: #00ff00;
    margin: 0;
    padding: 0;
}

footer {
    font-size: 12px;
    text-align: center;
}

/* Titles ========================================================================== */

h1 {
    font-family: 'MonaspaceKrypton-Regular', monospace;
    font-size: 20px;
    text-align: center;
    color: #00ff00;
    margin-bottom: 20px;
}

h2 {
    font-family: 'MonaspaceKrypton-Regular', monospace;
    font-size: 24px;
    text-align: center;
    color: #00ff00;
    margin-bottom: 20px;
}

h3 {
    font-family: 'MonaspaceKrypton-Regular', monospace;
    font-size: 18px;
    text-align: center;
    color: #00ff00;
    margin-bottom: 20px;
}

h4 {
    font-family: 'MonaspaceKrypton-Regular', monospace;
    font-size: 16px;
    /* text-align: center; */
    color: #00ff00;
    margin-bottom: 20px;
}

p {
    font-family: 'MonaspaceArgon-Regular', monospace;
    font-size: 16px;
    text-align: center;
    line-height: 1.6;
    margin-bottom: 20px;
}

q {
    font-family: 'MonaspaceArgon-Regular', monospace;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 20px;
    text-align: center;
    /* Changez cette ligne pour aligner le texte à gauche */
}

/* Text Styling ========================================================================== */

.logs {
    white-space: pre-line;
}

.bold-text {
    font-weight: bold;
}

.italic-text {
    font-style: italic;
}

.underline-text {
    text-decoration: underline;
}

.strike-text {
    text-decoration: line-through;
}

.small-text {
    font-size: 14px;
}

.exposent {
    vertical-align: super;
    font-size: 0.5em;
}

.left {
    text-align: left;
}

.centered {
    text-align: center;
}

.justify {
    text-align: justify;
}

.reset-margin-bottom {
    margin-bottom: 0;
}

/* containers ========================================================================== */

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

/* images ========================================================================== */

img {
    max-width: 100%;
}

img.displayed {
    display: block;
    margin-left: auto;
    margin-right: auto;
    max-width: 100%;
    height: auto;
    cursor: not-allowed;
    text-align: center;
}

img.logo {
    height: 50px;
    vertical-align: middle;
}

/* Terminal ========================================================================== */

.terminal {
    background-color: #000000;
    padding: 10px;
    border: 1px solid #00ff00;
    border-radius: 4px;
    overflow: auto;
    max-height: max-content;
}

.terminal-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
}

.terminal-buttons {
    display: flex;
}

.terminal-button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 5px;
}

.terminal-button-red {
    background-color: #ff5f56;
    position: relative;
}


.terminal-button-red::before {
    content: '✕';
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 12px;
    /* Ajustez la taille de la croix selon vos besoins */
}

.terminal-button-yellow {
    background-color: #ffbd2e;
    position: relative;
}

.terminal-button-yellow::before {
    content: '—';
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 12px;
    /* Ajustez la taille du tiret selon vos besoins */
}

.terminal-button-green {
    background-color: #27c93f;
    position: relative;
}

.terminal-button-green::before {
    content: '•';
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 12px;
    /* Ajustez la taille du carré selon vos besoins */
}

.terminal-title {
    color: #00550e;
    font-weight: bold;
}

.terminal-body {
    color: #00FF00;
}

.terminal-prompt {
    color: #ffbd2e;
}

.darkgreen {
    color: #27c93f;
}

/* These one are completely custom and for each characters */

.bright_teal {
    color: #00FFAA;
}

.terminal pre {
    margin: 0;
    padding: 0;
    color: #00ff00;
}

/* topnav ========================================================================== */

.topnav {
    background-color: #000000;
    overflow: hidden;
    text-align: center;
    position: absolute;
}

.topnav a,
.topnav img {
    display: inline-block;
    color: #00ff00;
    text-align: center;
    padding: 14px 16px;
    text-decoration: none;
    font-size: 17px;
    vertical-align: middle;
}

.topnav a:hover {
    background-color: #202020;
    color: black;
}

.topnav a.active {
    background-color: #00ff00;
    color: white;
}

.topnav a.unusual {
    background-color: #050505;
    color: white;
}

/* Nav ========================================================================== */

nav .main-title {
    font-family: 'MonaspaceKrypton-Regular', monospace;
    font-size: 25px;
    color: #00ff00;
    text-align: left;
    /* Changer center en left */
    margin: 0;
}

nav .sub-title {
    font-family: 'MonaspaceKrypton-Regular', monospace;
    font-size: 18px;
    color: #00ff00;
    text-align: left;
    /* Changer center en left */
    margin: 0;
}

nav .category {
    font-family: 'MonaspaceKrypton-Regular', monospace;
    font-size: 18px;
    color: #00ff00;
    text-align: left;
    /* Changer center en left */
    margin: 0;
}

nav ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    color: #00FF00;
    background-color: #000000;
    text-align: left;
    /* Changer center en left */
}

nav li {
    display: inline;
}

/* Icons ========================================================================== */

.return {
    height: 20px;
    content: url('/assets/icon/goBack.png');
}

.home {
    height: 20px;
    vertical-align: middle;
    content: url('/assets/img/home.png');
}

.avu-logo {
    height: 70px;
    vertical-align: middle;
    content: url('/assets/icon/AVU_logo.png');
}

.guide {
    height: 20px;
    vertical-align: middle;
    content: url('/assets/icon/guide.png');
}

.chat {
    height: 20px;
    vertical-align: middle;
    content: url('/assets/icon/chat.png');
}

.avu-logo {
    height: 40px;
    vertical-align: middle;
    content: url('/assets/icon/AVU_logo.png');
}

.lobby {
    height: 20px;
    vertical-align: middle;
    content: url('/assets/icon/lobby.png');
}

.formal {
    height: 20px;
    vertical-align: middle;
    content: url('/assets/icon/formal.png');
}

.combat {
    height: 20px;
    vertical-align: middle;
    content: url('/assets/icon/combat.png');
}

.notepad {
    height: 20px;
    vertical-align: middle;
    content: url('/assets/icon/notepad.png');
}

.windows {
    height: 20px;
    vertical-align: middle;
    content: url('/assets/icon/win.png');
}

/* Table ========================================================================== */

table {
    font-family: arial, sans-serif;
    border-collapse: collapse;
    width: 100%;
}

td,
th {
    border: 1px solid #000000;
    text-align: left;
    padding: 8px;
}

/* Version mobile */
@media screen and (max-width: 600px) {
    table {
        width: 100%;
        border: 0;
    }

    table thead {
        display: none;
    }

    table tr {
        display: block;
        margin-bottom: 10px;
    }

    table td {
        display: block;
        text-align: right;
        border-bottom: 1px solid #ddd;
        position: relative;
        padding-left: 50%;
    }

    table td::before {
        content: attr(data-label);
        position: absolute;
        left: 0;
        width: 50%;
        padding-left: 10px;
        font-weight: bold;
        text-align: left;
    }

    .container {
        padding: 10px;
        width: 100%;
        box-sizing: border-box;
        overflow-x: hidden;
    }

    body {
        overflow-x: hidden;
        width: 100%;
    }
}

.table-title {
    font-family: 'MonaspaceKrypton-Regular', monospace;
    font-size: 20px;
    color: #00ff00;
    margin: 0%;
}

/* colours ========================================================================== */

.red {
    color: red;
}

.orange {
    color: orange;
}

.yellow {
    color: yellow;
}

.green {
    color: lime;
}

.darkgreen {
    color: darkgreen;
}

.blue {
    color: blue;
}

.indigo {
    color: indigo;
}

.violet {
    color: violet;
}

.gray {
    color: gray;
}

.white {
    color: white;
}

/* Github markdown note ========================================================================== */

.alert {
    padding: 6px;
    /* margin-bottom: 15px; */
    border: 1px solid transparent;
    border-radius: 4px;
}

.alert.warning {
    background-color: #000000;
    color: #a01d1d;
    border-color: #ff0000;
}

.warning {
    color: red;
}

.alert.info {
    background-color: #004d5a;
    color: #ffffff;
    border-color: #bee5eb;
}

.alert.success {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.alert.error {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

/* Button ========================================================================== */

.button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #000000;
    color: #00ff40;
    text-decoration: dotted;
    border-radius: 4px;
    transition: background-color 0.3s;
    border: 1px solid #00ff00;
    cursor: pointer;
    font-family: 'Courier New', monospace;
    font-size: 16px;
}

.button:hover {
    background-color: #202020;
    color: #ffffff;
}

.center-button {
    display: block;
    margin: 0 auto;
    text-align: center;
}

/* Form ========================================================================== */

form {
    margin-top: 40px;
}

.hack-input {
    padding: 8px 12px;
    font-size: 16px;
    background-color: #000000;
    color: #00ff00;
    border: 1px solid #00ff00;
    border-radius: 4px;
    margin-bottom: 20px;
    width: 100%;
}

input[type="submit"] {
    display: inline-block;
    padding: 10px 20px;
    background-color: #00ff00;
    color: #000000;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s;
    border: none;
    cursor: pointer;
    font-family: 'Courier New', monospace;
    font-size: 16px;
    animation: neon 1s infinite;
}

input[type="submit"]:hover {
    background-color: #ff00ff;
    color: #ffffff;
}

/* Combat document ========================================================================== */

.life-display {
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    background-color: #000000;
    color: #00ff40;
    text-decoration: dotted;
    border-radius: 4px;
    transition: background-color 0.3s;
    border: 0.1px solid #424242;
    cursor: pointer;
    font-family: 'Courier New', monospace;
    font-size: 16px;
}

.math {
    font-family: 'ComputerModern', monospace;
    font-size: 16px;
    background-color: #050505;
    color: #00ff00;
}

/* Animations ========================================================================== */

@keyframes glitch {
    0% {
        transform: translate(2px, 2px);
        text-shadow: -1px -1px #ff00ff;
    }

    25% {
        transform: translate(-2px, -2px);
        text-shadow: 2px -1px #00ffff;
    }

    50% {
        transform: translate(2px, -2px);
        text-shadow: 1px 1px #ff00ff;
    }

    75% {
        transform: translate(-2px, 2px);
        text-shadow: -2px 1px #00ffff;
    }

    100% {
        transform: translate(2px, 2px);
        text-shadow: -1px -1px #ff00ff;
    }
}

@keyframes neon {
    0% {
        box-shadow: 0 0 10px #00ff00, 0 0 20px #00ff00, 0 0 30px #00ff00, 0 0 40px #00ff00, 0 0 70px #00ff00, 0 0 80px #00ff00, 0 0 100px #00ff00, 0 0 150px #00ff00;
    }

    50% {
        box-shadow: 0 0 5px #00ff00, 0 0 10px #00ff00, 0 0 15px #00ff00, 0 0 20px #00ff00, 0 0 35px #00ff00, 0 0 40px #00ff00, 0 0 50px #00ff00, 0 0 75px #00ff00;
    }

    100% {
        box-shadow: 0 0 10px #00ff00, 0 0 20px #00ff00, 0 0 30px #00ff00, 0 0 40px #00ff00, 0 0 70px #00ff00, 0 0 80px #00ff00, 0 0 100px #00ff00, 0 0 150px #00ff00;
    }
}

/* Others ========================================================================== */

label {
    display: block;
    font-size: 18px;
    margin-bottom: 10px;
}

.divider {
    border-top: 1px solid #00ff00;
    margin: 20px 0;
}

.art-divider {
    border-top: 1px solid #00ff00;
    margin: 20px 0;
    width: 50%;
    margin: 0 auto;
}

.img-divider {
    display: block;
    margin-left: auto;
    margin-right: auto;
    max-width: 100%;
    height: auto;
    cursor: not-allowed;
    text-align: center;
    content: url('/assets/img/coolBanner.png');
}

.center-links {
    display: flex;
    justify-content: center;
    gap: 10px;
    /* Espace entre les liens */
}

/* Summary ========================================================================== */

.summary {
    padding: 10px;
    font-family: 'MonaspaceArgon-Regular', monospace;
}

.summary ul {
    list-style: none;
    padding-left: 20px;
}

.summary ul ul {
    margin-top: 5px;
    margin-bottom: 10px;
}

.summary li {
    margin-bottom: 10px;
    position: relative;
}

.summary li::before {
    content: ">";
    color: #00ff00;
    position: absolute;
    left: -15px;
}

.summary a {
    color: #00ff00;
    text-decoration: none;
    transition: color 0.3s;
}

.summary a:hover {
    color: #ff00ff;
    text-shadow: 0 0 5px #ff00ff;
}

/* Characters ========================================================================== */

.characters-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
}

.character-card {
    background-color: #000000;
    border: 1px solid #00ff00;
    border-radius: 4px;
    padding: 20px;
    text-align: center;
}

.character-card img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

.character-card h2 {
    font-size: 18px;
    margin: 10px 0;
}

.character-card p {
    font-size: 14px;
    margin: 10px 0;
}

.character-card button {
    padding: 10px 20px;
    background-color: #00ff00;
    color: #000000;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.character-card button:hover {
    background-color: #202020;
    color: #ffffff;
}

/* Audio Player ========================================================================== */


/* Lecteur Audio */
audio {
    /* Disposition */
    display: block;
    width: 100%;
    max-width: 400px;
    margin: 20px auto;
}

/* Style des contrôles pour Chrome/Safari */
audio::-webkit-media-controls-panel {
    background-color: #000000;
    border: 1px solid #00ff00;
    border-radius: 4px;
}

audio::-webkit-media-controls-play-button,
audio::-webkit-media-controls-mute-button {
    background-color: #00ff00;
    border-radius: 50%;
}

audio::-webkit-media-controls-timeline {
    background-color: #001000;
}

audio::-webkit-media-controls-current-time-display,
audio::-webkit-media-controls-time-remaining-display {
    color: #00ff00;
}

audio::-webkit-slider-thumb {
    background-color: #00ff00;
}

/* Animation de brillance */

audio:active,
audio:focus {
    outline: none;
}

/* Settings ========================================================================== */

/* Settings Page Styles for TFR Wiki */

.settings-page {
    --setting-border-color: rgba(0, 255, 0, 0.3);
    --terminal-bg: #0a0a0a;
}

.settings-section {
    border: 1px solid var(--setting-border-color);
    border-radius: 4px;
    margin-bottom: 2rem;
    padding: 1rem;
    background-color: rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.settings-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, transparent, var(--setting-border-color), transparent);
    opacity: 0.8;
    z-index: 1;
    animation: glitch-line 4s infinite;
}

@keyframes glitch-line {
    0%, 100% { transform: translateX(-100%); }
    50% { transform: translateX(100%); }
}

.settings-section h2 {
    color: #00ff00;
    font-family: 'MonaspaceKrypton-Regular', monospace;
    margin-top: 0;
    border-bottom: 1px solid var(--setting-border-color);
    padding-bottom: 0.5rem;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px dashed rgba(0, 255, 0, 0.2);
}

.setting-item:last-child {
    border-bottom: none;
}

.setting-info {
    flex: 1;
}

.setting-info h3 {
    margin-top: 0;
    margin-bottom: 0.5rem;
    font-family: 'MonaspaceKrypton-Regular', monospace;
    color: #ffffff;
}

.setting-info p {
    margin-top: 0;
    font-size: 0.9rem;
    opacity: 0.8;
}

.setting-control {
    margin-left: 1rem;
    min-width: 150px;
    text-align: right;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 30px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #222;
    transition: .4s;
    border-radius: 30px;
    border: 1px solid var(--setting-border-color);
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 4px;
    bottom: 3px;
    background-color: #fff;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background-color: #00aa00;
}

input:checked + .toggle-slider:before {
    transform: translateX(30px);
}

/* Buttons */
.danger-btn {
    --primary: #aa0000;
    --shadow-primary: #500000;
}

.danger-btn:hover {
    --primary: #ff0000;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: var(--terminal-bg);
    padding: 20px;
    border: 1px solid var(--setting-border-color);
    width: 90%;
    max-width: 500px;
    box-shadow: 0 0 15px rgba(0, 255, 0, 0.3);
    animation: modal-glitch 0.3s ease;
}

@keyframes modal-glitch {
    0% { transform: translate(-3px, 0); }
    25% { transform: translate(3px, 0); }
    50% { transform: translate(-3px, 0); }
    75% { transform: translate(3px, 0); }
    100% { transform: translate(0, 0); }
}

.modal-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

/* Notification */
#notificationContainer {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.notification {
    background-color: var(--terminal-bg);
    border: 1px solid var(--setting-border-color);
    color: #fff;
    padding: 15px 20px;
    margin-bottom: 10px;
    border-radius: 4px;
    box-shadow: 0 0 10px rgba(0, 255, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 250px;
    animation: notification-slide-in 0.3s ease, glitch 5s infinite;
}

.notification.success {
    border-color: #00aa00;
}

.notification.error {
    border-color: #aa0000;
}

@keyframes notification-slide-in {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes notification-slide-out {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(100%); opacity: 0; }
}

/* Responsive */
@media screen and (max-width: 600px) {
    .setting-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .setting-control {
        margin-left: 0;
        margin-top: 1rem;
        width: 100%;
    }
    
    .modal-content {
        width: 95%;
    }
    
    .modal-buttons {
        flex-direction: column;
    }
    
    .modal-buttons button {
        margin-bottom: 10px;
    }
}