:root {
    --color-primary: #101010;
    --color-secondary: #0C0C0C;
    --color-tertiary: #0F0F0F;
    --color-button: #27262C;
    --color-logo: #70F2B7;
    --color-text: #FFFFFF;
    --color-text-hover: #70F2B7;
    --color-subtitle: #B2B2BB;
    --color-lista: #407AFF;
    --color-white: #FFFFFF;
}

/* Estilos generales */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    min-height: 100%;
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background-image: linear-gradient(to right bottom,
        #111111,
        #1a182d,
        #221d49,
        #2a2167,
        #342485,
        #60218f,
        #871894,
        #ac0095,
        #d8007b,
        #f4005c,
        #ff413a,
        #ff6f00);
    display: flex;
    flex-direction: column;
    font-family: "Jost", sans-serif;
}

.main-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    width: 100%;
}

.wrapper {
    flex: 1;
    margin-bottom: 1rem;
}

main.main-content {
    flex: 1;
    padding-top: 60px;
}

/* Header */
.header-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    padding: 1rem;
    border-bottom: 1px solid #262B2E;
    background-color: var(--color-primary);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

/* Logo */
.logo-container {
    z-index: 2;
}

.logo {
    font-family: "Jost", sans-serif;
    font-weight: bold;
    font-size: 1.4rem;
    color: var(--color-logo);
    text-decoration: none;
}

/* Nav */
.main-nav {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 1rem;
    margin: 0;
    padding: 0;
}

.main-nav a {
    color: var(--color-text);
    text-decoration: none;
    font-size: 1.2rem;
}

.main-nav a:hover {
    color: var(--color-text-hover);
}

/* Banner */
.banner-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 20px 0;
}

/* Contenedor de entrada */
.input-container {
    max-width: 500px;
    margin: 0 auto;
    background-color: var(--color-secondary);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

/* Títulos */
.main-title {
    font-size: 3.5rem;
    font-family: "Jost", sans-serif;
    font-weight: 500;
    color: var(--color-white);
    margin-bottom: 15px;;
}

.section-title {
    font-family: "Jost", sans-serif;
    font-size: 1.6rem;
    font-weight: 400;
    color: var(--color-subtitle);
    margin: 10px 0;
    text-align: center;
}

/* Contenedores de entrada y botón */
.input-wrapper {
    display: flex;
    justify-content: center;
    width: 100%;
}

.input-name {
    width: 100%;
    padding: 10px 30px;
    border: 2px solid var(--color-text);
    border-radius: 25px 0 0 25px;
    font-size: 1.2rem;
    font-family: "Jost", sans-serif;
}

/* Estilos de botón */
button {
    padding: 10px 30px;
    font-family: "Jost", sans-serif;
    font-size: 1rem;
    border: 2px solid #000;
    border-radius: 25px;
    cursor: pointer;
}

/* Botón Añadir */
.button-add {
    background-color: var(--color-tertiary);
    color: var(--color-text);
    font-size: 1.2rem;
    border: 2px solid var(--color-text);
    border-radius: 0 25px 25px 0;
}

.button-add:hover {
    background-color: #191A1B;
}

/* Contenedor sortear */
.button-container {
    width: 300px;
    justify-content: center;
}

/* Botón sortear */
.button-draw {
    display: flex;
    align-items: center;
    width: 100%;
    padding: .53rem .95rem .53rem;
    color: var(--color-white);
    background: linear-gradient(150deg, #0031AA, #97003D);
    font-weight: 600;
    font-size: 1.2rem;
    transform: translateY(1.25rem);
    transition: all .2s cubic-bezier(.68,-.6,.32,1.6);
    box-shadow: inset 0 1px #ffffff0d;
    justify-content: center;
    border-radius: 40px;
}

.button-draw img {
    margin-right: 10px;
}

.button-draw:hover {
    box-shadow: inset 0 1px #ffffff0d, 0 10px 10px #0000001a;
    transform: translateY(1.25rem) scale(1.025);
}

/* Lista amigos */
ul#listaAmigos {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    margin: 0;
    padding: 0;
    justify-content: center;
    gap: 0.75rem;
}

li.nombre-amigo {
    margin: 0;
    padding: 0.5rem;
    border-radius: 10px;
    background-color: var(--color-button);
    color: var(--color-text);
    flex: 0 0 auto;
    text-align: center;
    font-size: 1rem;
    flex-basis: 150px;
    min-width: 120px;
    transition: background-color 0.3s ease;
    text-transform: uppercase;
}

/* Resultado */
.result-list {
    margin-top: 30px;
    font-size: 1.4rem;
    text-align: center;
    background: linear-gradient(145deg, #ffffff, #6a40e0, #ff6f00);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
}

.result-list b {
    text-transform: uppercase;
}

/* Footer */
footer {
    background-color: var(--color-primary);
    color: var(--color-text);
    padding: 1rem 0;
    text-align: center;
    font-size: 1rem;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.5);
    margin-top: 2rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.footer-container a {
    color: var(--color-logo);
    text-decoration: none;
}

/* Ventana modal */
.modal {
    display: none;
    position: fixed;
    z-index: 999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
}

.modal-container {
    background-color: var(--color-primary);
    color: var(--color-text);
    margin: 10% auto;
    padding: 20px;
    border-radius: 12px;
    width: 80%;
    max-width: 600px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    text-align: center;
    animation: aparecer 0.3s ease;
}

.cerrar {
    color: var(--color-logo);
    float: right;
    font-size: 2.3rem;
    font-weight: bold;
    cursor: pointer;
    margin-top: -15px;
}

.cerrar:hover {
    color: var(--color-text);
}

#mensaje-modal {
    font-size: 1.2rem;
    margin-top: 10px;
    color: var(--color-text);
}

/* Animación de entrada modal */
@keyframes aparecer {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* Media Queries */
@media (max-width: 600px) {
    .header-container {
        flex-direction: column;
        align-items: center;
    }

    .logo-container {
        width: 100%;
        display: flex;
        justify-content: center;
        margin-bottom: 10px;
    }

    .main-nav {
        position: static;
        transform: none;
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .main-nav ul {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    main.main-content {
        padding-top: 180px;
    }

    .input-container {
        margin-left: 1rem;
        margin-right: 1rem;
    }

    .modal-container {
        margin: 48% auto;
    }
}