/* ==============================
   Custom Theme Styles - Cáceres & Asociados
   Sistema de Cuadro Comparativo de Seguros
   ============================== */

/*===============================
  Paleta de Colores del Proyecto
================================*/
/*
Colores principales:
- #FFFFFF - Blanco
- #003448 - Azul Oscuro (Header)
- #B5191E - Rojo Principal (Botones, Bordes)
- #DCE5E8 - Gris Azulado Claro (Contenedores)
- #E31D24 - Rojo Vibrante
- #E95745 - Rojo Coral
- #F39D86 - Naranja Claro
- #EBEDED - Gris Muy Claro
- #0F3346 - Azul Muy Oscuro
- #193244 - Azul Oscuro Secundario
- #D13631 - Rojo Oscuro
- #000000 - Negro
- #EEF0F1 - Gris Claro
- #F6F6F6 - Gris Muy Claro
- #D9D9D9 - Gris Medio
- #ECEEEE - Gris Claro (Background)
- #FFFFFF69 - Blanco Transparente
- #02364a - Azul Oscuro (Texto)
- #efefef - Gris Claro (Inputs)
*/

/*===============================
  Variables CSS
================================*/
:root {
  /* Backgrounds */
  --background-page: #ECEEEE;
  --background-container: #DCE5E8;
  --background-header: #003448;
  --background-input: #efefef;
  --background-card: #DCE5E8;
  
  /* Text Colors */
  --text-primary: #02364a;
  --text-secondary: #193244;
  --text-white: #FFFFFF;
  
  /* Brand Colors */
  --brand-red: #B5191E;
  --brand-red-dark: #D13631;
  --brand-blue: #003448;
  
  /* Borders */
  --border-primary: #B5191E;
  --border-input: #b5181e;
  
  /* Buttons */
  --button-primary-bg: #b5181e;
  --button-primary-text: #ffffff;
  
  /* Fonts */
  --font-family-main: "Gotham", "Gotham Black", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/*===============================
  Global Styles
================================*/
* {
  box-sizing: border-box;
}

body {
  background-color: var(--background-page);
  color: var(--text-primary);
  font-family: var(--font-family-main);
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/*===============================
  Typography
================================*/
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-main);
  font-weight: 700;
  color: var(--text-primary);
}

/*===============================
  Containers
================================*/
.container-custom {
  background-color: var(--background-container);
  padding: 2rem;
  border-radius: 1.5rem;
  border: 3px solid var(--border-primary);
}

/*===============================
  Buttons
================================*/
.btn-primary {
  background-color: var(--button-primary-bg);
  color: var(--button-primary-text);
  border: none;
  padding: 0.75rem 2rem;
  border-radius: 0.5rem;
  cursor: pointer;
  font-family: var(--font-family-main);
  font-weight: 600;
  transition: opacity 0.3s ease;
}

.btn-primary:hover {
  opacity: 0.9;
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-secondary {
  background-color: var(--background-container);
  color: var(--text-primary);
  border: 2px solid var(--border-primary);
  padding: 0.75rem 2rem;
  border-radius: 0.5rem;
  cursor: pointer;
  font-family: var(--font-family-main);
  font-weight: 600;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background-color: var(--border-primary);
  color: var(--text-white);
}

/*===============================
  Inputs
================================*/
.input-custom {
  background-color: var(--background-input);
  color: var(--text-primary);
  border: none;
  border-bottom: 2px solid var(--border-input);
  padding: 0.75rem 1rem;
  border-radius: 0.5rem 0.5rem 0 0;
  font-family: var(--font-family-main);
  outline: none;
  width: 100%;
  transition: border-color 0.3s ease;
}

.input-custom:focus {
  border-bottom-color: var(--brand-red-dark);
  border-bottom-width: 3px;
}

.input-custom::placeholder {
  color: rgba(2, 54, 74, 0.5);
}

select.input-custom {
  cursor: pointer;
}

/*===============================
  Cards
================================*/
.card-custom {
  background-color: var(--background-card);
  border: 3px solid var(--border-primary);
  border-radius: 1.5rem;
  padding: 1rem;
  transition: all 0.3s ease;
}

.card-custom:hover {
  box-shadow: 0 10px 30px rgba(181, 25, 30, 0.2);
  transform: translateY(-2px);
}

.card-clickable {
  cursor: pointer;
}

/*===============================
  Header
================================*/
.header-custom {
  background-color: var(--background-header);
  height: 118px;
  border-radius: 0 0 56px 56px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/*===============================
  Tables
================================*/
.table-custom {
  width: 100%;
  border-collapse: collapse;
}

.table-custom thead {
  background-color: var(--background-input);
}

.table-custom th {
  padding: 1rem;
  text-align: left;
  font-weight: 700;
  color: var(--text-primary);
  border-bottom: 2px solid var(--border-primary);
}

.table-custom td {
  padding: 1rem;
  border-bottom: 1px solid #e0e0e0;
}

.table-custom tbody tr:nth-child(even) {
  background-color: #f6f6f6;
}

.table-custom tbody tr:nth-child(odd) {
  background-color: #ffffff;
}

/*===============================
  Decorative Elements
================================*/
.decorative-bars {
  position: fixed;
  pointer-events: none;
  opacity: 0.3;
  z-index: 0;
}

.decorative-bars-left {
  bottom: 0;
  left: 0;
}

.decorative-bars-right {
  top: 120px;
  right: 0;
}

/*===============================
  Utility Classes
================================*/
.text-primary {
  color: var(--text-primary);
}

.text-white {
  color: var(--text-white);
}

.bg-primary {
  background-color: var(--brand-red);
}

.bg-container {
  background-color: var(--background-container);
}

.border-primary {
  border-color: var(--border-primary);
}

.rounded-custom {
  border-radius: 1.5rem;
}

/*===============================
  Animations
================================*/
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.5s ease-out;
}

/*===============================
  Responsive Design
================================*/
@media (max-width: 768px) {
  .header-custom {
    height: 80px;
    border-radius: 0 0 30px 30px;
  }
  
  .container-custom {
    padding: 1rem;
  }
  
  .card-custom {
    padding: 1rem;
  }
}

/*===============================
  Login Page Styles
================================*/
.login-container {
  background-color: #ECEEEE;
}

.login-wrapper {
  position: relative;
  z-index: 10;
}

.login-card {
  background-color: #DCE5E8;
  border: 2px solid #B5191E;
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.login-title {
  font-weight: bold;
  text-align: center;
  color: #02364a;
  font-family: 'Gotham Black', sans-serif;
}

.password-recovery {
  text-align: center;
}

.decorative-top {
  position: absolute;
  pointer-events: none;
  z-index: 0;
}

.decorative-bottom {
  position: absolute;
  pointer-events: none;
  z-index: 0;
  transform: rotate(180deg);
}

.bottom-logo {
  position: absolute;
  width: 100%;
  display: flex;
  justify-content: center;
  z-index: 10;
}

.logo-img {
  opacity: 0.9;
}

/* Mobile - 320px */
@media (min-width: 320px) {
  .login-wrapper {
    width: 100%;
    padding: 1rem;
  }

  .login-card {
    padding: 1.5rem;
  }

  .login-title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
  }

  .password-recovery {
    margin-top: 1.5rem;
    margin-bottom: 5rem;
    font-size: 0.875rem;
  }

  .decorative-top {
    display: none;
  }

  .decorative-bottom {
    display: none;
  }

  .bottom-logo {
    bottom: 1rem;
  }

  .logo-img {
    height: 3rem;
  }
}

/* Tablet - 768px */
@media (min-width: 768px) {
  .login-wrapper {
    max-width: 32rem;
    padding: 2rem;
  }

  .login-card {
    padding: 2rem;
  }

  .login-title {
    font-size: 1.75rem;
    margin-bottom: 1.75rem;
  }

  .password-recovery {
    margin-top: 1.75rem;
    margin-bottom: 5.5rem;
    font-size: 1rem;
  }

  .decorative-top {
    display: block;
    top: 1rem;
    right: 1rem;
  }

  .decorative-top img {
    width: 8rem;
    height: auto;
  }

  .decorative-bottom {
    display: block;
    bottom: 1rem;
    left: 1rem;
  }

  .decorative-bottom img {
    width: 8rem;
    height: auto;
  }

  .bottom-logo {
    bottom: 1.5rem;
  }

  .logo-img {
    height: 4rem;
  }
}

/* Laptop - 1024px */
@media (min-width: 1024px) {
  .login-wrapper {
    max-width: 36rem;
  }

  .login-card {
    padding: 2.5rem;
  }

  .login-title {
    font-size: 2rem;
    margin-bottom: 2rem;
  }

  .password-recovery {
    margin-top: 2rem;
    margin-bottom: 6rem;
    font-size: 1.125rem;
  }

  .decorative-top {
    top: 1.5rem;
    right: 1.5rem;
  }

  .decorative-top img {
    width: 9rem;
  }

  .decorative-bottom {
    bottom: 1.5rem;
    left: 1.5rem;
  }

  .decorative-bottom img {
    width: 9rem;
  }

  .bottom-logo {
    bottom: 2rem;
  }

  .logo-img {
    height: 4.5rem;
  }
}

/* Desktop - 1280px */
@media (min-width: 1280px) {
  .login-wrapper {
    max-width: 42rem;
  }

  .login-card {
    padding: 3rem;
  }

  .login-title {
    font-size: 2rem;
  }

  .password-recovery {
    margin-top: 2rem;
    margin-bottom: 6.5rem;
    font-size: 1.125rem;
  }

  .decorative-top {
    top: 2rem;
    right: 2rem;
  }

  .decorative-top img {
    width: 10rem;
  }

  .decorative-bottom {
    bottom: 2rem;
    left: 2rem;
  }

  .decorative-bottom img {
    width: 10rem;
  }

  .logo-img {
    height: 5rem;
  }
}

/* Pantallas grandes - 1536px */
@media (min-width: 1536px) {
  .login-card {
    padding: 3.5rem;
  }

  .password-recovery {
    margin-bottom: 7rem;
  }

  .decorative-top {
    top: 2.5rem;
    right: 2.5rem;
  }

  .decorative-top img {
    width: 11rem;
  }

  .decorative-bottom {
    bottom: 2.5rem;
    left: 2.5rem;
  }

  .decorative-bottom img {
    width: 11rem;
  }

  .logo-img {
    height: 5.5rem;
  }
}
