@import url('portal-theme.css');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  direction: rtl;
}

body {
  font-family: var(--font);
  color: var(--ink);
  background: radial-gradient(ellipse 120% 80% at 50% 0%, var(--sw-bg-tint, #e6f4f8), var(--sw-bg, #f9fbfc) 55%);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }

.catalog-header {
  background: #fff;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 100;
}

.catalog-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.catalog-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.catalog-brand img {
  height: 32px;
  width: auto;
}

.catalog-brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.catalog-brand__title {
  font-size: 15px;
  font-weight: 700;
  color: var(--purple-deep);
}

.catalog-brand__sub {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
}

.catalog-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.catalog-nav a {
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  padding: 8px 14px;
  border-radius: 8px;
}

.catalog-nav a:hover {
  color: var(--purple);
  background: var(--purple-pale);
  text-decoration: none;
}

.catalog-nav .btn-register {
  color: #fff;
  background: var(--sw-teal, #11a4c8);
  box-shadow: var(--sw-shadow-teal, 0 8px 24px rgba(17, 164, 200, 0.22));
}

.catalog-nav .btn-register:hover {
  background: var(--sw-teal-dark, #0d8aab);
  text-decoration: none;
}

.catalog-hero {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 24px 24px;
}

.catalog-hero .eyebrow {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--purple);
  margin-bottom: 10px;
}

.catalog-hero h1 {
  font-family: var(--font-h);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 400;
  color: var(--ink);
  margin-bottom: 12px;
  line-height: 1.2;
}

.catalog-hero .lead {
  font-size: 15px;
  color: var(--muted);
  max-width: 720px;
  line-height: 1.7;
  margin-bottom: 24px;
}

.catalog-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 8px;
}

.catalog-search {
  flex: 1 1 240px;
  display: flex;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.catalog-search input {
  flex: 1;
  border: 0;
  padding: 10px 14px;
  font: inherit;
  font-size: 14px;
  outline: none;
}

.catalog-search input:focus {
  box-shadow: inset 0 0 0 2px rgba(157, 27, 99, 0.15);
}

.catalog-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
}

.catalog-filters button {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  padding: 7px 16px;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.catalog-filters button:hover {
  border-color: var(--purple-faint);
  color: var(--purple-deep);
}

.catalog-filters button.active {
  background: var(--purple);
  border-color: var(--purple);
  color: #fff;
}

.catalog-grid {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px 64px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.role-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px 20px 18px;
  box-shadow: 0 4px 20px rgba(26, 26, 26, 0.04);
  display: flex;
  flex-direction: column;
  min-height: 100%;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}

.role-card:hover {
  border-color: var(--purple-faint);
  box-shadow: 0 8px 28px rgba(125, 27, 88, 0.1);
  transform: translateY(-2px);
}

.role-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.role-card__icon {
  font-size: 28px;
  line-height: 1;
  flex-shrink: 0;
}

.role-card__badge {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--soft);
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 3px 8px;
  border-radius: 999px;
}

.role-card h2 {
  font-size: 16px;
  font-weight: 700;
  color: var(--purple-deep);
  margin-bottom: 2px;
  line-height: 1.3;
}

.role-card .title-fa {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 14px;
  direction: rtl;
  text-align: left;
}

.role-card ul {
  list-style: none;
  flex: 1;
  margin-bottom: 16px;
}

.role-card li {
  position: relative;
  padding-inline-start: 18px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.75;
  margin-bottom: 8px;
}

.role-card li::before {
  content: '‹';
  position: absolute;
  inset-inline-start: 0;
  color: var(--sw-teal, #11a4c8);
  font-weight: 700;
}

.role-card__foot {
  border-top: 1px solid var(--line);
  padding-top: 14px;
  margin-top: auto;
}

.role-card__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--purple-deep);
  background: var(--purple-pale);
  border: 1px solid var(--purple-faint);
  cursor: pointer;
  transition: background 0.15s;
}

.role-card__cta:hover {
  background: #fff;
  text-decoration: none;
}

.catalog-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 48px 24px;
  color: var(--muted);
  font-size: 15px;
}

.catalog-footer {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 24px;
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}

.catalog-footer a {
  color: var(--purple);
  font-weight: 600;
}

@media (max-width: 1024px) {
  .catalog-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .catalog-grid { grid-template-columns: 1fr; }
  .catalog-header__inner { padding: 0 16px; }
  .catalog-hero, .catalog-grid { padding-left: 16px; padding-right: 16px; }
  .catalog-nav a:not(.btn-register) { display: none; }
}
