/* Legacy homepage tokens: the iframe has its own document and theme. */
:root {
  --usta-home-primary: oklch(0.45 0.24 289);
  --usta-home-primary-hover: oklch(0.4 0.22 289);
  --usta-home-border: oklch(0.75 0.14 294);
  --usta-home-surface: oklch(0.978 0.011 294);
  --usta-home-plumbing: oklch(0.64 0.24 20);
  --usta-home-electrical: oklch(0.68 0.15 86);
  --usta-home-paint: oklch(0.58 0.24 261);
  --usta-home-wood: oklch(0.5 0.12 48);
  --usta-home-climate: oklch(0.56 0.18 146);
  --usta-home-other: oklch(0.55 0.24 299);
}

/* Only the card's interior changes; the sidebar and feed keep their layout. */
.usta-home { display: block; container-type: inline-size; min-width: 0; padding: 10px; border: 1px solid var(--usta-home-border); border-radius: 12px; background: var(--usta-home-surface); letter-spacing: 0; overflow: hidden; }
.usta-home-banner { display: block; position: relative; isolation: isolate; aspect-ratio: 1.65; min-height: 144px; max-height: 220px; border-radius: 7px; overflow: hidden; }
.usta-home-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; z-index: -1; }
.usta-home-copy { display: block; width: 65%; padding: 9px 0 9px 4px; }
.usta-home-kicker { display: inline-block; background: var(--usta-home-primary); color: var(--paper); padding: 2px 6px; border-radius: 4px; font-size: 13px; font-weight: 900; line-height: 1.4; }
.usta-home .usta-home-title { color: var(--ink); font-size: 23px; font-weight: 950; line-height: 1.15; margin: 5px 0 6px; letter-spacing: 0; white-space: nowrap; }
.usta-home-title span { color: var(--usta-home-primary); }
.usta-home-copy strong { display: block; max-width: 110px; font-size: 10px; line-height: 1.4; }
.usta-home-copy p { max-width: 105px; font-size: 9px; line-height: 1.5; margin: 4px 0 0; color: var(--ink); }
.usta-home-categories { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px 4px; margin: 12px 0; }
.usta-home-category { display: flex; flex-direction: column; align-items: center; gap: 5px; min-width: 0; text-align: center; font-size: 9px; font-weight: 750; line-height: 1.3; }
.usta-home-category-icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 7px; color: var(--paper); transition: transform .18s ease; }
.usta-home-category-icon svg { width: 21px; height: 21px; }
.usta-home-plumbing { background: var(--usta-home-plumbing); }
.usta-home-electrical { background: var(--usta-home-electrical); }
.usta-home-paint { background: var(--usta-home-paint); }
.usta-home-wood { background: var(--usta-home-wood); }
.usta-home-climate { background: var(--usta-home-climate); }
.usta-home-other { background: var(--usta-home-other); }
.usta-home-category:hover .usta-home-category-icon { transform: translateY(-2px); }
.usta-home .usta-home-browse { display: flex; width: 100%; min-height: 36px; padding: 8px 6px; border-radius: 7px; background: var(--usta-home-primary); color: var(--paper); box-shadow: none; font-size: 11px; letter-spacing: 0; }
.usta-home-browse svg { flex-shrink: 0; width: 17px; height: 17px; }
.usta-home .usta-home-browse:hover { background: var(--usta-home-primary-hover); }
.usta-home .usta-home-register { display: flex; width: 100%; min-height: 34px; margin-top: 7px; padding: 7px 6px; border: 1.5px solid var(--usta-home-primary); border-radius: 7px; background: transparent; color: var(--usta-home-primary); font-size: 11px; font-weight: 800; letter-spacing: 0; box-shadow: none; }
.usta-home-register svg { flex-shrink: 0; width: 16px; height: 16px; }
.usta-home .usta-home-register:hover { background: var(--usta-home-primary); color: var(--paper); }
.usta-home a:focus-visible { outline: 2px solid var(--usta-home-primary); outline-offset: 2px; }

@container (min-width: 300px) {
  .usta-home-copy { padding: 12px 0 12px 7px; }
  .usta-home-kicker { font-size: 16px; }
  .usta-home .usta-home-title { font-size: 30px; }
  .usta-home-copy strong { max-width: 165px; font-size: 12px; }
  .usta-home-copy p { max-width: 160px; font-size: 10px; }
  .usta-home-categories { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
  .usta-home-category { font-size: 8px; }
  .usta-home .usta-home-browse { font-size: 12px; min-height: 40px; }
}

@media(max-width:1040px) {
  .usta-home { grid-column: 1; grid-row: 3; }
}
@media(max-width:690px) {
  .usta-home { grid-column: 1; grid-row: auto; }
}
@media(prefers-reduced-motion:reduce) {
  .usta-home a, .usta-home-category-icon { transition: none; }
  .usta-home a:hover, .usta-home-category:hover .usta-home-category-icon { transform: none; }
}

/* Yeni bağlantı eklenince menü hesap düğmeleriyle çakışmasın. */
@media (min-width: 901px) {
  .navlinks { min-width: 0; flex-wrap: wrap; justify-content: center; gap: 8px 16px; }
  .navlinks a { white-space: nowrap; }
}
