/* ============================================
   Rusty Suite — main.css
   ============================================ */

*, *::before, *::after {
    box-sizing: border-box;
}

/* --- Base --- */
body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background-color: #1a1a2e;
    color: #f0f0f0;
    margin: 0;
    padding: 0;
    text-align: center;
    background-image: url('../img/backgrund8.webp');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    overflow-x: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* --- Header --- */
header {
    position: relative;
    background: rgba(15, 15, 30, 0.92);
    backdrop-filter: blur(8px);
    padding: 16px 20px;
    text-align: center;
    color: white;
    width: 100%;
    border-bottom: 1px solid rgba(0, 170, 255, 0.25);
    z-index: 100;
}

.logo-container {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
}

.logo {
    width: 46px;
    height: auto;
    border-radius: 8px;
}

header h1 {
    color: #00aaff;
    margin: 0 0 10px 0;
    font-size: 1.9em;
    letter-spacing: 1px;
}

/* --- Navigation --- */
nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    padding: 0;
    margin: 0;
    list-style: none;
    gap: 6px;
}

nav ul li a {
    display: block;
    padding: 6px 14px;
    color: #c8d8e8;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95em;
    border-radius: 6px;
    transition: background 0.2s, color 0.2s;
    letter-spacing: 0.3px;
}

nav ul li a:hover,
nav ul li a.active {
    background: rgba(0, 170, 255, 0.15);
    color: #00f2ff;
    text-decoration: none;
}

/* --- Hamburger (mobile) --- */
.nav-toggle {
    display: none;
}

.hamburger {
    display: none;
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 6px;
    z-index: 101;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: #00aaff;
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}

.nav-toggle:checked ~ .hamburger span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.nav-toggle:checked ~ .hamburger span:nth-child(2) {
    opacity: 0;
}
.nav-toggle:checked ~ .hamburger span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* --- Main content wrapper --- */
.page-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.content {
    position: relative;
    padding: 20px;
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

/* --- Sections --- */
section {
    margin: 36px auto;
    width: 88%;
    max-width: 860px;
    background: rgba(40, 40, 60, 0.88);
    backdrop-filter: blur(6px);
    padding: 28px 32px;
    border-radius: 14px;
    box-shadow: 0 0 20px rgba(0, 170, 255, 0.18), 0 4px 20px rgba(0,0,0,0.4);
    border: 1px solid rgba(0, 170, 255, 0.12);
    text-align: left;
}

section h2 {
    text-align: center;
    color: #00aaff;
    margin-top: 0;
}

section h3 {
    color: #00d4ff;
}

/* --- Hero --- */
.hero {
    text-align: center;
    padding: 40px 32px;
}

.hero h2 {
    font-size: 2em;
    margin-bottom: 12px;
}

.hero p {
    font-size: 1.05em;
    color: #c0d0e0;
    max-width: 600px;
    margin: 0 auto 24px auto;
    line-height: 1.7;
}

/* --- Feature grid --- */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 18px;
    margin-top: 20px;
}

.feature-item {
    background: rgba(0, 170, 255, 0.07);
    border: 1px solid rgba(0, 170, 255, 0.2);
    border-radius: 10px;
    padding: 20px;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
    text-align: center;
}

.feature-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 20px rgba(0, 170, 255, 0.25);
    border-color: rgba(0, 170, 255, 0.5);
}

.feature-item h3 {
    color: #00d4ff;
    margin-top: 0;
    font-size: 1.1em;
}

.feature-item p {
    color: #b0c0d0;
    font-size: 0.9em;
    margin: 0;
    line-height: 1.6;
}

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 10px 22px;
    background: linear-gradient(135deg, #0088cc, #0055aa);
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95em;
    border: 1px solid rgba(0, 170, 255, 0.4);
    transition: background 0.25s, box-shadow 0.25s, transform 0.15s;
    box-shadow: 0 0 10px rgba(0, 136, 204, 0.3);
    cursor: pointer;
}

.btn:hover {
    background: linear-gradient(135deg, #00aaff, #0077cc);
    box-shadow: 0 0 18px rgba(0, 170, 255, 0.55);
    transform: translateY(-2px);
    color: #fff;
    text-decoration: none;
}

/* --- Donate button --- */
.donbtn {
    display: inline-block;
    background: #041fb4;
    color: white;
    padding: 12px 24px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: bold;
    transition: 0.25s ease-in-out;
    border: 2px solid rgba(0, 183, 255, 0.5);
    box-shadow: 0 0 12px rgba(0, 119, 255, 0.6);
}

.donbtn:hover {
    box-shadow: 0 0 24px rgb(0, 174, 255);
    transform: translateY(-2px);
    color: white;
    text-decoration: none;
}

/* --- QR Code section --- */
#qr-code-section {
    background: linear-gradient(135deg, #2e2e2e, #292b35);
    padding: 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 0 18px rgba(1, 221, 250, 0.5);
    border: 2px solid rgba(5, 156, 226, 0.7);
}

#qr-code-section h3 {
    color: #fff;
    margin-bottom: 10px;
}

.qr-code-container {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 15px;
    box-shadow: 0 0 12px rgba(0, 204, 255, 0.6);
    border: 2px solid rgb(0, 217, 255);
    margin: 16px auto;
    transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

.qr-code-container:hover {
    transform: scale(1.06);
    box-shadow: 0 0 24px rgba(0, 255, 255, 0.9);
}

.qr-code {
    border-radius: 13px;
    width: 200px;
    height: auto;
    display: block;
}

/* --- Links --- */
a {
    color: #3a9fda;
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: #00aaff;
    text-decoration: underline;
}

/* --- Release cards --- */
#release-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
    margin-top: 14px;
}

.release-card {
    border: 1px solid rgba(0, 170, 255, 0.25);
    border-radius: 8px;
    padding: 14px;
    background: rgba(0, 170, 255, 0.05);
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.release-card:hover {
    border-color: rgba(0, 170, 255, 0.5);
    box-shadow: 0 0 10px rgba(0, 170, 255, 0.15);
}

.release-card h4 {
    margin: 0;
    font-size: 0.9em;
    color: #00d4ff;
}

.release-card p {
    margin: 0;
    font-size: 0.82em;
    color: #99b0c0;
    flex-grow: 1;
}

/* --- Contact form --- */
.contact-form {
    max-width: 520px;
    margin: 16px auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form select,
.contact-form textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid rgba(0, 170, 255, 0.3);
    border-radius: 8px;
    background-color: rgba(0, 0, 0, 0.35);
    color: #f0f0f0;
    font-size: 0.95em;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    border-color: #00aaff;
    box-shadow: 0 0 8px rgba(0, 170, 255, 0.3);
}

.contact-form select option {
    background: #222;
}

.contact-form textarea {
    min-height: 130px;
    resize: vertical;
}

.contact-form label {
    font-size: 0.85em;
    color: #99b0c0;
    margin-bottom: -8px;
}

.contact-form button {
    padding: 12px;
    background: linear-gradient(135deg, #0088cc, #0055aa);
    color: #fff;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1em;
    transition: background 0.25s, box-shadow 0.25s;
    box-shadow: 0 0 10px rgba(0, 136, 204, 0.3);
}

.contact-form button:hover {
    background: linear-gradient(135deg, #00aaff, #0077cc);
    box-shadow: 0 0 18px rgba(0, 170, 255, 0.5);
}

/* --- GitHub / code blocks --- */
#github-readme {
    text-justify: inter-word;
    text-align: justify;
    hyphens: auto;
}

pre {
    background-color: #1a1a2a;
    padding: 12px 16px;
    border: 1px solid rgba(0, 170, 255, 0.2);
    border-radius: 8px;
    overflow-x: auto;
}

code {
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 13px;
    color: #7dd4f0;
}

pre code {
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 13px;
    color: #7dd4f0;
}

.italic {
    font-style: italic;
    background-color: rgba(0, 170, 255, 0.1);
    border-radius: 4px;
    padding: 1px 5px;
    color: #a0d0f0;
}

#github-readme code {
    display: inline-block;
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 13px;
    color: #7dd4f0;
    background-color: rgba(0, 170, 255, 0.08);
    border-radius: 5px;
    padding: 2px 6px;
    white-space: pre-wrap;
}

/* --- Footer --- */
footer {
    background: rgba(12, 12, 24, 0.95);
    backdrop-filter: blur(8px);
    padding: 18px 20px;
    border-top: 1px solid rgba(0, 170, 255, 0.15);
    margin-top: auto;
    width: 100%;
}

footer p {
    margin: 4px 0;
    color: #667788;
    font-size: 0.88em;
}

footer a {
    color: #3a9fda;
}

/* --- Spacer (remplace .separateur) --- */
.separateur {
    height: 20px;
    width: 100%;
    visibility: hidden;
}

/* --- Layout helpers --- */
.container {
    max-width: 860px;
    margin: 0 auto;
    padding: 0 20px;
}

.container-full-width {
    width: 100%;
    padding: 0;
}

.left-transparent,
.right-transparent {
    display: none;
}

/* ============================================
   Responsive — tablette
   ============================================ */
@media (max-width: 860px) {
    section {
        width: 94%;
        padding: 22px 20px;
    }
}

/* ============================================
   Responsive — mobile
   ============================================ */
@media (max-width: 640px) {

    header {
        padding: 14px 56px 14px 14px; /* space for hamburger */
        text-align: left;
    }

    .logo-container {
        position: static;
        transform: none;
        display: inline-flex;
        vertical-align: middle;
        margin-right: 10px;
    }

    header h1 {
        display: inline;
        font-size: 1.3em;
        vertical-align: middle;
    }

    .hamburger {
        display: flex;
    }

    nav {
        width: 100%;
    }

    nav ul {
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: rgba(10, 10, 25, 0.97);
        border-top: 1px solid rgba(0, 170, 255, 0.2);
        padding: 8px 0;
        margin-top: 10px;
    }

    .nav-toggle:checked ~ nav ul {
        display: flex;
    }

    nav ul li a {
        padding: 12px 20px;
        border-radius: 0;
        font-size: 1em;
        border-bottom: 1px solid rgba(0, 170, 255, 0.07);
    }

    .hero h2 {
        font-size: 1.5em;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }

    section {
        width: 96%;
        padding: 20px 16px;
        margin: 20px auto;
    }

    #github-readme {
        text-align: left;
        word-break: break-word;
        overflow-wrap: break-word;
        hyphens: none;
    }

    #release-container {
        grid-template-columns: 1fr;
    }
}
