/* Reset and Base Styles */
.time-converter-container * {
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif !important;
}

.time-converter-container {
  width: 100% !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
  padding: 1rem !important;
  color: #333 !important;
  background-color: #b771c3 !important;
  border-radius: 12px !important;
  transition: all 0.3s ease !important;
}

@media (min-width: 576px) {
  .time-converter-container {
    padding: 1.5rem !important;
  }
}

@media (min-width: 768px) {
  .time-converter-container {
    padding: 2rem !important;
  }
}

.time-converter-container.dark-mode {
  background-color: #121826 !important;
  color: #e6e6e6 !important;
}

/* Converter Card Styles */
.converter-card {
  background-color: #ffffff !important;
  border-radius: 16px !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05) !important;
  padding: 1.25rem !important;
  margin-bottom: 1.5rem !important;
  transition: all 0.3s ease !important;
  width: 100% !important;
}

@media (min-width: 576px) {
  .converter-card {
    padding: 1.5rem !important;
    margin-bottom: 2rem !important;
  }
}

@media (min-width: 768px) {
  .converter-card {
    padding: 2rem !important;
  }
}

.dark-mode .converter-card {
  background-color: #1e293b !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2) !important;
}

.converter-header {
  display: flex !important;
  flex-direction: column !important;
  gap: 1rem !important;
  margin-bottom: 1.25rem !important;
  align-items: flex-start !important;
}

@media (min-width: 576px) {
  .converter-header {
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-bottom: 1.5rem !important;
  }
}

.converter-header h2 {
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  color: #7c3aed !important;
  margin: 0 !important;
  line-height: 1.2 !important;
}

@media (min-width: 576px) {
  .converter-header h2 {
    font-size: 1.8rem !important;
  }
}

.dark-mode .converter-header h2 {
  color: #a78bfa !important;
}

/* Theme Toggle Switch */
.theme-toggle {
  display: flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
}

.switch {
  position: relative !important;
  display: inline-block !important;
  width: 50px !important;
  height: 24px !important;
}

.switch input {
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
}

.slider {
  position: absolute !important;
  cursor: pointer !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  background-color: #ccc !important;
  transition: .4s !important;
}

.slider:before {
  position: absolute !important;
  content: "" !important;
  height: 16px !important;
  width: 16px !important;
  left: 4px !important;
  bottom: 4px !important;
  background-color: white !important;
  transition: .4s !important;
}

input:checked + .slider {
  background-color: #7c3aed !important;
}

input:checked + .slider:before {
  transform: translateX(26px) !important;
}

.slider.round {
  border-radius: 34px !important;
}

.slider.round:before {
  border-radius: 50% !important;
}

/* Time Display */
.time-display {
  background: linear-gradient(135deg, #8b5cf6, #6366f1) !important;
  border-radius: 12px !important;
  padding: 1.25rem 1rem !important;
  margin-bottom: 1.5rem !important;
  text-align: center !important;
  color: white !important;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3) !important;
}

@media (min-width: 576px) {
  .time-display {
    padding: 1.5rem !important;
    margin-bottom: 2rem !important;
  }
}

.current-time {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 0.5rem !important;
}

#current-time {
  font-size: 1.8rem !important;
  font-weight: 700 !important;
  letter-spacing: 1px !important;
}

@media (min-width: 576px) {
  #current-time {
    font-size: 2.5rem !important;
  }
}

#current-date {
  font-size: 0.9rem !important;
  opacity: 0.9 !important;
}

@media (min-width: 576px) {
  #current-date {
    font-size: 1.1rem !important;
  }
}

/* Converter Body */
.converter-body {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 1.25rem !important;
  margin-bottom: 1.5rem !important;
}

@media (min-width: 768px) {
  .converter-body {
    grid-template-columns: 1fr auto 1fr !important;
    gap: 1rem !important;
    margin-bottom: 2rem !important;
    align-items: center !important;
  }
}

.time-input-container {
  display: flex !important;
  flex-direction: column !important;
  gap: 1.25rem !important;
}

.time-input, .timezone-select, .time-result {
  display: flex !important;
  flex-direction: column !important;
  gap: 0.5rem !important;
}

.time-input label, .timezone-select label, .time-result label {
  font-size: 0.9rem !important;
  font-weight: 600 !important;
  color: #64748b !important;
}

.dark-mode .time-input label, 
.dark-mode .timezone-select label, 
.dark-mode .time-result label {
  color: #94a3b8 !important;
}

.time-input input, .timezone-select select {
  padding: 0.75rem 1rem !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 8px !important;
  font-size: 1rem !important;
  background-color: #f8fafc !important;
  color: #334155 !important;
  transition: all 0.2s ease !important;
  width: 100% !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
}

.timezone-select select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 0.75rem center !important;
  background-size: 1rem !important;
  padding-right: 2.5rem !important;
}

.dark-mode .time-input input, 
.dark-mode .timezone-select select {
  background-color: #1e293b !important;
  border-color: #334155 !important;
  color: #e2e8f0 !important;
}

.dark-mode .timezone-select select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") !important;
}

.time-input input:focus, .timezone-select select:focus {
  outline: none !important;
  border-color: #8b5cf6 !important;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2) !important;
}

.converted-time-display {
  font-size: 1.25rem !important;
  font-weight: 700 !important;
  color: #7c3aed !important;
  background-color: #f5f3ff !important;
  padding: 0.75rem 1rem !important;
  border-radius: 8px !important;
  text-align: center !important;
}

@media (min-width: 576px) {
  .converted-time-display {
    font-size: 1.5rem !important;
  }
}

.dark-mode .converted-time-display {
  background-color: #2e1065 !important;
  color: #c4b5fd !important;
}

/* Swap Button */
.swap-button {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
}

@media (max-width: 767px) {
  .swap-button {
    transform: rotate(90deg) !important;
  }
}

#swap-timezones {
  background-color: #f1f5f9 !important;
  border: none !important;
  border-radius: 50% !important;
  width: 40px !important;
  height: 40px !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  cursor: pointer !important;
  color: #7c3aed !important;
  transition: all 0.2s ease !important;
}

.dark-mode #swap-timezones {
  background-color: #334155 !important;
  color: #a78bfa !important;
}

#swap-timezones:hover {
  background-color: #e2e8f0 !important;
  transform: scale(1.05) !important;
}

.dark-mode #swap-timezones:hover {
  background-color: #475569 !important;
}

/* Converter Footer */
.converter-footer {
  border-top: 1px solid #e2e8f0 !important;
  padding-top: 1.25rem !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 1rem !important;
}

@media (min-width: 576px) {
  .converter-footer {
    padding-top: 1.5rem !important;
  }
}

.dark-mode .converter-footer {
  border-color: #334155 !important;
}

.time-difference {
  font-size: 1rem !important;
  font-weight: 600 !important;
}

@media (min-width: 576px) {
  .time-difference {
    font-size: 1.1rem !important;
  }
}

#time-difference {
  color: #7c3aed !important;
}

.dark-mode #time-difference {
  color: #a78bfa !important;
}

.date-info {
  display: flex !important;
  flex-direction: column !important;
  gap: 0.5rem !important;
}

@media (min-width: 576px) {
  .date-info {
    flex-direction: row !important;
    gap: 2rem !important;
  }
}

.date-container {
  font-size: 0.9rem !important;
}

@media (min-width: 576px) {
  .date-container {
    font-size: 0.95rem !important;
  }
}

#source-date, #target-date {
  font-weight: 600 !important;
  color: #7c3aed !important;
}

.dark-mode #source-date, 
.dark-mode #target-date {
  color: #a78bfa !important;
}

/* Additional Features */
.additional-features {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 1.25rem !important;
  margin-bottom: 1.5rem !important;
}

@media (min-width: 576px) {
  .additional-features {
    gap: 1.5rem !important;
    margin-bottom: 2rem !important;
  }
}

@media (min-width: 768px) {
  .additional-features {
    grid-template-columns: 1fr 1fr !important;
  }
}

.feature-card {
  background-color: #ffffff !important;
  border-radius: 12px !important;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05) !important;
  padding: 1.25rem !important;
  transition: all 0.3s ease !important;
}

@media (min-width: 576px) {
  .feature-card {
    padding: 1.5rem !important;
  }
}

.dark-mode .feature-card {
  background-color: #1e293b !important;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2) !important;
}

.feature-card h3 {
  font-size: 1.2rem !important;
  font-weight: 700 !important;
  color: #7c3aed !important;
  margin-bottom: 1rem !important;
}

@media (min-width: 576px) {
  .feature-card h3 {
    font-size: 1.3rem !important;
  }
}

.dark-mode .feature-card h3 {
  color: #a78bfa !important;
}

/* Quick Reference */
.quick-reference {
  display: flex !important;
  flex-direction: column !important;
  gap: 0.75rem !important;
}

.reference-item {
  display: grid !important;
  grid-template-columns: 1fr auto 1fr !important;
  align-items: center !important;
  padding: 0.75rem !important;
  background-color: #f8fafc !important;
  border-radius: 8px !important;
  transition: all 0.2s ease !important;
  gap: 0.5rem !important;
}

.dark-mode .reference-item {
  background-color: #1e293b !important;
}

.reference-item:hover {
  background-color: #f5f3ff !important;
}

.dark-mode .reference-item:hover {
  background-color: #2e1065 !important;
}

.reference-time {
  font-weight: 600 !important;
  color: #334155 !important;
  font-size: 0.9rem !important;
  text-align: center !important;
}

@media (min-width: 576px) {
  .reference-time {
    font-size: 1rem !important;
  }
}

.dark-mode .reference-time {
  color: #e2e8f0 !important;
}

.reference-equals {
  color: #64748b !important;
  font-weight: 700 !important;
}

.dark-mode .reference-equals {
  color: #94a3b8 !important;
}

/* World Clock */
.world-clock {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)) !important;
  gap: 0.75rem !important;
}

@media (min-width: 576px) {
  .world-clock {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)) !important;
    gap: 1rem !important;
  }
}

.world-clock-item {
  background-color: #f8fafc !important;
  border-radius: 8px !important;
  padding: 0.75rem !important;
  text-align: center !important;
  transition: all 0.2s ease !important;
}

.dark-mode .world-clock-item {
  background-color: #1e293b !important;
}

.world-clock-item:hover {
  background-color: #f5f3ff !important;
  transform: translateY(-2px) !important;
}

.dark-mode .world-clock-item:hover {
  background-color: #2e1065 !important;
}

.world-clock-city {
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  color: #64748b !important;
  margin-bottom: 0.5rem !important;
}

@media (min-width: 576px) {
  .world-clock-city {
    font-size: 0.85rem !important;
  }
}

.dark-mode .world-clock-city {
  color: #94a3b8 !important;
}

.world-clock-time {
  font-size: 1rem !important;
  font-weight: 700 !important;
  color: #334155 !important;
}

@media (min-width: 576px) {
  .world-clock-time {
    font-size: 1.1rem !important;
  }
}

.dark-mode .world-clock-time {
  color: #e2e8f0 !important;
}

/* Supportive Content */
.supportive-content {
  background-color: #ffffff !important;
  border-radius: 16px !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05) !important;
  padding: 1.25rem !important;
  transition: all 0.3s ease !important;
}

@media (min-width: 576px) {
  .supportive-content {
    padding: 1.5rem !important;
  }
}

@media (min-width: 768px) {
  .supportive-content {
    padding: 2rem !important;
  }
}

.dark-mode .supportive-content {
  background-color: #1e293b !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2) !important;
}

.supportive-content h2 {
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  color: #7c3aed !important;
  margin-bottom: 1.25rem !important;
  text-align: center !important;
  line-height: 1.3 !important;
}

@media (min-width: 576px) {
  .supportive-content h2 {
    font-size: 1.8rem !important;
  }
}

.dark-mode .supportive-content h2 {
  color: #a78bfa !important;
}

.content-card {
  margin-bottom: 1.5rem !important;
  padding-bottom: 1.5rem !important;
  border-bottom: 1px solid #e2e8f0 !important;
}

@media (min-width: 576px) {
  .content-card {
    margin-bottom: 2rem !important;
    padding-bottom: 2rem !important;
  }
}

.dark-mode .content-card {
  border-color: #334155 !important;
}

.content-card:last-child {
  border-bottom: none !important;
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}

.content-card h3 {
  font-size: 1.25rem !important;
  font-weight: 700 !important;
  color: #7c3aed !important;
  margin-bottom: 0.75rem !important;
  line-height: 1.3 !important;
}

@media (min-width: 576px) {
  .content-card h3 {
    font-size: 1.4rem !important;
    margin-bottom: 1rem !important;
  }
}

.dark-mode .content-card h3 {
  color: #a78bfa !important;
}

.content-card p {
  font-size: 0.95rem !important;
  line-height: 1.6 !important;
  color: #4b5563 !important;
  margin-bottom: 1.25rem !important;
}

@media (min-width: 576px) {
  .content-card p {
    font-size: 1rem !important;
    margin-bottom: 1.5rem !important;
  }
}

.dark-mode .content-card p {
  color: #d1d5db !important;
}

/* Info Graphic */
.info-graphic {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 1rem !important;
  margin: 1.5rem 0 !important;
}

@media (min-width: 768px) {
  .info-graphic {
    flex-direction: row !important;
    justify-content: center !important;
    margin: 2rem 0 !important;
  }
}

.timezone-block {
  background-color: #f8fafc !important;
  border-radius: 12px !important;
  padding: 1.25rem !important;
  text-align: center !important;
  width: 100% !important;
  transition: all 0.2s ease !important;
}

@media (min-width: 576px) {
  .timezone-block {
    padding: 1.5rem !important;
  }
}

@media (min-width: 768px) {
  .timezone-block {
    flex: 1 !important;
  }
}

.dark-mode .timezone-block {
  background-color: #1e293b !important;
}

.timezone-block.est {
  border-left: 5px solid #8b5cf6 !important;
}

.timezone-block.pst {
  border-left: 5px solid #6366f1 !important;
}

.timezone-name {
  font-size: 1rem !important;
  font-weight: 700 !important;
  margin-bottom: 0.5rem !important;
}

@media (min-width: 576px) {
  .timezone-name {
    font-size: 1.1rem !important;
  }
}

.timezone-time {
  font-size: 1.5rem !important;
  font-weight: 800 !important;
  color: #7c3aed !important;
  margin-bottom: 0.5rem !important;
}

@media (min-width: 576px) {
  .timezone-time {
    font-size: 1.8rem !important;
  }
}

.dark-mode .timezone-time {
  color: #a78bfa !important;
}

.timezone-cities {
  font-size: 0.85rem !important;
  color: #64748b !important;
}

@media (min-width: 576px) {
  .timezone-cities {
    font-size: 0.9rem !important;
  }
}

.dark-mode .timezone-cities {
  color: #94a3b8 !important;
}

.timezone-arrow {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 0.5rem !important;
  color: #64748b !important;
}

@media (min-width: 768px) {
  .timezone-arrow {
    flex-direction: column !important;
  }
}

.dark-mode .timezone-arrow {
  color: #94a3b8 !important;
}

.timezone-arrow svg {
  color: #7c3aed !important;
  transform: rotate(90deg) !important;
}

@media (min-width: 768px) {
  .timezone-arrow svg {
    transform: rotate(0deg) !important;
  }
}

.dark-mode .timezone-arrow svg {
  color: #a78bfa !important;
}

/* DST Table */
.dst-table {
  margin: 1.25rem 0 !important;
  border-radius: 8px !important;
  overflow: hidden !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05) !important;
  width: 100% !important;
}

@media (min-width: 576px) {
  .dst-table {
    margin: 1.5rem 0 !important;
  }
}

.dark-mode .dst-table {
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2) !important;
}

.dst-row {
  display: grid !important;
  grid-template-columns: 1fr !important;
}

@media (min-width: 576px) {
  .dst-row {
    grid-template-columns: 1fr 1fr !important;
  }
}

.dst-row.header {
  background-color: #8b5cf6 !important;
  color: white !important;
  font-weight: 600 !important;
}

.dark-mode .dst-row.header {
  background-color: #6d28d9 !important;
}

.dst-cell {
  padding: 0.75rem !important;
  text-align: center !important;
  border: 1px solid #e2e8f0 !important;
  font-size: 0.9rem !important;
}

@media (min-width: 576px) {
  .dst-cell {
    padding: 1rem !important;
    font-size: 1rem !important;
  }
}

.dark-mode .dst-cell {
  border-color: #334155 !important;
}

.dst-row:not(.header) .dst-cell {
  background-color: #f8fafc !important;
}

.dark-mode .dst-row:not(.header) .dst-cell {
  background-color: #1e293b !important;
}

/* Business Hours */
.business-hours {
  margin: 1.25rem 0 !important;
}

@media (min-width: 576px) {
  .business-hours {
    margin: 1.5rem 0 !important;
  }
}

.business-row {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 0.75rem !important;
  margin-bottom: 0.75rem !important;
}

@media (min-width: 576px) {
  .business-row {
    grid-template-columns: 1fr 1fr !important;
    gap: 1rem !important;
  }
}

.business-time {
  padding: 0.75rem !important;
  text-align: center !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  font-size: 0.9rem !important;
}

@media (min-width: 576px) {
  .business-time {
    font-size: 1rem !important;
  }
}

.business-time.est {
  background-color: #ede9fe !important;
  color: #5b21b6 !important;
}

.dark-mode .business-time.est {
  background-color: #4c1d95 !important;
  color: #c4b5fd !important;
}

.business-time.pst {
  background-color: #e0e7ff !important;
  color: #4338ca !important;
}

.dark-mode .business-time.pst {
  background-color: #3730a3 !important;
  color: #a5b4fc !important;
}

/* Broadcast Info */
.broadcast-info {
  display: flex !important;
  flex-direction: column !important;
  gap: 1rem !important;
  margin: 1.25rem 0 !important;
}

.broadcast-item {
  display: flex !important;
  gap: 1rem !important;
  padding: 1rem !important;
  background-color: #f8fafc !important;
  border-radius: 8px !important;
  transition: all 0.2s ease !important;
}

.dark-mode .broadcast-item {
  background-color: #1e293b !important;
}

.broadcast-icon {
  font-size: 1.5rem !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.broadcast-text {
  flex: 1 !important;
  font-size: 0.9rem !important;
  line-height: 1.5 !important;
  color: #4b5563 !important;
}

@media (min-width: 576px) {
  .broadcast-text {
    font-size: 1rem !important;
  }
}

.dark-mode .broadcast-text {
  color: #d1d5db !important;
}

.broadcast-text strong {
  color: #7c3aed !important;
  font-weight: 600 !important;
}

.dark-mode .broadcast-text strong {
  color: #a78bfa !important;
}

/* Tips List */
.tips-list {
  list-style-type: none !important;
  padding-left: 0 !important;
}

.tips-list li {
  position: relative !important;
  padding-left: 1.5rem !important;
  margin-bottom: 0.75rem !important;
  line-height: 1.5 !important;
  color: #4b5563 !important;
  font-size: 0.9rem !important;
}

@media (min-width: 576px) {
  .tips-list li {
    font-size: 1rem !important;
  }
}

.dark-mode .tips-list li {
  color: #d1d5db !important;
}

.tips-list li:before {
  content: "✓" !important;
  position: absolute !important;
  left: 0 !important;
  color: #7c3aed !important;
  font-weight: bold !important;
}

.dark-mode .tips-list li:before {
  color: #a78bfa !important;
}

/* Mobile Optimizations */
@media (max-width: 360px) {
  .converter-header h2 {
    font-size: 1.3rem !important;
  }

  #current-time {
    font-size: 1.5rem !important;
  }

  .time-input label, .timezone-select label, .time-result label {
    font-size: 0.85rem !important;
  }

  .time-input input, .timezone-select select {
    padding: 0.6rem 0.8rem !important;
    font-size: 0.9rem !important;
  }

  .converted-time-display {
    font-size: 1.1rem !important;
    padding: 0.6rem 0.8rem !important;
  }

  .feature-card h3, .content-card h3 {
    font-size: 1.1rem !important;
  }

  .supportive-content h2 {
    font-size: 1.3rem !important;
  }
}

/* Touch Device Optimizations */
@media (hover: none) {
  .time-input input, .timezone-select select {
    font-size: 16px !important; /* Prevents zoom on iOS */
  }

  #swap-timezones {
    width: 48px !important;
    height: 48px !important; /* Larger touch target */
  }
}

/* Animations */
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.converted-time-display {
  animation: pulse 2s infinite;
  animation-play-state: paused;
}

.converted-time-display.updated {
  animation-play-state: running;
}
