/* ── Vitres — Dark theme Empire ── */

/* Override body layout for vitres (no sidebar) */
.vitres-body {
    display: block;
}

/* ── Top Nav ── */
.vitres-nav {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    padding: 0 24px;
    display: flex;
    align-items: center;
    gap: 0;
    height: 54px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.vitres-nav-left {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-right: 24px;
}

.vitres-back {
    font-size: 13px;
    color: var(--text-muted);
    text-decoration: none;
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid var(--border);
    transition: all 0.15s;
}

.vitres-back:hover {
    color: var(--text);
    border-color: var(--accent);
    text-decoration: none;
}

.vitres-brand {
    font-weight: 700;
    font-size: 15px;
    color: var(--text);
    white-space: nowrap;
}

.vitres-nav-links {
    display: flex;
    gap: 2px;
    flex: 1;
}

.vitres-nav-links a {
    padding: 6px 14px;
    border-radius: var(--radius);
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.15s;
}

.vitres-nav-links a:hover {
    background: var(--bg-hover);
    color: var(--text);
    text-decoration: none;
}

.vitres-nav-links a.active {
    background: transparent;
    color: var(--accent-light);
    font-weight: 600;
    border-bottom: 2px solid var(--accent);
    border-radius: 0;
}

/* ── Main content ── */
.vitres-main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 24px 16px;
}

/* ── Page Header ── */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 24px;
}

.page-header h1 {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
}

.subtitle {
    color: var(--text-muted);
    font-size: 14px;
    margin-top: 2px;
}

.retour {
    font-size: 13px;
    color: var(--text-muted);
    display: block;
    margin-bottom: 4px;
    text-decoration: none;
}

.retour:hover { color: var(--accent-light); }

.header-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

/* ── Cards ── */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 16px;
}

.card h2 {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 14px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ── Grids ── */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

/* ── Progression ── */
.progression-card {
    margin-bottom: 16px;
    border-top: 3px solid var(--accent);
}

.progression-header {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 10px;
}

.revenu { font-size: 28px; font-weight: 700; color: var(--text); }
.objectif { color: var(--text-muted); font-size: 16px; }
.pourcentage { margin-left: auto; font-size: 20px; font-weight: 600; color: var(--accent-light); }

.barre-container {
    background: var(--border);
    border-radius: 100px;
    height: 8px;
    overflow: hidden;
}

.barre {
    background: linear-gradient(90deg, var(--accent), var(--accent-light));
    height: 100%;
    border-radius: 100px;
    transition: width 0.5s ease;
    min-width: 4px;
}

/* ── Lists ── */
.liste-simple { list-style: none; }

.liste-simple li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
}

.liste-simple li:last-child { border-bottom: none; }
.liste-simple a { color: var(--text); text-decoration: none; }
.liste-simple a:hover { color: var(--accent-light); }

.vide { color: var(--text-muted); font-size: 14px; }

/* ── Badges ── */
.badge {
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 100px;
    font-weight: 500;
}

.badge.vert { background: rgba(34,197,94,0.15); color: var(--green); }
.badge.rouge { background: rgba(239,68,68,0.15); color: var(--red); }
.badge.date { background: rgba(99,102,241,0.15); color: var(--accent-light); }

/* ── Table ── */
table { width: 100%; border-collapse: collapse; font-size: 14px; }

th {
    text-align: left;
    padding: 8px 12px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid var(--border);
}

td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--border);
    color: var(--text);
}

tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--bg-hover); }

td a { color: var(--accent-light); text-decoration: none; }
td a:hover { text-decoration: underline; }

/* ── Filtres ── */
.filtres {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    align-items: center;
}

.filtres input[type="text"],
.filtres select {
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 14px;
    background: var(--bg-card);
    color: var(--text);
}

/* ── Client Grid ── */
.clients-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 12px;
}

.client-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    display: block;
    transition: border-color 0.15s, box-shadow 0.15s;
    text-decoration: none;
}

.client-card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 12px rgba(99,102,241,0.15);
    transform: translateY(-1px);
}

.client-card.archived { opacity: 0.4; }

.client-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.client-nom { font-weight: 600; color: var(--text); }
.client-prix { font-weight: 600; color: var(--accent-light); font-size: 14px; }

.client-card-info {
    display: flex;
    gap: 8px;
    font-size: 13px;
    color: var(--text-muted);
    flex-wrap: wrap;
}

.client-card-date {
    margin-top: 8px;
    font-size: 12px;
    color: var(--text-muted);
}

/* ── Formulaires ── */
.form-client, .form-passage {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
}

input[type="text"],
input[type="number"],
input[type="date"],
select,
textarea {
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 14px;
    color: var(--text);
    background: var(--bg);
    font-family: inherit;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(99,102,241,0.15);
}

.checkbox-label {
    flex-direction: row;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text);
}

textarea { resize: vertical; }

.form-actions {
    display: flex;
    gap: 8px;
    padding-top: 4px;
}

/* ── Info list ── */
.info-list {
    display: grid;
    grid-template-columns: 130px 1fr;
    gap: 8px 16px;
    font-size: 14px;
}

dt { color: var(--text-muted); font-weight: 500; }
dd { color: var(--text); }

.notes-block {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    font-size: 14px;
}

.notes-block p { margin-top: 6px; color: var(--text); }

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.15s ease;
}

.btn:hover { background: var(--accent-light); color: white; text-decoration: none; }

.btn-primary { background: var(--accent); color: white; }
.btn-primary:hover { background: var(--accent-light); }

.btn-secondary {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    background: var(--bg-card);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.15s ease;
}

.btn-secondary:hover { background: var(--bg-hover); text-decoration: none; }

.btn-danger {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    background: var(--bg-card);
    color: var(--red);
    border: 1px solid rgba(239,68,68,0.3);
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
}

.btn-danger:hover { background: rgba(239,68,68,0.1); }

.btn-ghost {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    background: transparent;
    color: var(--text-muted);
    border: none;
    border-radius: var(--radius);
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
}

.btn-ghost:hover { background: var(--bg-hover); color: var(--text); text-decoration: none; }

.btn-small {
    padding: 3px 10px;
    background: var(--bg-card);
    color: var(--accent-light);
    border: 1px solid var(--accent);
    border-radius: 100px;
    font-size: 12px;
    cursor: pointer;
}

.btn-small:hover { background: rgba(99,102,241,0.1); }

/* ── RoadMap ── */
.roadmap-vitres {
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 8px 0;
}

.rm-item {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.rm-dot-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    flex-shrink: 0;
}

.rm-dot-big {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid var(--border);
    background: var(--bg);
    flex-shrink: 0;
    margin-top: 3px;
}

.rm-line-v {
    width: 2px;
    height: 100%;
    min-height: 20px;
    background: var(--border);
    margin-top: 4px;
}

.rm-item.rm-done .rm-dot-big {
    background: var(--green);
    border-color: var(--green);
}

.rm-item.rm-done .rm-line-v { background: var(--green); }

.rm-item.rm-active .rm-dot-big {
    background: var(--accent);
    border-color: var(--accent);
    box-shadow: 0 0 8px var(--accent);
}

.rm-content strong {
    font-size: 15px;
    color: var(--text);
    display: block;
    margin-bottom: 4px;
}

.rm-desc {
    font-size: 13px;
    color: var(--text-muted);
    margin: 0;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .grid-3, .grid-2 { grid-template-columns: 1fr; }
    .form-grid { grid-template-columns: 1fr; }
    .vitres-nav-links a { padding: 6px 8px; font-size: 13px; }
}
