/* ===== Background ===== */
body {
    background: url('../img/BG-SmartAuto-scaled.jpg') no-repeat center center fixed;
    background-size: cover;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ===== Layout ===== */
header {
    padding: 15px 0;
    text-align: center;
}

header img {
    max-height: 80px;
}

main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    width: 100%;
}

form {
    margin: 50px 0 100px 0;
}

footer {
    background: #222;
    color: #fff;
    padding: 40px 0;
}

footer a, footer p {
    color: #aaa;
    text-decoration: none;
}

footer a:hover {
    color: #fff;
}

/* ===== Survey Container ===== */
.survey-container {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 1rem;
    padding: 2rem;
    max-width: 900px;
    width: 100%;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    position: relative;
}

.survey-container-bkg {
    background: rgba(255, 255, 255, 1);
}

.progress {
    height: 10px;
    border-radius: 5px;
    margin-bottom: 25px;
}

.step {
    display: none;
}

.step.active {
    display: block;
    animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.btn-next,
.btn-prev {
    min-width: 120px;
}

.survey-title {
    text-align: center;
    margin-bottom: 20px;
}

.survey-title h2,
h2 {
    font-weight: 700;
    margin-bottom: 5px;
}

.survey-title p,
p {
    color: #393939;
    font-size: 1rem;
}

.radio-image-option {
  text-align: center;
}

.radio-image-label {
  display: inline-block;
  cursor: pointer;
  border: 2px solid transparent;
  border-radius: 12px;
  padding: 10px 15px;
  transition: all 0.3s ease;
}

.radio-image {
  width: 90px;
  height: auto;
  display: block;
  margin: 0 auto 8px;
  border-radius: 8px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.radio-text {
  font-weight: 500;
  color: #333;
}

/* Estado seleccionado */
.btn-check:checked + .radio-image-label {
  border-color: #0d6efd;
  background-color: rgba(13, 110, 253, 0.1);
}

.btn-check:checked + .radio-image-label .radio-image {
  transform: scale(1.08);
  box-shadow: 0 0 12px rgba(13, 110, 253, 0.4);
}

.checkbox-text-option {
  display: inline-block;
}

.checkbox-text-label {
  border: 1px solid #0d6efd;
  border-radius: 10px;
  padding: 10px 18px;
  cursor: pointer;
  transition: all 0.3s ease;
  background-color: #fff;
  font-weight: 500;
  color: #333;
  display: inline-block;
  min-width: 160px;
  text-align: left;
}

/* Estado seleccionado */
.btn-check:checked + .checkbox-text-label {
  border-color: #0d6efd;
  background-color: rgba(13, 110, 253, 0.1);
  box-shadow: 0 0 10px rgba(13, 110, 253, 0.2);
  color: #0d6efd;
}

/* Hover */
.checkbox-text-label:hover {
  border-color: #b0d0ff;
}

.input-error {
  border: 2px solid red !important;
  border-radius: 4px;
}

.error-message {
  color: red;
  font-size: 0.9em;
  margin-top: 4px;
}

.red{
    color: red;
    font-size: 1.1em;
    padding: 0 5px;
}
.loading{
  width:150px; 
  padding: 10em 0
}
.float-left{
  float: left;

}
.float-right{
  float: right;
}

.list {
    list-style-type: disc;
    padding-left: 20px;
    margin: 0;
    display: grid;
    gap: 10px 20px;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }

  @media (min-width: 1024px) {
    .list {
      grid-template-columns: repeat(4, 1fr);
    }
  }

  .list li {
    font-family: sans-serif;
    font-size: 14px;
    color: #333;
    break-inside: avoid;
  }

/* Brand Selector Grid */
.brand-selector {
    margin-bottom: 1rem;
}

.brand-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(85px, 1fr));
    gap: 10px;
}

.brand-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 8px;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.brand-item:hover {
    border-color: #0d6efd;
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.15);
    transform: translateY(-2px);
}

.brand-item.selected {
    border-color: #0d6efd;
    background-color: #e7f1ff;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
}

.brand-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
}

.brand-logo {
    max-width: 50px;
    max-height: 50px;
    width: 100%;
    height: auto;
    object-fit: contain;
    filter: grayscale(20%);
    transition: filter 0.2s ease;
}

.brand-item:hover .brand-logo,
.brand-item.selected .brand-logo {
    filter: grayscale(0%);
}

.brand-name {
    font-size: 0.7rem;
    font-weight: 600;
    color: #6c757d;
    text-align: center;
    line-height: 1.2;
    transition: color 0.2s ease;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.brand-item:hover .brand-name {
    color: #0d6efd;
}

.brand-item.selected .brand-name {
    color: #0d6efd;
    font-weight: 700;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .brand-grid {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
        gap: 8px;
    }
    
    .brand-item {
        padding: 10px 6px;
    }
    
    .brand-logo {
        max-width: 40px;
        max-height: 40px;
    }
    
    .brand-name {
        font-size: 0.65rem;
    }
}

@media (max-width: 480px) {
    .brand-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 6px;
    }
    
    .brand-logo {
        max-width: 35px;
        max-height: 35px;
    }
    
    .brand-name {
        font-size: 0.6rem;
    }
}

/* Date of Birth Inputs */
#q_birth_month,
#q_birth_day,
#q_birth_year {
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

#q_birth_month::placeholder,
#q_birth_day::placeholder,
#q_birth_year::placeholder {
    color: #adb5bd;
    font-weight: 400;
}

#q_birth_month:focus,
#q_birth_day:focus,
#q_birth_year:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.15);
}

/* Smaller labels */
#q_birth_month + label,
#q_birth_day + label,
#q_birth_year + label {
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

.extra_info {
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-top: 20px;
    border-left: 4px solid #007bff;
}

.info_icon {
    width: 24px;
    height: 24px;
    background: url('../img/question.svg') no-repeat center;
    margin-right: 15px;
    flex-shrink: 0;
}

.extra_text .title {
    font-weight: bold;
    margin: 0;
    font-size: 0.9rem;
    color: #333;
}

.extra_text .info {
    margin: 0;
    font-size: 0.85rem;
    color: #666;
}

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

.extra_info {
    animation: fadeIn 0.3s ease-out;
}
.border-white {
    border: 2px solid #fff;
}