/* Forum Page Styles */

.forum-page {
  direction: rtl;
  width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

/* Hero Section */
.forum-hero {
  position: relative;
  background-image: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)),
    url("https://images.pexels.com/photos/5699419/pexels-photo-5699419.jpeg?auto=compress&cs=tinysrgb&w=1680");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--color-white);
  padding: 96px 0;
  text-align: center;
  width: 100%;
  box-sizing: border-box;
  transition: background-image 0.3s ease;
}

.forum-hero__inner {
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 24px;
}

.forum-hero__title {
  font-size: 3rem;
  font-weight: 800;
  line-height: 1.2;
  margin: 0 0 16px;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
  font-family: "Assistant", sans-serif;
}

.forum-hero__subtitle {
  font-size: 1.125rem;
  margin: 0;
  max-width: 48rem;
  margin-left: auto;
  margin-right: auto;
  font-family: "Assistant", sans-serif;
  opacity: 0.95;
}

/* Forum Section */
.forum-section {
  padding: 64px 0;
  background-color: var(--color-gray-100);
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 24px;
  transition: background-color 0.3s ease;
}

.forum-container {
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
  box-sizing: border-box;
}

/* Forum Head */
.forum-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 16px;
}

.forum-head__title {
  font-size: 1.875rem;
  font-weight: 700;
  color: var(--color-gray-800);
  margin: 0;
  font-family: "Assistant", sans-serif;
  transition: color 0.3s ease;
}

.forum-btn {
  background-color: var(--color-brand);
  color: var(--color-white);
  font-weight: 700;
  font-size: 1rem;
  padding: 12px 24px;
  border-radius: 8px;
  text-decoration: none;
  transition: background-color 0.3s ease;
  font-family: "Assistant", sans-serif;
  white-space: nowrap;
}

.forum-btn:hover {
  background-color: var(--color-brand-hover);
  color: var(--color-white);
}

/* Forum Card */
.forum-card {
  background: var(--color-white);
  border-radius: 8px;
  box-shadow: 0 4px 6px -1px var(--shadow-sm), 0 2px 4px -1px var(--shadow-sm);
  margin-bottom: 32px;
  overflow: hidden;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.forum-card__header {
  background-color: var(--color-gray-300);
  padding: 16px 24px;
  transition: background-color 0.3s ease;
}

.forum-card__title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-gray-900);
  margin: 0;
  font-family: "Assistant", sans-serif;
  transition: color 0.3s ease;
}

.forum-card__body {
  padding: 0;
}

/* Forum Table */
.forum-table {
  width: 100%;
  border-collapse: collapse;
  font-family: "Assistant", sans-serif;
}

.forum-table thead {
  background-color: var(--color-gray-50);
  border-bottom: 1px solid var(--color-gray-300);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.forum-table th {
  padding: 16px 24px;
  text-align: right;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--color-gray-700);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: color 0.3s ease;
}

.forum-table th.is-center {
  text-align: center;
}

.forum-table tbody tr {
  border-bottom: 1px solid var(--color-gray-300);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.forum-table tbody tr:hover {
  background-color: var(--color-gray-50);
}

.forum-table tbody tr:last-child {
  border-bottom: none;
}

.forum-table tbody tr td {
  padding: 16px 24px !important;
  vertical-align: top;
  border: none;
}

.forum-table tbody tr td:first-child {
  text-align: right;
}

.forum-table tbody tr td:last-child {
  text-align: right;
}

.forum-table tbody tr td.is-center {
  text-align: center;
}

/* Forum Links */
.forum-link {
  color: var(--color-brand);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: color 0.3s ease;
  display: inline-block;
  margin-bottom: 4px;
}

.forum-table tbody tr td:first-child .forum-link {
  font-weight: 700;
  font-size: 1rem;
}

.forum-link:hover {
  color: var(--color-brand-hover);
  text-decoration: underline;
}

/* Forum Meta */
.forum-meta {
  color: var(--color-gray-600);
  font-size: 0.875rem;
  margin: 4px 0 0 0;
  font-family: "Assistant", sans-serif;
  transition: color 0.3s ease;
}

.forum-table tbody tr td p {
  margin: 0;
  color: var(--color-gray-600);
  font-size: 0.875rem;
  font-family: "Assistant", sans-serif;
  transition: color 0.3s ease;
}

.forum-table tbody tr td p:first-child {
  margin-bottom: 4px;
}

.forum-table tbody tr td .forum-link {
  font-size: 14px;
  font-weight: 500;
}

/* Responsive Design */
@media screen and (max-width: 1024px) {
  .forum-hero {
    padding: 64px 0;
  }

  .forum-hero__title {
    font-size: 2rem;
  }

  .forum-hero__subtitle {
    font-size: 1rem;
  }

  .forum-section {
    padding: 48px 0;
  }

  .forum-head__title {
    font-size: 1.75rem;
  }
}

/* Dark theme overrides */
:root.dark .forum-hero {
  background-image: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)),
    url("https://images.pexels.com/photos/5699419/pexels-photo-5699419.jpeg?auto=compress&cs=tinysrgb&w=1680");
}

:root.dark .forum-section {
  background-color: var(--color-slate-900);
}

:root.dark .forum-head__title {
  color: var(--color-slate-50);
}

:root.dark .forum-card {
  background: var(--color-slate-925);
  box-shadow: 0 4px 6px -1px var(--shadow-2xl), 0 2px 4px -1px var(--shadow-xl);
}

:root.dark .forum-card__header {
  background-color: var(--color-slate-800);
}

:root.dark .forum-card__title {
  color: var(--color-slate-50);
}

:root.dark .forum-table thead {
  background-color: var(--color-slate-925);
  border-bottom: 1px solid var(--color-slate-700);
}

:root.dark .forum-table th {
  color: var(--color-slate-200);
}

:root.dark .forum-table tbody tr {
  border-bottom: 1px solid var(--color-slate-700) !important;
  background-color: var(--color-slate-925);
}

:root.dark .forum-table tbody tr:hover {
  background-color: var(--color-slate-800);
}

:root.dark .forum-link {
  color: var(--color-purple-600);
}

:root.dark .forum-link:hover {
  color: var(--color-purple-300);
}

:root.dark .forum-meta {
  color: var(--color-gray-400);
}

:root.dark .forum-table tbody tr td {
  border: none !important;
  color: var(--color-gray-400);

}

:root.dark .forum-table tbody tr td p {
  color: var(--color-gray-400);
}

@media screen and (max-width: 768px) {
  .forum-hero {
    padding: 48px 0;
  }

  .forum-hero__title {
    font-size: 1.75rem;
  }

  .forum-hero__subtitle {
    font-size: 1rem;
  }

  .forum-section {
    padding: 32px 0;
  }

  .forum-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .forum-btn {
    width: 100%;
    text-align: center;
  }

  .forum-card__header {
    padding: 12px 16px;
  }

  .forum-card__title {
    font-size: 18px;
  }

  .forum-table th,
  .forum-table tbody tr td {
    padding: 12px 16px !important;
  }

  .forum-table th.hide-sm,
  .forum-table tbody tr td.hide-sm {
    display: none;
  }
}

@media screen and (max-width: 480px) {
  .forum-hero__title {
    font-size: 1.5rem;
  }

  .forum-hero__subtitle {
    font-size: 0.875rem;
  }

  .forum-head__title {
    font-size: 1.5rem;
  }

  .forum-card__title {
    font-size: 1rem;
  }

  .forum-table th,
  .forum-table tbody tr td {
    padding: 10px 12px !important;
  }

  .forum-link {
    font-size: 14px;
  }

  .forum-meta {
    font-size: 12px;
  }
}
