:root {
  --bg: #f5f7fc;
  --panel: #ffffff;
  --panel-soft: #f0f3fa;
  --text: #111827;
  --muted: #4b5563;
  --accent: #ff7a3c;
  --accent-2: #1ec8a6;
  --accent-3: #5b7bff;
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
  --radius: 18px;
  --font: 'Bai Jamjuree', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --outline: rgba(15, 23, 42, 0.06);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 16% 20%, rgba(30, 200, 166, 0.14), transparent 26%),
    radial-gradient(circle at 82% 12%, rgba(255, 122, 60, 0.16), transparent 26%),
    radial-gradient(circle at 42% 80%, rgba(91, 123, 255, 0.12), transparent 30%),
    linear-gradient(160deg, #f7f9ff 0%, #edf2ff 60%, #f5f7fc 100%);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.7;
  letter-spacing: 0.01em;
}

a {
  color: rgb(102, 3, 102);
  text-decoration: none;
  font-weight: 600;
}

a:hover {
  color: blue;
  text-decoration: underline;
}

h1 {
  margin: 0 auto;
}

.main-title {
  line-height: 1.1;
  max-width: 1400px;
  margin: 18px auto 12px;
  font-size: 34px;
  padding: 18px 22px;
  /* background: linear-gradient(120deg, rgba(255, 122, 60, 0.16), rgba(30, 200, 166, 0.12)); */
  border-radius: 20px;
  /* border: 1px solid var(--outline); */
  /* box-shadow: 0 14px 30px rgba(15, 23, 42, 0.12); */
}

.page-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 28px;
  border-bottom: 1px solid var(--outline);
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.1);
}

.brand {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-3);
}

.nav {
  display: flex;
  align-items: center;
  gap: 18px;
}

.nav-links {
  display: flex;
  gap: 12px;
  font-weight: 700;
}

.nav-links a {
  padding: 9px 12px;
  border-radius: 12px;
  color: var(--text);
  text-align: center;
  border: 1px solid var(--outline);
  background: rgba(91, 123, 255, 0.06);
  transition: 0.2s ease;
}

.nav-links a.active,
.nav-links a:hover {
  background: linear-gradient(130deg, rgba(255, 122, 60, 0.18), rgba(30, 200, 166, 0.16));
  border-color: rgba(91, 123, 255, 0.14);
  color: var(--text);
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.12);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.social {
  display: flex;
  gap: 10px;
  margin: 0 auto;
}

.social a {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--text);
  /* border: 1px solid var(--outline); */
  /* background: rgba(91, 123, 255, 0.06); */
  transition: 0.2s ease;
}

.social a:hover {
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255, 122, 60, 0.36);
  background: linear-gradient(120deg, #ffb347, #5b7bff);
  color: #0f172a;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 12px 22px rgba(15, 23, 42, 0.16);
  transition: 0.18s ease;
  text-decoration: none;
}

.btn:hover {
  transform: translateY(-1px);
  background: linear-gradient(120deg, #5b7bff, #1ec8a6);
  box-shadow: 0 16px 32px rgba(91, 123, 255, 0.2);
}

.subscribe {
  text-decoration: none;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--outline);
  background: rgba(91, 123, 255, 0.08);
  border-radius: 14px;
  padding: 10px;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
}

.nav-toggle span {
  display: block;
  height: 3px;
  background: var(--text);
  border-radius: 8px;
}

.content {
  padding: 0 0 36px;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 22px 46px;
  display: grid;
  grid-template-columns: minmax(260px, 320px) 1fr;
  grid-template-areas: "sidebar feed";
  gap: 32px;
  align-items: flex-start;
}

.feed {
  grid-area: feed;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  align-items: stretch;
  grid-auto-rows: 1fr;
}
.feed-arcticle{
  display: block;
}

.feed-text {
  padding: 15px;
}

.post-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.88), rgba(245, 247, 252, 0.9));
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px 18px 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  border: 1px solid var(--outline);
  transition: 0.2s ease;
}

.post-card::before {
  content: '';
  position: absolute;
  inset: -40% auto auto -55%;
  width: 60%;
  height: 160%;
  background: radial-gradient(circle at 50% 50%, rgba(255, 122, 60, 0.18), transparent 62%);
  transform: rotate(8deg);
  opacity: 0.7;
  pointer-events: none;
}

.post-card::after {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2), var(--accent-3));
  opacity: 0.85;
  pointer-events: none;
}

.post-card:hover {
  transform: translateY(-4px);
  border-color: rgba(91, 123, 255, 0.16);
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
}

.media {
  display: flex;
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  background: #eef2fb;
  border: 1px solid var(--outline);
  flex-shrink: 0;
}

.placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 700;
  background: radial-gradient(circle at 50% 40%, rgba(30, 200, 166, 0.2), rgba(91, 123, 255, 0.2));
}

.placeholder img {
  border-radius: 12px;
  width: 100%;
  min-height: 200px;
  object-fit: cover;
}

.chip-action {
  position: absolute;
  right: 12px;
  top: 12px;
  border: 1px solid rgba(91, 123, 255, 0.16);
  background: linear-gradient(135deg, var(--accent-3), var(--accent));
  color: #0c101c;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  box-shadow: 0 14px 26px rgba(126, 139, 255, 0.35);
  cursor: pointer;
  font-size: 16px;
}

.body h2 {
  margin: 8px 0 12px;
  line-height: 1.3;
  font-size: 24px;
}

.body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.body p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.badge {
  display: inline-block;
  padding: 8px 12px;
  border-radius: 50px;
  font-weight: 800;
  font-size: 13px;
  color: #0c101c;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge-primary {
  background: linear-gradient(135deg, var(--accent), #ffc176);
}

.badge-teal {
  background: linear-gradient(135deg, var(--accent-2), #b8f4e7);
}

.sidebar {
  grid-area: sidebar;
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: sticky;
  top: 110px;
  align-self: flex-start;
}

.card {
  background: linear-gradient(160deg, #ffffff 0%, #f6f8fd 100%);
  border-radius: 18px;
  padding: 18px 18px 10px;
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.12);
  border: 1px solid var(--outline);
}

.search-card {
  background: var(--panel);
}

.card-title {
  font-size: 18px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border: 1px solid var(--outline);
  border-radius: 14px;
  background: rgba(91, 123, 255, 0.06);
}

.search-box {
  margin: 16px 0 10px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  background: var(--panel-soft);
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.search-box input {
  border: none;
  outline: none;
  font-size: 15px;
  background: transparent;
  color: var(--text);
}

.search-box .btn {
  width: 110px;
  box-shadow: 0 8px 18px rgba(91, 123, 255, 0.22);
}

.recent-card {
  padding-bottom: 12px;
}

.recent-list {
  list-style: none;
  padding: 0;
  margin: 14px 0 0;
}

.recent-list li {
  padding: 5px 0;
  border-bottom: 1px solid #3F51B5;
  font-weight: 700;
}

.recent-list li:last-child {
  border-bottom: none;
}

.recommendations {
  padding: 0 24px 44px;
}

.rec-card {
  max-width: 1200px;
  margin: 0 auto;
  background: linear-gradient(165deg, #ffffff 0%, #f2f5ff 100%);
  border: 1px solid var(--outline);
  border-radius: 18px;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.14);
  padding: 18px 18px 24px;
}

.rec-card__title {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 14px;
  background: rgba(91, 123, 255, 0.08);
  font-size: 18px;
  font-weight: 800;
  margin-bottom: 18px;
  border: 1px solid var(--outline);
}

.rec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.rec-item {
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: var(--text);
  background: var(--panel-soft);
  border-radius: 16px;
  padding: 10px 10px 14px;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.25);
  transition: 0.18s ease;
}

.rec-item:hover {
  border-color: rgba(255, 255, 255, 0.16);
  transform: translateY(-3px);
}

.rec-thumb {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  min-height: 140px;
  background: #10182c;
  display: grid;
  align-items: end;
}

.rec-thumb .badge {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 1;
}

.rec-placeholder {
  background: linear-gradient(135deg, #ffb347, #5b7bff, #1ec8a6);
  height: 100%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 800;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

.rec-item p {
  margin: 0;
  font-weight: 800;
  line-height: 1.3;
}

@media (max-width: 1024px) {
  .container {
    grid-template-columns: 1fr;
    grid-template-areas:
      "feed"
      "sidebar";
  }

  .feed {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sidebar {
    position: static;
  }
}

@media (max-width: 760px) {
  .topbar {
    padding: 14px 18px;
  }

  .nav {
    position: absolute;
    top: 72px;
    right: 18px;
    left: 18px;
    flex-direction: column;
    background: var(--panel);
    border-radius: 14px;
    box-shadow: 0 18px 30px rgba(0, 0, 0, 0.35);
    padding: 14px 16px;
    gap: 12px;
    display: none;
  }

  .nav.open {
    display: flex;
  }

  .nav-links {
    flex-direction: column;
    width: 100%;
  }

  .nav-links a {
    width: 100%;
  }

  .nav-actions {
    width: 100%;
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .subscribe {
    width: 100%;
    justify-content: center;
  }

  .nav-toggle {
    display: flex;
  }

  .content {
    padding: 0 0;
  }

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

  .post-card {
    padding: 14px 14px 20px;
  }

  .body h2 {
    font-size: 22px;
  }

  .recommendations {
    padding: 0 16px 28px;
  }

  .rec-card {
    padding: 16px 12px 18px;
  }

  .rec-grid {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 80%;
    overflow-x: auto;
    padding-bottom: 6px;
    scroll-snap-type: x mandatory;
  }

  .rec-item {
    scroll-snap-align: start;
  }
}

.img-box {
  width: 100%;
  height: auto;
  overflow: hidden;
  margin: 0px auto 15px auto;
}

.img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

footer {
  padding: 18px;
  margin: 0 auto;
  text-align: center;
  color: var(--muted);
  border-top: 1px solid var(--outline);
  background: rgba(255, 255, 255, 0.92);
}

.button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 1.5px;
  padding: 15px 10px;
  background: linear-gradient(135deg, var(--accent-3), var(--accent));
  border-radius: 0.75rem;
  transition: all 0.12s ease;
  max-width: 360px;
  height: 60px;
  color: #d3d3d5;
  margin: 20px auto;
  border: 1px solid rgba(255, 122, 60, 0.32);
  box-shadow: 0 16px 30px rgba(15, 23, 42, 0.14);
}

.button:hover {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  transform: translateY(-2px);
}

.button:active {
  letter-spacing: 1px;
  transform: translateY(4px);
  background: linear-gradient(135deg, var(--accent-2), var(--accent-3));
}



/* -------table--------- */

.table-double {
  border-collapse: collapse;
  text-align: center;
  width: 100%;
  max-width: 900px;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 14px;
  color: #333;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.table-double thead th {
  background-color: #f8f8f8;
  text-align: center;
  padding: 12px;
  font-weight: 700;
  font-size: 18px;
  border-bottom: 2px solid #e0e0e0;
}

.table-double tbody td {
  padding: 12px;
  vertical-align: middle;
  border-bottom: 1px solid #eee;
}

.table-double tbody tr:nth-child(even) {
  background-color: #fafafa;
}



