/* 3D UI & Glassmorphism Components */

/* Glass Panel / Card */
.glass-panel {
  background: var(--bg-glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: var(--glass-border);
  border-radius: 24px;
  padding: 2rem;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
}

/* 3D Card effect */
.card-3d {
  background: var(--bg-secondary);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: var(--shadow-3d);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-3d:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-soft);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: var(--accent-gradient);
  color: #fff;
  box-shadow: 0 4px 15px rgba(37, 99, 235, 0.4);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(37, 99, 235, 0.5);
  filter: brightness(1.1);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 2px solid var(--border-color);
  box-shadow: var(--shadow-soft);
}

.btn-secondary:hover {
  background: var(--border-color);
  transform: translateY(-2px);
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

/* Header & Nav */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: var(--nav-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: var(--glass-border);
  transition: background-color 0.3s ease;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

.brand {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-links a {
  color: var(--text-primary);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background: var(--accent-gradient);
  transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Theme Toggle Button */
.theme-toggle {
  background: var(--bg-secondary);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-3d);
  color: var(--text-primary);
  transition: all 0.3s ease;
}

.theme-toggle:hover {
  transform: scale(1.1);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

/* Mobile Menu Toggle */
.mobile-toggle {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text-primary);
}

.mobile-toggle svg {
  width: 24px;
  height: 24px;
}

/* Form Inputs & Sliders */
.input-group {
  margin-bottom: 1.5rem;
}

.input-label {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text-primary);
}

.input-field {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  color: var(--text-primary);
  font-size: 1rem;
  box-shadow: var(--shadow-3d-inset);
  transition: all 0.3s ease;
}

.input-field:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

/* 3D Range Slider */
input[type=range] {
  -webkit-appearance: none;
  width: 100%;
  background: transparent;
  height: 20px;
  margin-top: 10px;
}

input[type=range]:focus {
  outline: none;
}

input[type=range]::-webkit-slider-runnable-track {
  width: 100%;
  height: 8px;
  cursor: pointer;
  background: var(--bg-secondary);
  border-radius: 10px;
  box-shadow: var(--shadow-3d-inset);
}

input[type=range]::-webkit-slider-thumb {
  box-shadow: var(--shadow-3d);
  height: 24px;
  width: 24px;
  border-radius: 50%;
  background: var(--accent-color);
  cursor: pointer;
  -webkit-appearance: none;
  margin-top: -8px;
  transition: transform 0.1s ease;
}

input[type=range]::-webkit-slider-thumb:hover {
  transform: scale(1.1);
}

/* Toggle Switch (Months/Years) */
.toggle-switch {
  display: flex;
  background: var(--bg-secondary);
  border-radius: 50px;
  padding: 4px;
  box-shadow: var(--shadow-3d-inset);
  gap: 4px;
}

.toggle-switch button {
  flex: 1;
  padding: 6px 12px;
  border-radius: 40px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s ease;
}

.toggle-switch button.active {
  background: var(--accent-gradient);
  color: white;
  box-shadow: var(--shadow-soft);
}

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

/* Footer structure */
footer {
  background: var(--bg-secondary);
  border-top: var(--glass-border);
  padding: 60px 0 20px;
  margin-top: 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-col h4 {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.footer-col ul {
  list-style: none;
  padding: 0;
}

.footer-col ul li a {
  color: var(--text-secondary);
  transition: color 0.2s ease;
}

.footer-col ul li a:hover {
  color: var(--accent-color);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* Mobile responsive fixes */
@media (max-width: 1024px) {
  footer {
    margin-top: 35px;
    padding-top: 45px;
  }
}

@media (max-width: 991px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 80px;
    left: 0;
    width: 100%;
    background: var(--bg-glass);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    flex-direction: column;
    padding: 2rem 0;
    box-shadow: 0 10px 15px rgba(0,0,0,0.1);
  }
  .nav-links.active {
    display: flex;
  }
  .mobile-toggle {
    display: block;
  }
  .nav-actions {
    gap: 0.5rem;
  }
}

@media (max-width: 768px) {
  footer {
    margin-top: 30px;
    padding-top: 30px;
  }
  
  .brand {
    font-size: 1.15rem;
    gap: 8px;
    max-width: 100%;
  }

  .brand svg {
    width: 22px;
    height: 22px;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .hero-buttons .btn {
    width: 100%;
    max-width: 320px;
  }
}
