/* 
 * ONPhI - Styles Unifiés pour les Pages
 * Système de design cohérent pour toutes les pages du site
 */

/* ===== SYSTÈME DE TITRES UNIFIÉ ===== */

/* Titre principal de page */
.onphi-page-title {
    margin-bottom: 0.5rem;
    font-size: 1.75rem;
    line-height: 1.2;
    color: #f56a6a;
    font-variant-caps: small-caps;
    font-weight: 600;
    text-align: center;
    margin-bottom: 1rem;
}

/* Sous-titre de page */
.onphi-page-subtitle {
    color: #7f888f;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    text-align: center;
    font-style: italic;
}

/* Responsive pour les titres */
@media (min-width: 992px) {
    .onphi-page-title {
        font-size: 2rem;
    }
    .onphi-page-subtitle {
        font-size: 1rem;
    }
}

/* ===== HEADER DE PAGE UNIFIÉ ===== */
.onphi-page-header {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 2rem 0;
    margin-bottom: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

.onphi-page-header .onphi-page-title {
    margin-bottom: 0.5rem;
}

.onphi-page-header .onphi-page-subtitle {
    margin-bottom: 0;
}

/* ===== SECTIONS DE CONTENU ===== */
.onphi-content-section {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    margin-bottom: 2rem;
    border-left: 4px solid #f56a6a;
}

.onphi-content-section h3 {
    color: #f56a6a;
    font-size: 1.3rem;
    margin-bottom: 1rem;
    font-weight: 600;
    border-bottom: 2px solid #f56a6a;
    padding-bottom: 0.5rem;
}

.onphi-content-section h4 {
    color: #495057;
    font-size: 1.1rem;
    margin-bottom: 0.8rem;
    font-weight: 600;
}

/* ===== CARTES D'INFORMATION ===== */
.onphi-info-card {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.onphi-info-card:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.onphi-info-card h4 {
    color: #f56a6a;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

/* ===== LISTES ET ÉLÉMENTS ===== */
.onphi-list {
    list-style: none;
    padding: 0;
}

.onphi-list li {
    padding: 0.8rem 0;
    border-bottom: 1px solid #e9ecef;
    transition: all 0.2s ease;
}

.onphi-list li:hover {
    background: #f8f9fa;
    padding-left: 1rem;
}

.onphi-list li:last-child {
    border-bottom: none;
}

.onphi-list li a {
    color: #495057;
    text-decoration: none;
    font-weight: 500;
}

.onphi-list li a:hover {
    color: #f56a6a;
    text-decoration: none;
}

/* ===== BOUTONS UNIFIÉS ===== */
.onphi-btn {
    background: #f56a6a !important;
    color: white !important;
    border: none !important;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 700 !important;
    text-decoration: none !important;
    display: inline-block;
    transition: all 0.3s ease;
    cursor: pointer;
}

.onphi-btn:hover {
    background: #e55a5a !important;
    color: white !important;
    text-decoration: none !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(245, 106, 106, 0.3);
}

.onphi-btn-outline {
    background: #f56a6a;
    color: white;
    border: 2px solid #f56a6a;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 700;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    cursor: pointer;
}

.onphi-btn-outline:hover {
    background: #f56a6a;
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
}

/* ===== FORMULAIRES UNIFIÉS ===== */
.onphi-form-group {
    margin-bottom: 1.5rem;
}

.onphi-form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #495057;
}

.onphi-form-control {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.onphi-form-control:focus {
    outline: none;
    border-color: #f56a6a;
    box-shadow: 0 0 0 3px rgba(245, 106, 106, 0.1);
}

/* ===== GRILLE RESPONSIVE ===== */
.onphi-grid {
    display: grid;
    gap: 2rem;
    margin-bottom: 2rem;
}

.onphi-grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.onphi-grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.onphi-grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* ===== ALERTES ET MESSAGES ===== */
.onphi-alert {
    padding: 1rem 1.5rem;
    border-radius: 6px;
    margin-bottom: 1.5rem;
    border-left: 4px solid;
    display: flex;
    align-items: center;
}

.onphi-alert i {
    margin-right: 0.75rem;
    font-size: 1.1rem;
}

.onphi-alert-info {
    background: #e3f2fd;
    border-color: #2196f3;
    color: #0d47a1;
}

.onphi-alert-success {
    background: #e8f5e8;
    border-color: #4caf50;
    color: #2e7d32;
}

.onphi-alert-warning {
    background: #fff3e0;
    border-color: #ff9800;
    color: #e65100;
}

/* ===== LISTES ===== */
.onphi-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.onphi-list-item {
    display: flex;
    align-items: flex-start;
    padding: 1rem;
    margin-bottom: 0.75rem;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.onphi-list-item:hover {
    background: #e9ecef;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.item-icon {
    margin-right: 1rem;
    color: #f56a6a;
    font-size: 1.2rem;
    margin-top: 0.25rem;
}

.item-content {
    flex: 1;
}

.item-content h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.item-content h4 a {
    color: #333;
    text-decoration: none;
    transition: color 0.2s ease;
}

.item-content h4 a:hover {
    color: #f56a6a;
    text-decoration: none;
}

.item-meta {
    margin: 0;
    color: #6c757d;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
}

.item-meta i {
    margin-right: 0.5rem;
    color: #f56a6a;
}

/* ===== BOUTONS OUTLINE ===== */
.onphi-btn-outline {
    display: inline-block;
    font-weight: 700;
    color: white;
    text-align: center;
    vertical-align: middle;
    cursor: pointer;
    user-select: none;
    background-color: #f56a6a;
    border: 1px solid #f56a6a;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    border-radius: 0.375rem;
    transition: all 0.15s ease-in-out;
    text-decoration: none;
}

.onphi-btn-outline:hover {
    color: #fff;
    background-color: #f56a6a;
    border-color: #f56a6a;
    text-decoration: none;
}

.onphi-btn-outline:focus {
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(245, 106, 106, 0.5);
}

.onphi-alert-error {
    background: #ffebee;
    border-color: #f44336;
    color: #c62828;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .onphi-page-header {
        padding: 1.5rem 1rem;
    }
    
    .onphi-content-section {
        padding: 1.5rem;
    }
    
    .onphi-grid {
        gap: 1rem;
    }
    
    .onphi-page-title {
        font-size: 1.5rem;
    }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.onphi-fade-in {
    animation: fadeInUp 0.6s ease-out;
}

/* ===== LOGO RESPONSIVE ET ALIGNEMENT ===== */

/* Logo principal - alignement avec le pavé radio */
#header .logo {
    font-family: "Roboto Slab", serif;
    color: #f56a6a;
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1.2;
    margin: 0;
    padding: 0;
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

/* Alignement du logo avec le pavé radio */
#header {
    padding-left: 15px;
    padding-right: 15px;
    margin-bottom: 8px;
}

/* Responsive pour le logo */
@media (max-width: 1680px) {
    #header .logo {
        font-size: 1.1em;
        line-height: 1.3;
    }
}

@media (max-width: 1280px) {
    #header .logo {
        font-size: 1em;
        line-height: 1.2;
    }
}

@media (max-width: 980px) {
    #header .logo {
        font-size: 0.9em;
        line-height: 1.1;
    }
}

@media (max-width: 736px) {
    #header .logo {
        font-size: 0.8em;
        line-height: 1.1;
        word-wrap: break-word;
        hyphens: auto;
    }
}

@media (max-width: 480px) {
    #header .logo {
        font-size: 0.75em;
        line-height: 1.1;
    }
}

/* Alignement parfait avec le pavé radio */
.radio-player-container {
    margin-left: 15px;
    margin-right: 15px;
}

/* Ajustement de la sidebar pour l'alignement */
#sidebar .inner {
    padding-left: 0;
    padding-right: 0;
}

/* Header dans la sidebar - alignement avec le pavé radio */
#sidebar #header {
    padding-left: 15px;
    padding-right: 15px;
    margin-bottom: 8px;
}

/* Logo dans la sidebar - alignement parfait */
#sidebar #header .logo {
    font-size: 0.9em;
    line-height: 1.2;
    margin: 0;
    padding: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    word-wrap: break-word;
    hyphens: auto;
}

/* Logo image dans la sidebar - alignement avec le pavé radio */
#sidebar .logo {
    padding-left: 15px;
    padding-right: 15px;
    margin-bottom: 8px;
}

#sidebar .logo img {
    width: 100%;
    max-width: 100%;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border: 2px solid #e9ecef;
    display: block;
    margin: 0 auto;
}

/* Responsive pour le logo dans la sidebar */
@media (max-width: 1680px) {
    #sidebar #header .logo {
        font-size: 0.85em;
    }
}

@media (max-width: 1280px) {
    #sidebar #header .logo {
        font-size: 0.8em;
    }
}

@media (max-width: 980px) {
    #sidebar #header .logo {
        font-size: 0.75em;
    }
}

@media (max-width: 736px) {
    #sidebar #header .logo {
        font-size: 0.7em;
    }
}

@media (max-width: 480px) {
    #sidebar #header .logo {
        font-size: 0.65em;
    }
}

/* Responsive pour l'image du logo dans la sidebar */
@media (max-width: 1680px) {
    #sidebar .logo img {
        max-width: 220px;
    }
}

@media (max-width: 1280px) {
    #sidebar .logo img {
        max-width: 200px;
    }
}

@media (max-width: 980px) {
    #sidebar .logo img {
        max-width: 180px;
    }
}

@media (max-width: 736px) {
    #sidebar .logo img {
        max-width: 160px;
    }
}

@media (max-width: 480px) {
    #sidebar .logo img {
        max-width: 140px;
    }
}

/* ===== CORRECTION DU MENU SIDEBAR ===== */

/* Correction de l'alignement du menu de la sidebar */
#sidebar .nav.flex-column {
    padding-left: 15px;
    padding-right: 15px;
    margin: 0;
    list-style: none;
}

#sidebar .nav-item {
    margin-bottom: 0.5rem;
    padding: 0;
    display: block !important;
}

#sidebar .nav-link {
    display: block;
    padding: 0.5rem 0.75rem;
    color: #3d4449;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s ease;
    font-weight: 500;
}

#sidebar .nav-link:hover {
    background-color: #f8f9fa;
    color: #f56a6a;
    text-decoration: none;
}

#sidebar .nav-link.active {
    background-color: #f56a6a;
    color: white;
}

/* Correction des dropdowns */
#sidebar .dropdown {
    position: relative;
    display: block !important;
}

#sidebar .dropdown-toggle {
    display: block;
    padding: 0.5rem 0.75rem;
    color: #3d4449;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s ease;
    font-weight: 500;
    cursor: pointer;
}

#sidebar .dropdown-toggle:hover {
    background-color: #f8f9fa;
    color: #f56a6a;
    text-decoration: none;
}

#sidebar .dropdown-menu {
    position: static;
    display: none;
    background-color: white;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-top: 0.25rem;
    padding: 0.5rem 0;
    list-style: none;
}

#sidebar .dropdown-menu.show {
    display: block;
}

#sidebar .dropdown-item {
    display: block;
    padding: 0.5rem 1rem;
    color: #3d4449;
    text-decoration: none;
    transition: all 0.2s ease;
}

#sidebar .dropdown-item:hover {
    background-color: #f8f9fa;
    color: #f56a6a;
    text-decoration: none;
}

/* Responsive pour le menu */
@media (max-width: 1680px) {
    #sidebar .nav.flex-column {
        padding-left: 12px;
        padding-right: 12px;
    }
}

@media (max-width: 1280px) {
    #sidebar .nav.flex-column {
        padding-left: 10px;
        padding-right: 10px;
    }
}

@media (max-width: 980px) {
    #sidebar .nav.flex-column {
        padding-left: 8px;
        padding-right: 8px;
    }
}

@media (max-width: 736px) {
    #sidebar .nav.flex-column {
        padding-left: 5px;
        padding-right: 5px;
    }
}

/* ===== UTILITAIRES ===== */
.onphi-text-center {
    text-align: center;
}

.onphi-text-muted {
    color: #6c757d;
}

.onphi-mb-0 {
    margin-bottom: 0;
}

.onphi-mb-1 {
    margin-bottom: 1rem;
}

.onphi-mb-2 {
    margin-bottom: 2rem;
}

.onphi-mt-0 {
    margin-top: 0;
}

.onphi-mt-1 {
    margin-top: 1rem;
}

.onphi-mt-2 {
    margin-top: 2rem;
}

/* ===== CARTES ÉCOLE ONPhI ===== */
.card.bg-light.border-0 {
    border: 1px solid #f56a6a !important;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(245, 106, 106, 0.1);
    transition: all 0.3s ease;
}

.card.bg-light.border-0:hover {
    border-color: #e55a5a !important;
    box-shadow: 0 4px 15px rgba(245, 106, 106, 0.2);
    transform: translateY(-2px);
}
