/* --- Import --- */
@import "flashbag.css";

/* --- Variables --- */
:root {
    --primary-color: #1a2fa0;
    --primary-color-gradient: linear-gradient(
        to bottom,
        #1f3db8 0%,
        #1a2fa0 50%,
        #16277e 100%
    );
    --secondary-color-gradient: linear-gradient(
        to bottom,
        #ff4c43 0%,
        #ed2939 50%,
        #d61c28 100%
    );
    --secondary-color: #ed2939;
    --box-shadow: 1px 2px 3px rgba(0, 0, 0, 0.25);
    --text-color: white;
    --label-text-color: var(--primary-color);
}

/* --- Reset global --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    height: 100%;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* important pour footer collé en bas */
    font-family: Verdana, Geneva, Tahoma, sans-serif;
    line-height: 1.5;
    background-color: #f9f9f9;
    color: #333;
}
i,
a i {
    margin-right: 7px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
    cursor: pointer;
    transition: all ease 0.3s;
    font-size: 1.5rem;
    color: #ffff;
}
i:hover {
    transform: scale(1.2);
    padding: 5px;
}
/* --- Main content --- */
.main-content {
    display: flex;
    flex: 1; /* prend tout l’espace restant */
    flex-direction: column;
    width: 100%;
    margin-left: 0;
    padding: 1rem;
    transition: margin-left 0.3s ease;
    align-items: center;
}
.text-center {
    text-align: center;
}
/* --- Footer --- */
.footer {
    flex-shrink: 0; /* empêche le footer de rétrécir */
    background: var(--secondary-color-gradient);
    color: #fff;
    text-align: center;
    padding: 1rem;
}

/* --- Titres --- */
h1 {
    font-size: clamp(1.5rem, 5vw, 2.4rem);
    font-weight: 800;
    line-height: 1.2;
    margin-top: 10px;
    margin-bottom: 20px;
    background: var(--primary-color-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.15);
}
h1 i {
    margin-right: 10px;
    font-size: 2rem;
    text-shadow: none; 
}
h2 {
    margin: 10px auto;
    color: var(--primary-color);
}
.text-success,
.text-success i {
    color: green;
}

.btn-danger {
    background: var(--secondary-color-gradient);
}
.text-warning {
    color: #fff;
    padding: 10px;
    margin: 10px;
    border-radius: 10px;
    background: orangered;
}
.btn-warning {
    background-color: var(--secondary-color);
}
.btn-delete i {
    color: red;
}
/* --- Liens et paragraphes --- */
a {
    text-decoration: none;
    white-space: nowrap;
}
.text-red,
.text-red i {
    color: red;
}
.btn-open i,
.btn-open {
    color: var(--primary-color);
}
p {
    display: block;
    margin: 1em 0;
}

/* --- Boutons --- */
.btn,
button.btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    color: #fff;
    border: none;
    padding: 0.5rem 1rem;
    font-size: 16px;
    border-radius: 25px;
    cursor: pointer;
    margin: 10px;
    width: fit-content;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    transition: box-shadow 0.2s, transform 0.1s;
    min-height: 44px;
}
.btn-action {
    border: none;
    background: transparent;
    font-size: 1.2rem;
}
.btn-delete {
    color: red;
}
button:hover,
.btn:hover {
    opacity: 0.7;
}
.btn-primary {
    background: var(--primary-color-gradient);
}
.btn-primary:hover {
    background-color: #0056b3;
}

/* --- Flex helpers --- */
.row {
    display: flex;
    flex-direction: row;
}
.item-flex,
.flex-1,
.flex-2,
.flex-3 {
    display: flex;
}
.flex-1 {
    flex: 1 1 0;
}
.flex-2 {
    flex: 2 2 0;
}
.flex-3 {
    flex: 3 3 0;
}
.text-success,
.text-green {
    color: darkgreen;
}
/* --- Responsive --- */
@media (max-width: 768px) {
    .btn,
    button.btn {
        width: 99%;
        max-width: 300px;
    }
}

/* --- Animations --- */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}
.counter-pagination {
    margin: 10px;
    font-size: 1.2rem;
}
