/* Custom Fonts */
@font-face {
  font-family: "BigBlueTerm";
  src: url("../fonts/BigBlueTerm437NerdFontMono-Regular.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-color: #233c4b;
  --secondary-color: #fac846;
  --accent-color: #ff7d2d;
  --success-color: #fac846;
  --bg-color: #1a2c38;
  --card-bg: #2a4456;
  --text-color: #f5f5f5;
  --text-light: #b8c5cf;
  --border-color: #3d5a6f;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.4);
}

body {
  font-family:
    "Segoe UI Variable",
    "Segoe UI",
    -apple-system,
    BlinkMacSystemFont,
    "Roboto",
    "Oxygen",
    "Ubuntu",
    "Cantarell",
    "Helvetica Neue",
    sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  max-width: 100%;
  margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
}

/* Header */
.header {
  background: linear-gradient(
    135deg,
    var(--secondary-color) 0%,
    var(--accent-color) 100%
  );
  color: var(--primary-color);
  padding: 0.5rem 0;
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
  overflow: visible;
}

.header .container {
  position: relative;
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-img {
  padding-left: 5px;
}

.logo-img-mobile {
  display: none;
}

.weather {
  display: flex;
  align-items: center;
  font-weight: 600;
  font-size: 0.9rem;
}

.weather .city,
.weather .temp {
  margin: 0;
  line-height: 1.2;
}

.weather-icon {
  height: 60px;
}

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

.search-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.header-search {
  padding: 0.5rem 2.5rem 0.5rem 1rem;
  border: none;
  border-radius: 8px;
  background-color: white;
  color: var(--primary-color);
  font-size: 0.95rem;
  width: 250px;
  transition: all 0.3s ease;
}

.header-search::placeholder {
  color: rgba(35, 60, 75, 0.6);
}

.header-search:focus {
  outline: none;
  background-color: white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.search-toggle-btn {
  display: none;
  background: transparent;
  border: none;
  color: var(--primary-color);
  padding: 0.5rem 0.8rem;
  cursor: pointer;
  font-size: 1rem;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.search-toggle-btn:hover {
  background-color: rgba(0, 0, 0, 0.1);
}

.search-close-btn {
  display: none;
  position: absolute;
  top: 50%;
  right: 0.5rem;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--primary-color);
  padding: 0;
  cursor: pointer;
  font-size: 1.1rem;
  z-index: 1001;
  transition: all 0.3s ease;
  width: 2rem;
  height: 2rem;
  align-items: center;
  justify-content: center;
}

.search-close-btn:hover {
  color: var(--accent-color);
}

.search-close-btn.visible {
  display: flex;
}

.header-date {
  color: var(--primary-color);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.4rem 1rem;
}

.nav-btn {
  background: transparent;
  border: none;
  color: var(--primary-color);
  padding: 0.4rem 1.2rem;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.3s ease;
  font-weight: 600;
  border-radius: 6px;
}

.nav-btn:hover {
  background-color: rgba(0, 0, 0, 0.1);
}

.nav-btn.active {
  font-weight: 700;
}

.nav-btn .fa-newspaper {
  display: none;
}

/* Main Content */
main {
  flex: 1;
  padding: 0;
  margin-top: 1rem;
  display: flex;
  gap: 2rem;
  align-items: flex-start;
}

.main-content {
  flex: 1;
  min-width: 0;
  margin-top: 2rem;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

/* Hamburger Button */
.hamburger-btn {
  display: none;
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 56px;
  height: 56px;
  background: linear-gradient(
    135deg,
    var(--secondary-color) 0%,
    var(--accent-color) 100%
  );
  border: none;
  border-radius: 50%;
  color: var(--primary-color);
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  z-index: 999;
  transition: all 0.3s ease;
}

.hamburger-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
}

/* Topic Sidebar */
.topic-sidebar {
  width: 240px;
  background-color: var(--card-bg);
  border-radius: 12px;
  box-shadow: var(--shadow);
  position: sticky;
  top: 108px;
  max-height: calc(100vh - 108px);
  overflow-y: auto;
  margin-top: 2rem;
  transition: transform 0.3s ease;
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-left: 1rem;
  padding-top: 0.5rem;
}

.sidebar-close-btn {
  display: none;
  background: transparent;
  border: none;
  color: var(--text-color);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0;
  transition: color 0.3s ease;
}

.sidebar-close-btn:hover {
  color: var(--accent-color);
}

.sidebar-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0;
  margin-top: 0;
  color: var(--secondary-color);
}

.topic-nav {
  display: flex;
  flex-direction: column;
}

.topic-nav::after {
  content: "";
  display: block;
  height: 1.5rem;
}

.topic-btn {
  display: flex;
  align-items: center;
  padding: 0.75rem 1rem;
  background-color: transparent;
  border: transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
  font-size: 0.95rem;
  color: var(--text-color);
}

.topic-btn:hover {
  background-color: var(--bg-color);
  border-color: var(--border-color);
}

.topic-btn.active {
  background-color: var(--accent-color);
  border-color: var(--accent-color);
  color: var(--primary-color);
}

.topic-btn.active .topic-name {
  font-weight: 600;
}

.topic-btn.empty-topic {
  opacity: 0.4;
  cursor: default;
}

.topic-btn.empty-topic:hover {
  background-color: transparent;
  border-color: transparent;
}

.topic-name {
  font-weight: 500;
}

/* Loading State */
.loading {
  text-align: center;
  padding: 3rem;
  margin-top: 2rem;
}

.spinner {
  border: 4px solid var(--border-color);
  border-top: 4px solid var(--accent-color);
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.hidden {
  display: none !important;
}

/* Error Message */
.error-message {
  background-color: rgba(255, 125, 45, 0.15);
  border: 1px solid var(--accent-color);
  color: var(--accent-color);
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  margin-top: 2rem;
}

/* Welcome State */
.welcome-state {
  text-align: center;
  padding: 3rem 2rem;
  margin-top: 2rem;
}

.welcome-content {
  max-width: 900px;
  margin: 0 auto;
  background-color: var(--card-bg);
  padding: 3rem;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.welcome-content h2 {
  color: var(--secondary-color);
  font-size: 2rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.welcome-logo {
  height: 2rem;
  width: auto;
  vertical-align: middle;
}

.welcome-description {
  color: var(--text-light);
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  line-height: 1.6;
}

.welcome-feed-form {
  background-color: var(--card-bg);
  padding: 2rem;
  border-radius: 8px;
}

.welcome-feed-form h3 {
  color: var(--secondary-color);
  font-size: 1.3rem;
  margin-bottom: 1.5rem;
}

.welcome-feed-form .add-feed-form {
  flex-direction: column;
  align-items: stretch;
}

.welcome-feed-form .add-feed-form .input-field,
.welcome-feed-form .add-feed-form .select-field {
  width: 100%;
  min-width: 100%;
}

.welcome-feed-form .add-feed-form .btn {
  margin-top: 0.5rem;
  align-self: center;
  width: auto;
  min-width: 200px;
  padding: 0.75rem 2rem;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 3rem;
  color: var(--text-light);
  margin-top: 2rem;
}

/* Articles Grid */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.article-card {
  background-color: var(--card-bg);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  position: relative;
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.article-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background-color: var(--primary-color);
}

.article-content {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.article-source {
  display: inline-block;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--accent-color);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.article-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  line-height: 1.4;
  color: var(--text-color);
}

.article-description {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 1rem;
  flex: 1;
  line-height: 1.5;
}

.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.article-tag {
  display: inline-block;
  background-color: rgba(250, 200, 70, 0.2);
  color: var(--secondary-color);
  font-size: 0.75rem;
  padding: 0.25rem 0.6rem;
  border-radius: 12px;
  border: 1px solid var(--secondary-color);
  font-weight: 500;
}

/* Clickable tags */
.clickable-tag {
  cursor: pointer;
  transition: all 0.2s ease;
}

.clickable-tag:hover {
  background-color: rgba(250, 200, 70, 0.35);
  transform: scale(1.05);
  border-color: var(--accent-color);
}

/* Active tag filter indicator */
.active-tag-filter {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background-color: var(--card-bg);
  border-radius: 8px;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
}

.filter-label {
  font-weight: 600;
  color: var(--text-light);
  font-size: 0.9rem;
}

.filter-tag {
  display: inline-block;
  background-color: rgba(250, 200, 70, 0.3);
  color: var(--secondary-color);
  font-size: 0.9rem;
  padding: 0.4rem 0.8rem;
  border-radius: 12px;
  border: 1px solid var(--secondary-color);
  font-weight: 600;
}

.clear-filter-btn {
  background: transparent;
  border: none;
  color: var(--accent-color);
  cursor: pointer;
  font-size: 1.2rem;
  padding: 0.25rem 0.5rem;
  transition: all 0.2s ease;
  margin-left: auto;
}

.clear-filter-btn:hover {
  color: #e66a1f;
  transform: scale(1.1);
}

.article-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: auto;
}

.article-date {
  font-size: 0.85rem;
}

.read-indicator {
  position: absolute;
  bottom: 20px;
  right: 15px;
  width: 28px;
  height: 28px;
  background-color: var(--secondary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  animation: fadeIn 0.3s ease;
}

.read-indicator svg {
  width: 16px;
  height: 16px;
  color: var(--primary-color);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.5);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Compact Mode Styles */
.articles-grid.compact-mode {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-radius: 12px;
  overflow: hidden;
}

.article-card-compact {
  flex-direction: row;
  height: auto;
  min-height: auto;
  padding: 0;
  border-radius: 0;
  box-shadow: none;
  border-bottom: 1px solid rgba(250, 200, 70, 0.2);
}

.article-card-compact:last-child {
  border-bottom: none;
}

.article-card-compact:hover {
  transform: none;
  background-color: rgba(250, 200, 70, 0.1);
}

.article-content-compact {
  padding: 1rem 1.25rem;
  width: 100%;
}

.article-title-compact {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.article-card-compact .article-tags {
  margin-bottom: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.article-card-compact .article-tag {
  background-color: transparent;
  border: none;
  padding: 0;
  margin-right: 0.5rem;
  line-height: 1;
}

.article-source-compact {
  font-size: 0.8rem;
  color: var(--accent-color);
  font-weight: 600;
  text-transform: uppercase;
  margin-right: 0.5rem;
  line-height: 1;
}

.article-card-compact .article-date {
  font-size: 0.8rem;
  white-space: nowrap;
}

.article-card-compact .read-indicator {
  top: 12px;
  right: 12px;
  bottom: auto;
  width: 24px;
  height: 24px;
}

.article-card-compact .read-indicator svg {
  width: 14px;
  height: 14px;
}

/* Mobile responsive for compact mode */
@media (max-width: 768px) {
  .articles-grid.compact-mode {
    gap: 0;
  }

  .article-content-compact {
    padding: 0.75rem 1rem;
  }

  .active-tag-filter {
    flex-wrap: wrap;
    padding: 0.75rem 1rem;
  }

  .clear-filter-btn {
    margin-left: 0;
  }

  /* Move read indicator to bottom right on mobile */
  .read-indicator {
    bottom: 12px;
    right: 12px;
  }

  .article-card-compact .read-indicator {
    top: auto;
    bottom: 12px;
    right: 12px;
  }

  /* Move date to its own line below tags in compact mode */
  .article-card-compact .article-date {
    width: 100%;
    margin-top: 0.25rem;
  }
}

/* Info Page */
#info-view {
  margin-top: 2rem;
}

.info-content {
  max-width: 900px;
  margin: 0 auto 3rem auto;
  background-color: var(--card-bg);
  padding: 3rem;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.info-content h2 {
  color: var(--secondary-color);
  font-size: 2rem;
  margin-bottom: 2rem;
  text-align: left;
}

.info-section {
  margin-bottom: 2.5rem;
}

.info-section h3 {
  color: var(--secondary-color);
  font-size: 1.3rem;
  margin-bottom: 1rem;
}

.info-section p {
  color: var(--text-color);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.info-section ul,
.info-section ol {
  color: var(--text-color);
  line-height: 2;
  margin-left: 2rem;
  margin-bottom: 1rem;
}

.info-section li {
  margin-bottom: 0.5rem;
}

.info-section strong {
  color: var(--secondary-color);
}

/* Settings Page */
.settings-section {
  padding: 0;
  margin-bottom: 1.5rem;
}

.settings-section h3 {
  margin-bottom: 0.5rem;
  color: var(--secondary-color);
}

.section-description {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.feed-list {
  margin-bottom: 1rem;
}

.feed-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  background-color: rgba(61, 90, 111, 0.3);
  border-radius: 6px;
  margin-bottom: 0.5rem;
}

.feed-info {
  flex: 1;
}

.feed-name {
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.feed-url {
  font-size: 0.85rem;
  color: var(--text-light);
  word-break: break-all;
}

.feed-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  flex: 1;
}

.feed-checkbox {
  width: 20px;
  height: 20px;
  cursor: pointer;
  flex-shrink: 0;
}

.custom-badge {
  display: inline-block;
  background-color: var(--accent-color);
  color: var(--primary-color);
  font-size: 0.7rem;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  margin-left: 0.5rem;
  font-weight: 600;
}

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

.source-column {
  background-color: var(--card-bg);
  border-radius: 8px;
  padding: 1rem;
}

.source-column-header {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--secondary-color);
  margin-bottom: 0.75rem;
  padding-bottom: 0;
  text-align: left;
}

.source-header-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}

.source-select-all {
  width: 18px;
  height: 18px;
  cursor: pointer;
  flex-shrink: 0;
}

.source-column-feeds {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.feed-checkbox-item {
  display: flex;
  flex-direction: column;
}

.feed-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 6px;
}

.feed-name {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-color);
}

.feed-category-badge {
  display: inline-block;
  background-color: rgba(250, 200, 70, 0.2);
  color: var(--secondary-color);
  font-size: 0.7rem;
  padding: 0.2rem 0.5rem;
  border-radius: 12px;
  border: 1px solid var(--secondary-color);
  margin-left: 0.5rem;
  font-weight: 500;
}

.custom-feed-checkbox-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.5rem;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.custom-feed-checkbox-item:hover {
  background-color: rgba(61, 90, 111, 0.3);
}

.btn-remove-compact {
  background: none;
  color: var(--accent-color);
  border: none;
  cursor: pointer;
  font-size: 1.4rem;
  line-height: 1;
  transition: all 0.2s ease;
  flex-shrink: 0;
  padding: 0;
  font-weight: 700;
  margin-right: 10px;
}

.btn-remove-compact:hover {
  color: #e66a1f;
  transform: scale(1.2);
}

.btn-remove {
  background-color: var(--accent-color);
  color: white;
  border: none;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.btn-remove:hover {
  background-color: #e66a1f;
}

.add-feed-section {
  background-color: var(--card-bg);
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
}

.my-feeds-section {
  background-color: var(--card-bg);
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
}

.add-feed-form {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
}

.add-feed-form .input-field {
  flex: 2;
  min-width: 250px;
}

.add-feed-form .select-field {
  flex: 0 0 auto;
  min-width: 180px;
  background-color: var(--bg-color);
  color: var(--text-color);
}

.add-feed-form .btn {
  flex: 0 0 auto;
  white-space: nowrap;
}

.input-field {
  flex: 1;
  min-width: 200px;
  padding: 0.75rem;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  transition: all 0.3s ease;
  background-color: var(--bg-color);
  color: var(--text-color);
}

.input-field::placeholder {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
}

.input-field:focus {
  outline: none;
}

.select-field {
  padding: 0.75rem;
  padding-right: 2.5rem;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  background-color: white;
  color: var(--primary-color);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fac846' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 1.2em;
}

.select-field:focus {
  outline: none;
  box-shadow: 0 0 0 2px var(--primary-color);
}

.setting-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.setting-row label {
  font-weight: 500;
}

.help-text {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 0.5rem;
}

/* Buttons */
.btn {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
  transition: all 0.3s ease;
  font-weight: 500;
}

.btn-primary {
  background-color: var(--secondary-color);
  color: var(--primary-color);
}

.btn-primary:hover {
  background-color: #f5bc2d;
}

.btn-secondary {
  background-color: var(--success-color);
  color: var(--primary-color);
}

.btn-secondary:hover {
  background-color: #f5bc2d;
}

.btn-danger {
  background-color: var(--accent-color);
  color: white;
}

.btn-danger:hover {
  background-color: #e66a1f;
}

.settings-actions {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
  margin-bottom: 3rem;
}

/* Footer */
.footer {
  background-color: #1a2c38;
  color: var(--accent-color);
  text-align: left;
  padding: 1rem 0;
  margin-top: 2rem;
  font-weight: 600;
  font-size: 0.85rem;
}

/* Sidebar Backdrop */
.sidebar-backdrop {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(26, 44, 56, 0.7);
  z-index: 999;
  backdrop-filter: blur(2px);
}

.sidebar-backdrop.active {
  display: block;
}

/* Custom Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(26, 44, 56, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  backdrop-filter: blur(4px);
}

.modal-content {
  background-color: var(--card-bg);
  border-radius: 12px;
  padding: 2rem;
  max-width: 500px;
  width: 90%;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  border: 2px solid var(--border-color);
}

.modal-title {
  color: var(--secondary-color);
  margin-bottom: 1rem;
  font-size: 1.3rem;
}

.modal-message {
  color: var(--text-color);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.modal-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
}

.modal-actions .btn {
  min-width: 100px;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .search-wrapper {
    position: static;
  }

  .header-search {
    display: none;
    position: fixed;
    top: 60px;
    left: 1rem;
    width: calc(100vw - 2rem);
    font-size: 16px;
    padding: 0.9rem 2.8rem 0.9rem 1rem;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-sizing: border-box;
  }

  .header-search.expanded {
    display: block;
  }

  .search-close-btn {
    position: fixed;
    top: 59px;
    right: 1.5rem;
    transform: none;
    font-size: 1.3rem;
    width: 2.8rem;
    height: 3.3rem;
  }

  .header-search:focus {
    outline: none;
    background-color: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  }

  .search-toggle-btn {
    display: block;
  }
}

@media (max-width: 992px) {
  .header-date {
    display: none;
  }

  .weather .city {
    display: none;
  }

  .weather-icon {
    height: 50px;
  }

  .nav {
    gap: 0.5rem;
  }

  .nav-btn .fa-newspaper {
    display: inline;
  }

  .nav-btn-text {
    display: none;
  }

  .nav-btn {
    padding: 0.4rem 0.8rem;
    font-size: 1rem;
  }

  main {
    flex-direction: column;
    gap: 1rem;
  }

  .main-content {
    width: 100%;
    margin-top: 1rem;
  }

  /* Show hamburger button on mobile */
  .hamburger-btn {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* Hide hamburger when sidebar is hidden */
  .hamburger-btn.hidden {
    display: none;
  }

  /* Sidebar as slide-in menu on mobile */
  .topic-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    max-width: 85vw;
    height: 100vh;
    max-height: 100vh;
    margin-top: 0;
    padding: 2rem 1.5rem;
    border-radius: 0;
    z-index: 1000;
    transform: translateX(-100%);
    overflow-y: auto;
  }

  /* Show sidebar when active */
  .topic-sidebar.mobile-active {
    transform: translateX(0);
  }

  /* Show close button on mobile */
  .sidebar-close-btn {
    display: block;
  }

  .sidebar-header {
    margin-bottom: 1.5rem;
  }

  .topic-nav {
    flex-direction: column;
    gap: 0.5rem;
  }

  .topic-btn {
    flex: 1;
    padding: 0.75rem 1rem;
    width: 100%;
  }

  .sidebar-title {
    font-size: 1.1rem;
    margin-bottom: 0;
  }

  .add-feed-form {
    flex-direction: column;
  }

  .add-feed-form .input-field,
  .add-feed-form .select-field,
  .add-feed-form .btn {
    width: 100%;
    min-width: 100%;
  }

  .input-field {
    width: 100%;
  }

  .welcome-content {
    padding: 2rem 1.5rem;
  }

  .welcome-content h2 {
    font-size: 1.5rem;
  }

  .welcome-feed-form {
    padding: 1.5rem;
  }

  .info-content {
    padding: 2rem 1.5rem;
  }

  .info-content h2 {
    font-size: 1.5rem;
  }

  .info-section ul,
  .info-section ol {
    margin-left: 1.5rem;
  }

  .settings-actions {
    flex-direction: column;
  }

  .source-columns {
    grid-template-columns: 1fr;
  }

  .btn {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .welcome-state {
    padding: 0 0 2rem 0;
  }

  .welcome-content {
    padding: 2rem 1rem;
  }

  .logo {
    font-size: 0;
  }

  .logo-img {
    height: 32px;
  }

  .logo-img-desktop {
    display: none;
  }

  .logo-img-mobile {
    display: block;
  }

  .articles-grid {
    grid-template-columns: 1fr;
  }
}
