.mg-page {
  --mg-max: 1120px;
  --mg-gutter: 1.5rem;
  --mg-surface: var(--surface, #fffdf9);
  --mg-surface-2: #f1ece3;
  --mg-ink: var(--text, #1e211d);
  --mg-muted: var(--muted, #6d716b);
  --mg-soft: var(--soft, #a99f92);
  --mg-line: var(--line, rgba(30, 33, 29, 0.1));
  --mg-accent: var(--accent, #394237);
  --mg-accent-soft: #e9eee7;
  --mg-orange: #c9822d;
  --mg-radius-xl: var(--radius-xl, 32px);
  --mg-radius-lg: var(--radius-lg, 24px);
  --mg-radius-md: var(--radius-md, 18px);
  --mg-shadow: var(--shadow-soft, 0 14px 40px rgba(45, 39, 31, 0.07));
  padding-bottom: 72px;
  color: var(--mg-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overflow-x: clip;
}

.mg-page *,
.mg-page *::before,
.mg-page *::after {
  box-sizing: border-box;
}

.mg-page__inner {
  width: min(var(--mg-max), calc(100% - (var(--mg-gutter) * 2)));
  margin-inline: auto;
}

.mg-hero {
  padding: 52px 0 36px;
}

.mg-hero__grid {
  display: grid;
  gap: 28px;
  align-items: center;
}

.mg-hero__kicker {
  margin-bottom: 14px;
  color: var(--mg-soft);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.mg-hero h1 {
  margin: 0;
  font-size: clamp(40px, 8vw, 72px);
  line-height: 0.95;
  letter-spacing: -0.045em;
  max-width: 760px;
}

.mg-hero__lead {
  margin-top: 20px;
  max-width: 640px;
  color: var(--mg-muted);
  font-size: clamp(17px, 2.2vw, 20px);
  line-height: 1.6;
  letter-spacing: -0.02em;
}

.mg-hero__lead > * {
  margin: 0;
}

.mg-hero__lead > * + * {
  margin-top: 14px;
}

.mg-hero__actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 28px;
}

.mg-hero__actions .btn {
  width: 100%;
}

.mg-hero__card {
  padding: 22px;
  border: 1px solid var(--mg-line);
  border-radius: var(--mg-radius-lg);
  background: rgba(255, 253, 249, 0.72);
  backdrop-filter: blur(18px);
  box-shadow: var(--mg-shadow);
}

.mg-hero__card strong {
  display: block;
  font-size: 18px;
  letter-spacing: -0.03em;
  margin-bottom: 8px;
}

.mg-hero__card p {
  margin: 0;
  color: var(--mg-muted);
  font-size: 14px;
  line-height: 1.55;
}

.mg-hero__card .btn {
  width: 100%;
  margin-top: 16px;
}

.mg-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 8px 0 28px;
}

.mg-toolbar__chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid var(--mg-line);
  background: var(--mg-surface);
  color: var(--mg-muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.02em;
  transition: background 180ms ease, color 180ms ease, border-color 180ms ease;
}

.mg-toolbar__chip:hover,
.mg-toolbar__chip.is-active {
  color: var(--mg-ink);
  border-color: rgba(57, 66, 55, 0.22);
  background: var(--mg-accent-soft);
}

.mg-toolbar__chip::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #6f8f72;
}

.mg-categories {
  display: grid;
  gap: 18px;
}

.mg-category {
  border: 1px solid var(--mg-line);
  border-radius: var(--mg-radius-xl);
  background: var(--mg-surface);
  box-shadow: var(--mg-shadow);
  overflow: hidden;
  scroll-margin-top: 96px;
}

.mg-category__head {
  display: grid;
  grid-template-columns: 88px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 22px 22px 18px;
  border-bottom: 1px solid var(--mg-line);
}

.mg-category__thumb {
  width: 88px;
  height: 88px;
  border-radius: 20px;
  overflow: hidden;
  background: var(--mg-surface-2);
  flex-shrink: 0;
}

.mg-category__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mg-category__thumb-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: var(--mg-soft);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.mg-category__copy h2 {
  margin: 0 0 6px;
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.mg-category__copy p {
  margin: 0;
  color: var(--mg-muted);
  font-size: 15px;
  line-height: 1.55;
  letter-spacing: -0.015em;
}

.mg-category__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  font-size: 13px;
  font-weight: 800;
  color: var(--mg-accent);
  letter-spacing: -0.02em;
}

.mg-category__link:hover {
  text-decoration: underline;
}

.mg-category__badge {
  align-self: start;
  justify-self: end;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--mg-accent-soft);
  color: var(--mg-accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.mg-category__steps {
  padding: 8px 14px 14px;
}

.mg-step {
  border-radius: var(--mg-radius-lg);
  background: rgba(247, 244, 239, 0.55);
  margin-top: 8px;
  overflow: hidden;
}

.mg-step:first-child {
  margin-top: 0;
}

.mg-step summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 58px;
  padding: 14px 18px;
  list-style: none;
  cursor: pointer;
  font-size: 16px;
  font-weight: 750;
  letter-spacing: -0.025em;
}

.mg-step summary::-webkit-details-marker {
  display: none;
}

.mg-step__title-wrap {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
}

.mg-step__title-wrap > span:not(.mg-step__icon) {
  min-width: 0;
  overflow-wrap: anywhere;
}

.mg-step__icon {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-grid;
  place-items: center;
  background: var(--mg-surface);
  box-shadow: inset 0 0 0 1px var(--mg-line);
  flex-shrink: 0;
}

.mg-step__icon svg {
  width: 16px;
  height: 16px;
  stroke: var(--mg-accent);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mg-step__icon--video {
  background: #fff1e4;
  box-shadow: inset 0 0 0 1px rgba(201, 130, 45, 0.18);
}

.mg-step__icon--video svg {
  stroke: var(--mg-orange);
  fill: var(--mg-orange);
  stroke-width: 0;
}

.mg-step__toggle {
  position: relative;
  width: 36px;
  height: 36px;
  border-radius: 14px;
  background: var(--mg-surface);
  box-shadow: inset 0 0 0 1px var(--mg-line);
  flex-shrink: 0;
}

.mg-step__toggle::before,
.mg-step__toggle::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 2px;
  border-radius: 999px;
  background: var(--mg-accent);
  transform: translate(-50%, -50%);
  transition: transform 180ms ease, opacity 180ms ease;
}

.mg-step__toggle::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.mg-step[open] .mg-step__toggle::after {
  opacity: 0;
}

.mg-step[open] {
  background: var(--mg-surface);
  box-shadow: inset 0 0 0 1px var(--mg-line);
}

.mg-step__body {
  padding: 0 18px 22px;
}

.mg-step__content {
  color: var(--mg-muted);
  font-size: 15px;
  line-height: 1.65;
  letter-spacing: -0.015em;
  overflow-wrap: anywhere;
}

.mg-step__content > * {
  margin: 0;
}

.mg-step__content > * + * {
  margin-top: 12px;
}

.mg-step__content ol {
  margin: 12px 0 0;
  padding-left: 1.25rem;
}

.mg-step__content ul {
  margin: 12px 0 0;
  padding-left: 1.25rem;
}

.mg-step__content li + li {
  margin-top: 8px;
}

.mg-step__content strong {
  color: var(--mg-ink);
}

.mg-step__media-grid {
  display: grid;
  gap: 14px;
  margin-top: 18px;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
}

.mg-step__figure {
  margin: 0;
  border-radius: var(--mg-radius-md);
  overflow: hidden;
  border: 1px solid var(--mg-line);
  background: #f7f4ef;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.mg-step__figure img {
  width: 100%;
  height: auto;
  display: block;
}

.mg-step__figure figcaption,
.mg-step__caption {
  flex: 1 1 auto;
  padding: 12px 14px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--mg-muted);
  border-top: 1px solid var(--mg-line);
  background: rgba(255, 253, 249, 0.9);
  overflow-wrap: break-word;
  text-wrap: pretty;
}

/* Fenster-Uygunluk: ✓ / ✕ Rozetleri (Plisstek-Stil) */
.mg-compat-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px 5px 5px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.2;
  vertical-align: middle;
  margin-right: 4px;
  white-space: nowrap;
}

.mg-compat-badge__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  flex-shrink: 0;
}

.mg-compat-badge--ok {
  background: #e6f2e9;
  color: #2a5238;
}

.mg-compat-badge--ok .mg-compat-badge__mark {
  background: #3d6b4f;
  color: #fff;
  box-shadow: 0 2px 6px rgba(61, 107, 79, 0.28);
}

.mg-compat-badge--warn {
  background: #fdf4e3;
  color: #7a5418;
}

.mg-compat-badge--warn .mg-compat-badge__mark {
  background: #c9822d;
  color: #fff;
  box-shadow: 0 2px 6px rgba(201, 130, 45, 0.28);
}

.mg-compat-badge--no {
  background: #faecec;
  color: #7a3232;
}

.mg-compat-badge--no .mg-compat-badge__mark {
  background: #b84a4a;
  color: #fff;
  box-shadow: 0 2px 6px rgba(184, 74, 74, 0.28);
}

.mg-step__caption .mg-compat-badge {
  display: inline-flex;
  margin-bottom: 6px;
}

.mg-step__caption strong {
  display: block;
  margin-bottom: 0.35em;
  color: var(--mg-ink);
  font-size: 13px;
  line-height: 1.35;
}

.mg-step__content li .mg-compat-badge {
  margin-right: 8px;
}

.mg-step__diagram-placeholder {
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  padding: 24px;
  text-align: center;
  color: var(--mg-soft);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.02em;
  background:
    linear-gradient(180deg, rgba(255, 253, 249, 0.4), rgba(241, 236, 227, 0.9)),
    repeating-linear-gradient(
      -45deg,
      rgba(57, 66, 55, 0.03),
      rgba(57, 66, 55, 0.03) 8px,
      transparent 8px,
      transparent 16px
    );
}

.mg-step__video {
  margin-top: 18px;
  border-radius: var(--mg-radius-lg);
  overflow: hidden;
  border: 1px solid var(--mg-line);
  background: #1d201c;
}

.mg-step__video video,
.mg-step__video iframe {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
}

.mg-step__video-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  padding: 12px 18px;
  border-radius: 999px;
  background: var(--mg-accent);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.mg-step__video-link:hover {
  transform: translateY(-1px);
}

.mg-step__video-empty {
  margin: 0;
  padding: 28px 24px;
  border-radius: var(--mg-radius-lg);
  background: var(--mg-surface-2);
  color: var(--mg-muted);
  text-align: center;
  font-size: 15px;
}

.mg-cta {
  margin-top: 34px;
  padding: 28px;
  border-radius: var(--mg-radius-xl);
  display: grid;
  gap: 18px;
  align-items: center;
  background:
    radial-gradient(circle at 100% 0%, rgba(201, 130, 45, 0.14), transparent 38%),
    linear-gradient(135deg, #fffdf8, #efebe1);
  border: 1px solid var(--mg-line);
  box-shadow: var(--mg-shadow);
}

.mg-cta h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1;
  letter-spacing: -0.04em;
}

.mg-cta p {
  margin: 10px 0 0;
  color: var(--mg-muted);
  font-size: 16px;
  line-height: 1.6;
}

.mg-cta__actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mg-cta__actions .btn {
  width: 100%;
}

.mg-global-video {
  margin-top: 34px;
  padding: 24px;
  border-radius: var(--mg-radius-xl);
  background: var(--mg-surface);
  border: 1px solid var(--mg-line);
  box-shadow: var(--mg-shadow);
}

.mg-global-video__head {
  margin-bottom: 18px;
}

.mg-global-video__head h2 {
  margin: 0;
  font-size: clamp(26px, 3.5vw, 36px);
  letter-spacing: -0.04em;
}

.mg-global-video__head p {
  margin: 8px 0 0;
  color: var(--mg-muted);
  font-size: 15px;
}

.mg-global-video__player {
  border-radius: var(--mg-radius-lg);
  overflow: hidden;
  background: #1d201c;
}

.mg-global-video__player video {
  display: block;
  width: 100%;
  height: auto;
}

.mg-tips {
  margin-top: 18px;
  display: grid;
  gap: 12px;
}

.mg-tip {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
  align-items: start;
  padding: 14px 16px;
  border-radius: var(--mg-radius-md);
  background: var(--mg-accent-soft);
}

.mg-tip__mark {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: var(--mg-surface);
  font-size: 13px;
  font-weight: 900;
  color: var(--mg-accent);
  box-shadow: inset 0 0 0 1px rgba(57, 66, 55, 0.08);
}

.mg-tip strong {
  display: block;
  font-size: 14px;
  margin-bottom: 4px;
  letter-spacing: -0.02em;
}

.mg-tip span {
  color: var(--mg-muted);
  font-size: 13px;
  line-height: 1.5;
}

@media (min-width: 640px) {
  .mg-hero__actions {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .mg-hero__actions .btn {
    width: auto;
  }

  .mg-hero__card .btn {
    width: auto;
  }

  .mg-cta {
    grid-template-columns: 1fr auto;
  }

  .mg-cta__actions {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .mg-cta__actions .btn {
    width: auto;
  }
}

@media (min-width: 768px) {
  .mg-step__media-grid--two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 768px) and (max-width: 959px) {
  /* Detail steps (2 images): full-width captions avoid cramped line breaks */
  .mg-step__media-grid--pair.mg-step__media-grid--two {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (min-width: 860px) {
  .mg-hero {
    padding: 68px 0 42px;
  }

  .mg-hero__grid {
    grid-template-columns: 1.05fr 0.95fr;
  }

  .mg-category__head {
    padding: 24px 26px 20px;
  }

  .mg-category__steps {
    padding: 10px 18px 18px;
  }
}

@media (max-width: 859px) {
  .mg-category__head {
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 14px;
    padding: 18px 18px 16px;
  }

  .mg-category__badge {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .mg-category__thumb {
    width: 72px;
    height: 72px;
  }

  .mg-category__copy {
    min-width: 0;
  }
}

@media (max-width: 639px) {
  .mg-page {
    --mg-gutter: 1rem;
    padding-bottom: 48px;
  }

  .mg-hero {
    padding: 32px 0 24px;
  }

  .mg-hero h1 {
    font-size: clamp(32px, 9vw, 40px);
    line-height: 1;
  }

  .mg-hero__lead {
    margin-top: 16px;
    font-size: 16px;
  }

  .mg-hero__card {
    padding: 18px;
  }

  .mg-category {
    border-radius: var(--mg-radius-lg);
    scroll-margin-top: 80px;
  }

  .mg-category__steps {
    padding: 6px 10px 12px;
  }

  .mg-step summary {
    min-height: 52px;
    padding: 12px 14px;
    font-size: 15px;
    gap: 12px;
  }

  .mg-step__body {
    padding: 0 14px 18px;
  }

  .mg-step__icon {
    width: 30px;
    height: 30px;
    border-radius: 10px;
  }

  .mg-step__toggle {
    width: 32px;
    height: 32px;
    border-radius: 12px;
  }

  .mg-cta {
    margin-top: 28px;
    padding: 20px 16px;
    border-radius: var(--mg-radius-lg);
  }

  .mg-global-video {
    margin-top: 28px;
    padding: 16px;
    border-radius: var(--mg-radius-lg);
  }

  .mg-tips {
    margin-top: 14px;
  }

  .mg-toolbar {
    flex-wrap: nowrap;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
  }

  .mg-toolbar::-webkit-scrollbar {
    display: none;
  }

  .mg-toolbar__chip {
    flex-shrink: 0;
  }
}

@media (max-width: 479px) {
  .mg-category__head {
    grid-template-columns: minmax(0, 1fr);
  }

  .mg-category__thumb {
    width: 64px;
    height: 64px;
  }
}
