﻿/* Estilos globales SGI Chile */
:root {
  --sgi-blue: #0b59a5;
  --sidebar-bg: #0b0b0b;
  --accent: #05b3f0;
}

/* Puedes ir moviendo acá lo que antes estaba en <style> de base.html */
body {
  background: #f7f7fb;
}

/* Ejemplo: cosas del sidebar/header que teníamos inline */
.header-shadow {
  box-shadow: 0 2px 8px rgba(11,89,165,0.08);
}
.overlay {
  background: rgba(0,0,0,0.35);
}
.sidebar a {
  color: #cbd5e1;
}
.sidebar a:hover {
  color: white;
}
.sidebar-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(255,255,255,0.06);
  border-radius: 999px;
  width: 36px;
  height: 36px;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  border: 1px solid rgba(255,255,255,0.15);
}

.sgi-input,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="date"],
select,
textarea {
  width: 100%;
  border: 1px solid #cbd5e1 !important;  /* <-- borde SIEMPRE visible */
  background: #ffffff !important;
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 0.95rem;
  outline: none;
  box-shadow: none;
}

/* cuando está enfocado */
.sgi-input:focus,
input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
select:focus,
textarea:focus {
  border-color: #0b59a5 !important; /* sgi-blue */
  box-shadow: 0 0 0 3px rgba(11, 89, 165, 0.18) !important;
}

/* placeholder más suave */
input::placeholder,
textarea::placeholder {
  color: #94a3b8;
}

/* si algún input viene con borde 0 por un estilo previo */
input, select, textarea {
  border-width: 1px !important;
}

html, body {
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
}

@media (max-width: 767px) {
  .container {
    max-width: 100%;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }

  #mainHeader {
    min-height: 84px;
  }

  #mainHeader .container {
    min-height: 84px;
    padding-top: 0.75rem !important;
    padding-bottom: 0.75rem !important;
  }

  #sidebar {
    width: 84vw;
    max-width: 320px;
  }

  #notificationsMenu,
  #avatarMenu {
    width: min(92vw, 320px);
    right: 0;
  }

  main.container {
    padding-top: 104px !important;
  }

  footer {
    padding-bottom: 90px;
  }

  .home-page .rounded-3xl,
  .kofu-page .rounded-3xl,
  .fortuna-page .rounded-3xl,
  .members-page .rounded-3xl,
  .daimoku-page .rounded-3xl {
    border-radius: 24px;
  }

  .section-header-mobile {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .section-header-mobile > a {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .mobile-scroll-reset {
    max-height: none !important;
    overflow: visible !important;
  }

  .mobile-scroll-inner {
    overflow: visible !important;
    max-height: none !important;
    padding-right: 0 !important;
  }

  .mobile-action-card {
    padding: 18px 18px !important;
    border-radius: 22px !important;
    gap: 14px !important;
  }

  .mobile-action-card span {
    line-height: 1.35;
  }

  .mobile-info-panel {
    padding: 20px !important;
  }

  .mobile-cover-image {
    height: auto !important;
    max-height: 420px !important;
    object-fit: contain !important;
  }

  .members-mobile-card,
  .rank-mobile-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 22px;
    padding: 16px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.03);
  }

  .members-mobile-grid,
  .rank-mobile-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .mobile-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #64748b;
    font-weight: 700;
    margin-bottom: 2px;
  }

  .mobile-value {
    font-size: 14px;
    color: #0f172a;
  }

  .mobile-pill {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    color: #334155;
  }

  .mobile-actions-stack {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .mobile-actions-stack > * {
    width: 100%;
  }

  .mobile-title-compact {
    font-size: 1.75rem !important;
    line-height: 1.15 !important;
  }

  .mobile-subtitle-compact {
    font-size: 0.95rem !important;
    line-height: 1.45 !important;
  }

  .mobile-two-cols {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 767px) {
  body {
    background: #f5f7fb;
  }

  #mainHeader {
    min-height: 78px;
  }

  #mainHeader .container {
    min-height: 78px;
    padding-top: 0.75rem !important;
    padding-bottom: 0.75rem !important;
  }

  main.container {
    padding-top: 96px !important;
    padding-left: 0.9rem !important;
    padding-right: 0.9rem !important;
    padding-bottom: 1.25rem !important;
  }

  footer {
    padding-top: 1rem;
    padding-bottom: 5.5rem;
  }

  .home-page {
    gap: 1rem !important;
  }

  .home-page .rounded-3xl,
  .kofu-page .rounded-3xl,
  .fortuna-page .rounded-3xl,
  .members-page .rounded-3xl,
  .daimoku-page .rounded-3xl {
    border-radius: 22px !important;
  }

  .home-page h2 {
    line-height: 1.15;
  }

  .home-page .section-header-mobile h2,
  .home-page .section-header-mobile h3 {
    font-size: 1.05rem !important;
  }

  .home-page .section-header-mobile > a {
    min-height: 46px;
    border-radius: 999px;
    font-weight: 700;
  }

  .home-page .text-xl {
    font-size: 1.1rem !important;
  }

  .home-page .text-lg {
    font-size: 1rem !important;
  }

  .home-page .p-6 {
    padding: 1rem !important;
  }

  .home-page .p-5 {
    padding: 1rem !important;
  }

  .home-page .p-4 {
    padding: 0.9rem !important;
  }

  .home-page .mt-8 {
    margin-top: 1rem !important;
  }

  .home-page .space-y-6 > * + * {
    margin-top: 1rem !important;
  }

  .home-page .space-y-3 > * + * {
    margin-top: 0.75rem !important;
  }

  #carousel {
    aspect-ratio: 4 / 3;
    border-radius: 20px !important;
  }

  #carousel .carousel-item {
    height: 100% !important;
  }

  .home-page .inline-flex.rounded-full {
    white-space: nowrap;
  }

  .home-page .news-card {
    border-radius: 20px;
  }

  .home-page .news-card img {
    height: 180px;
  }

  .home-page .text-sm {
    line-height: 1.45;
  }

  .home-page .text-xs {
    line-height: 1.35;
  }

  .home-page .mobile-scroll-inner {
    overflow: visible !important;
    max-height: none !important;
    padding-right: 0 !important;
  }
}

@media (max-width: 767px) {
  .my-group-hero-fix {
    margin-top: -135px !important;
  }

  .my-group-hero-title {
    font-size: 1.9rem !important;
    line-height: 1.02 !important;
  }

  .my-group-hero-subtitle {
    font-size: 0.95rem !important;
  }

  .my-group-hero-title,
  .my-group-hero-subtitle {
    text-shadow: 0 3px 14px rgba(0,0,0,0.72) !important;
  }
  .my-group-hero-overlay {
  background: linear-gradient(
    to bottom,
    rgba(15, 23, 42, 0.28) 0%,
    rgba(15, 23, 42, 0.45) 48%,
    rgba(15, 23, 42, 0.82) 100%
  ) !important;
}

.my-group-hero-subtitle {
  margin-top: 6px !important;
  opacity: 0.95;
}

.my-group-hero-title {
  margin-bottom: 2px !important;
}
}

@media (max-width: 767px) {
  .my-group-hero-fix {
    margin-top: -135px !important;
  }

  .my-group-hero-title {
    font-size: 1.9rem !important;
    line-height: 1.02 !important;
    color: #ffffff !important;
    text-shadow: 0 3px 14px rgba(0,0,0,0.72) !important;
    margin-bottom: 2px !important;
  }

  .my-group-hero-subtitle {
    font-size: 0.95rem !important;
    color: rgba(255,255,255,0.92) !important;
    text-shadow: 0 3px 14px rgba(0,0,0,0.72) !important;
    margin-top: 6px !important;
    opacity: 0.95;
  }

  .my-group-hero-overlay {
    background: linear-gradient(
      to bottom,
      rgba(15, 23, 42, 0.28) 0%,
      rgba(15, 23, 42, 0.45) 48%,
      rgba(15, 23, 42, 0.82) 100%
    ) !important;
  }
}