@font-face {
  font-family: "Thmanyah Sans";
  src: url("../fonts/thmanyahsans/thmanyahsans-Light.otf") format("opentype");
  font-display: swap;
  font-style: normal;
  font-weight: 300;
}

@font-face {
  font-family: "Thmanyah Sans";
  src: url("../fonts/thmanyahsans/thmanyahsans-Regular.otf") format("opentype");
  font-display: swap;
  font-style: normal;
  font-weight: 400;
}

@font-face {
  font-family: "Thmanyah Sans";
  src: url("../fonts/thmanyahsans/thmanyahsans-Medium.otf") format("opentype");
  font-display: swap;
  font-style: normal;
  font-weight: 500;
}

@font-face {
  font-family: "Thmanyah Sans";
  src: url("../fonts/thmanyahsans/thmanyahsans-Bold.otf") format("opentype");
  font-display: swap;
  font-style: normal;
  font-weight: 700;
}

@font-face {
  font-family: "Thmanyah Sans";
  src: url("../fonts/thmanyahsans/thmanyahsans-Black.otf") format("opentype");
  font-display: swap;
  font-style: normal;
  font-weight: 900;
}

:root {
  --lammah-font-arabic: "Thmanyah Sans", "Noto Sans Arabic", Tahoma, Arial, sans-serif;
  --lammah-font-features: "ccmp" 1, "locl" 1, "rlig" 1, "liga" 1, "calt" 1, "kern" 1, "mark" 1, "mkmk" 1, "salt" 1, "ss01" 1, "ss03" 1, "ss08" 1;
  --lammah-primary: #006a64;
  --lammah-primary-soft: #81d8d0;
  --lammah-primary-fixed: #9bf2ea;
  --lammah-ink: #131b2e;
  --lammah-muted: #3e4947;
  --lammah-outline: #bdc9c7;
  --lammah-silver: #c0c0c0;
  --lammah-platinum: #e5e4e2;
  --lammah-surface: #f8fafa;
  --lammah-card: #ffffff;
  --lammah-danger: #ba1a1a;
  --lammah-radius: 12px;
  --lammah-radius-lg: 24px;
  --lammah-shadow: 0 20px 40px rgba(15, 23, 42, 0.04);
}

.lammah-theme {
  font-family: var(--lammah-font-arabic);
  background:
    radial-gradient(circle at 10% 0%, rgba(129, 216, 208, 0.16), transparent 34rem),
    linear-gradient(180deg, #ffffff 0%, var(--lammah-surface) 100%);
  min-height: 100vh;
}

body,
button,
input,
select,
textarea,
.lammah-theme,
.lammah-theme *:not(.material-symbols-outlined),
.lammah-static-template *:not(.material-symbols-outlined),
[class*="font-headline"],
[class*="font-body"],
[class*="font-label"],
[class*="font-display"] {
  font-family: var(--lammah-font-arabic) !important;
  font-feature-settings: var(--lammah-font-features);
  font-kerning: normal;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

.material-symbols-outlined {
  font-family: "Material Symbols Outlined" !important;
}

.lammah-thmanyah,
.lammah-kashida,
.lammah-public-invitation {
  font-family: var(--lammah-font-arabic) !important;
  font-feature-settings: var(--lammah-font-features);
}

.lammah-kashida {
  text-align: justify;
  text-justify: kashida;
  -ms-text-kashida-space: 20%;
}

.lammah-fatha-1 {
  font-feature-settings: "ccmp" 1, "rlig" 1, "liga" 1, "calt" 1, "kern" 1, "mark" 1, "mkmk" 1, "salt" 1, "ss01" 1, "ss03" 1, "ss08" 1;
}

.lammah-fatha-2 {
  font-feature-settings: "ccmp" 1, "rlig" 1, "liga" 1, "calt" 1, "kern" 1, "mark" 1, "mkmk" 1, "salt" 1, "ss01" 1, "ss04" 1, "ss08" 1;
}

.lammah-fatha-3 {
  font-feature-settings: "ccmp" 1, "rlig" 1, "liga" 1, "calt" 1, "kern" 1, "mark" 1, "mkmk" 1, "salt" 1, "ss01" 1, "ss05" 1, "ss08" 1;
}

.lammah-fatha-4 {
  font-feature-settings: "ccmp" 1, "rlig" 1, "liga" 1, "calt" 1, "kern" 1, "mark" 1, "mkmk" 1, "salt" 1, "ss01" 1, "ss06" 1, "ss08" 1;
}

.lammah-fatha-5 {
  font-feature-settings: "ccmp" 1, "rlig" 1, "liga" 1, "calt" 1, "kern" 1, "mark" 1, "mkmk" 1, "salt" 1, "ss01" 1, "ss07" 1, "ss08" 1;
}

.lammah-site-header,
.lammah-site-footer {
  align-items: center;
  background: rgba(248, 250, 250, 0.82);
  backdrop-filter: blur(12px);
  border-color: rgba(189, 201, 199, 0.6);
  display: flex;
  gap: 24px;
  justify-content: space-between;
  padding: 18px clamp(16px, 4vw, 48px);
}

.lammah-site-header {
  border-bottom: 1px solid rgba(189, 201, 199, 0.6);
  position: sticky;
  top: 0;
  z-index: 50;
}

.lammah-brand {
  color: var(--lammah-primary);
  font-size: 24px;
  font-weight: 800;
  text-decoration: none;
}

.lammah-site-nav ul,
.lammah-site-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.lammah-site-nav a,
.lammah-site-footer a {
  color: var(--lammah-muted);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.lammah-page-wrap {
  margin: 0 auto;
  max-width: 1120px;
  padding: clamp(32px, 6vw, 80px) 16px;
}

.lammah-content-card,
.lammah-app-content {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--lammah-platinum);
  border-radius: var(--lammah-radius-lg);
  box-shadow: var(--lammah-shadow);
  color: var(--lammah-ink);
  padding: clamp(24px, 5vw, 48px);
}

.lammah-content-card h1,
.lammah-app-content h1 {
  color: var(--lammah-ink);
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.25;
  margin: 0 0 24px;
}

.lammah-entry-content {
  color: var(--lammah-muted);
  font-size: 17px;
  line-height: 1.8;
}

.lammah-button,
.lammah-button-primary,
.lammah-plugin button,
.lammah-plugin input[type="submit"] {
  align-items: center;
  background: var(--lammah-primary-soft);
  border: 0;
  border-radius: var(--lammah-radius);
  color: #00201e;
  cursor: pointer;
  display: inline-flex;
  font-weight: 800;
  gap: 8px;
  justify-content: center;
  min-height: 44px;
  padding: 12px 20px;
  text-decoration: none;
  transition: filter 0.2s ease, transform 0.2s ease;
}

.lammah-button:hover,
.lammah-button-primary:hover,
.lammah-plugin button:hover,
.lammah-plugin input[type="submit"]:hover {
  filter: brightness(1.03);
  transform: translateY(-1px);
}

.lammah-attribution {
  color: var(--lammah-silver);
  font-size: 13px;
  font-weight: 600;
  margin: 0;
}

.lammah-app-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: calc(100vh - 78px);
}

.lammah-app-sidebar {
  background: #ffffff;
  border-left: 1px solid var(--lammah-platinum);
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 28px 20px;
}

.lammah-app-logo {
  color: var(--lammah-primary);
  font-size: 26px;
  font-weight: 800;
}

.lammah-app-sidebar nav {
  display: grid;
  gap: 8px;
}

.lammah-app-sidebar a {
  border-radius: var(--lammah-radius);
  color: var(--lammah-muted);
  font-weight: 700;
  padding: 12px 14px;
  text-decoration: none;
}

.lammah-app-sidebar a:hover {
  background: #f2f3ff;
  color: var(--lammah-primary);
}

.lammah-app-content {
  border-radius: 0;
  box-shadow: none;
  min-height: 100%;
}

.lammah-plugin {
  color: var(--lammah-ink);
}

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

.lammah-stat,
.lammah-panel,
.lammah-table-wrap,
.lammah-form {
  background: #ffffff;
  border: 1px solid var(--lammah-platinum);
  border-radius: var(--lammah-radius);
  padding: 20px;
}

.lammah-stat strong {
  color: var(--lammah-primary);
  display: block;
  font-size: 32px;
  line-height: 1.2;
}

.lammah-form {
  display: grid;
  gap: 16px;
}

.lammah-form label {
  color: var(--lammah-ink);
  display: grid;
  font-size: 14px;
  font-weight: 700;
  gap: 8px;
}

.lammah-form input,
.lammah-form select,
.lammah-form textarea {
  background: #ffffff;
  border: 1px solid var(--lammah-outline);
  border-radius: var(--lammah-radius);
  color: var(--lammah-ink);
  font: inherit;
  min-height: 44px;
  padding: 10px 12px;
  width: 100%;
}

.lammah-form textarea {
  min-height: 120px;
}

.lammah-form input:focus,
.lammah-form select:focus,
.lammah-form textarea:focus {
  border-color: var(--lammah-primary-soft);
  box-shadow: 0 0 0 4px rgba(129, 216, 208, 0.14);
  outline: none;
}

.lammah-table {
  border-collapse: collapse;
  width: 100%;
}

.lammah-table th,
.lammah-table td {
  border-bottom: 1px solid var(--lammah-platinum);
  padding: 12px;
  text-align: right;
}

.lammah-badge {
  background: rgba(129, 216, 208, 0.16);
  border-radius: 999px;
  color: var(--lammah-primary);
  display: inline-flex;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 10px;
}

.lammah-notice {
  background: rgba(129, 216, 208, 0.16);
  border: 1px solid rgba(129, 216, 208, 0.4);
  border-radius: var(--lammah-radius);
  color: var(--lammah-primary);
  font-weight: 700;
  margin: 0 0 18px;
  padding: 12px 16px;
}

.lammah-public-invitation {
  background:
    linear-gradient(rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.96)),
    radial-gradient(circle at top, rgba(129, 216, 208, 0.24), transparent 28rem);
  border: 1px solid var(--lammah-platinum);
  border-radius: 28px;
  box-shadow: var(--lammah-shadow);
  margin: 0 auto;
  max-width: 720px;
  overflow: hidden;
  padding: clamp(24px, 6vw, 56px);
  text-align: center;
}

.lammah-public-invitation h2 {
  color: var(--lammah-primary);
  font-size: clamp(32px, 7vw, 60px);
  line-height: 1.25;
  margin: 0 0 18px;
}

@media (max-width: 820px) {
  html {
    -webkit-text-size-adjust: 100%;
  }

  body {
    overflow-x: hidden;
  }

  .lammah-site-header,
  .lammah-site-footer {
    align-items: flex-start;
    flex-direction: column;
    padding-left: max(16px, env(safe-area-inset-left));
    padding-right: max(16px, env(safe-area-inset-right));
  }

  .lammah-app-layout {
    grid-template-columns: 1fr;
    min-height: 100vh;
  }

  .lammah-app-sidebar {
    border-bottom: 1px solid var(--lammah-platinum);
    border-left: 0;
    gap: 14px;
    padding: 18px 16px;
  }

  .lammah-app-sidebar nav {
    display: flex;
    gap: 8px;
    margin-inline: -16px;
    overflow-x: auto;
    padding: 0 16px 4px;
    scroll-snap-type: x proximity;
  }

  .lammah-app-sidebar a {
    flex: 0 0 auto;
    scroll-snap-align: start;
    white-space: nowrap;
  }

  .lammah-page-wrap {
    padding: 24px 16px calc(96px + env(safe-area-inset-bottom));
  }

  .lammah-content-card,
  .lammah-app-content,
  .lammah-panel,
  .lammah-form,
  .lammah-table-wrap {
    border-radius: 16px;
    padding: 18px;
  }

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

  .lammah-table-wrap {
    overflow-x: auto;
  }

  .lammah-table {
    min-width: 560px;
  }

  .lammah-public-invitation {
    border-radius: 22px;
    padding: 28px 18px;
  }

  .lammah-mobile-template {
    min-height: 100vh;
    padding-bottom: env(safe-area-inset-bottom);
  }

  .lammah-mobile-template nav.fixed.bottom-0,
  .lammah-mobile-template footer.fixed.bottom-0 {
    padding-bottom: max(12px, env(safe-area-inset-bottom));
  }

  .lammah-mobile-template input,
  .lammah-mobile-template select,
  .lammah-mobile-template textarea,
  .lammah-mobile-template button {
    font-size: 16px;
  }

  .lammah-mobile-template h1,
  .lammah-mobile-template h2,
  .lammah-mobile-template h3 {
    text-wrap: balance;
  }
}
