/* Reset y variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-primary: #111827;
    --color-gray-100: #f3f4f6;
    --color-gray-400: #9ca3af;
    --color-gray-500: #6b7280;
    --color-gray-800: #1f2937;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    line-height: 1.5;
    color: var(--color-primary);
}


main {
    flex: 1;
}

/* Header */
header {
    height: 3.5rem;
    padding: 0 1rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--color-gray-100);
}

nav {
    margin-left: auto;
    display: flex;
    gap: 1.5rem;
}

nav a {
    color: var(--color-primary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
}

nav a:hover {
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* Container y utilidades */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Hero section */
.hero {
    padding: 3rem 0;
    text-align: center;
}

.hero h1 {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.hero p {
    max-width: 700px;
    margin: 0 auto 2rem;
    color: var(--color-gray-500);
}

/* Botones */
.button-group {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
}

.button-primary {
    background-color: var(--color-primary);
    color: white;
}

.button-secondary {
    background-color: white;
    color: var(--color-primary);
    border: 1px solid var(--color-gray-100);
}

/* Hockey Map section */
.hockey-map {
    background-color: var(--color-gray-100);
    padding: 3rem 0;
}

.hockey-map h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2.5rem;
}

.feature-card {
    background: white;
    padding: 1.5rem;
    border-radius: 0.5rem;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.feature-icon {
    width: 3rem;
    height: 3rem;
    margin: 0 auto 1rem;
}

/* Project section */
.project {
    padding: 3rem 0;
}

.project h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.gallery-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 0.5rem;
}

/* Contact section */
.contact {
    background-color: var(--color-gray-100);
    padding: 3rem 0;
}

.contact h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.input, .textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--color-gray-100);
    border-radius: 0.375rem;
    font-size: 1rem;
}

.textarea {
    min-height: 100px;
    resize: vertical;
}

/* Footer */
footer {
    padding: 1.5rem;
    border-top: 1px solid var(--color-gray-100);
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: space-between;
    align-items: center;
}

footer p {
    font-size: 0.75rem;
    color: var(--color-gray-500);
}

footer nav {
    gap: 1rem;
}

footer nav a {
    font-size: 0.75rem;
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2rem;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
    }
    
    .button-group {
        flex-direction: column;
        align-items: stretch;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}

#map {
    height: 400px;
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin: 20px 0;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 0.5rem;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--color-gray-500);
    font-size: 0.875rem;
    font-weight: 500;
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
}

/* Admin Table Styles */
.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
}

thead tr {
    background-color: var(--color-gray-100);
}

th, td {
    text-align: left;
    padding: 1rem;
}

tbody tr {
    border-bottom: 1px solid var(--color-gray-100);
}

.admin-actions {
    justify-content: flex-start;
}

.admin-actions .button {
    margin-right: 0.5rem;
}

.button-delete {
    background-color: #dc2626;
    color: white;
}

/* Admin Section */
.admin-section {
    padding: 2rem 0;
}

.admin-section h1 {
    margin-bottom: 2rem;
}

.custom-marker {
    background: transparent;
    border: none;
}

.marker-pin {
    width: 30px;
    height: 30px;
    border-radius: 50% 50% 50% 0;
    background: #c30b82;
    position: absolute;
    transform: rotate(-45deg);
    left: 50%;
    top: 50%;
    margin: -15px 0 0 -15px;
}

.marker-pin::after {
    content: '';
    width: 24px;
    height: 24px;
    margin: 3px 0 0 3px;
    background: #fff;
    position: absolute;
    border-radius: 50%;
}

.club-popup {
    text-align: center;
    padding: 10px;
}

.club-popup .club-logo {
    max-width: 100px;
    max-height: 100px;
    margin-bottom: 10px;
}

.club-popup h3 {
    margin: 5px 0;
    color: #333;
}

.club-popup a {
    color: #c30b82;
    text-decoration: none;
}

.map-container {
    display: flex;
    gap: 2rem;
    align-items: stretch;
    margin-top: 2rem;
}

#map {
    flex: 2;
    min-height: 500px;
}

.stats-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 2rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.map-description {
    margin-bottom: 2rem;
    text-align: center;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Estilos mejorados para el formulario */
.contact-form {
    background: white;
    padding: 2rem;
    border-radius: 0.8rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.input {
    background-color: var(--color-gray-100);
    border: 2px solid transparent;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.input:focus {
    border-color: var(--color-primary);
    background-color: white;
    outline: none;
    box-shadow: 0 0 0 3px rgba(17, 24, 39, 0.1);
}

.file-input-wrapper {
    background-color: var(--color-gray-100);
    padding: 0.75rem;
    border-radius: 0.375rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.file-input-wrapper label {
    font-weight: 500;
    color: var(--color-gray-800);
}

#file-name {
    font-size: 0.875rem;
    color: var(--color-gray-500);
}

.button-primary {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    transition: transform 0.2s ease;
}

.button-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Mejoras para la sección de información de contacto */
.contact-info {
    padding: 2rem;
    background: white;
    border-radius: 0.8rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--color-primary);
}

.contact-info p {
    color: var(--color-gray-500);
    margin-bottom: 1.5rem;
}

.contact-info div {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
    color: var(--color-gray-800);
}

/* Estilos del formulario de registro de clubes */
.club-registration-form {
    background: white;
    padding: 2rem;
    border-radius: 0.8rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.club-registration {
    background-color: var(--color-gray-100);
    padding: 3rem 0;
}

.club-registration h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

.club-registration-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
}

/* Login styles */
.login-section {
    padding: 3rem 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 3.5rem - 4.5rem); /* Resta altura del header y footer */
}

.login-container {
    width: 100%;
    max-width: 400px;
}

.login-container h1 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--color-primary);
}

.login-form {
    width: 100%;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--color-gray-800);
}

.alert {
    padding: 1rem;
    border-radius: 0.375rem;
    margin-bottom: 1.5rem;
}

.alert-danger {
    background-color: #fee2e2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

/* Estilos para el formulario en grid */
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 500;
    color: var(--color-gray-800);
}

.full-width {
    grid-column: 1 / -1;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.current-logo {
    font-size: 0.875rem;
    color: var(--color-gray-500);
    margin-bottom: 0.5rem;
}

@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}
