/* Lopullinen CSS: Top10 compact + gallerian kuvapino */

:root {
  --bg: #f6f2ef;
  --surface: #ffffff;
  --surface-alt: #f1ebe5;
  --text: #111217;
  --muted: #636771;
  --border: rgba(17, 18, 23, 0.1);
  --shadow: 0 20px 50px rgba(17, 18, 23, 0.08);
  --accent: #f56e1d;
  --accent-dark: #d34d0d;
  --accent-soft: rgba(245, 110, 29, 0.12);
  --blue: #2f86dd;
  --yellow: #f2ca19;
  --black: #111217;
  --max: 1240px;
  --radius: 26px;
  --header-h: 82px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  font-family: "Outfit", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
}

img {
  max-width: 100%;
  display: block;
}

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

button,
input {
  font: inherit;
}

.container {
  width: min(calc(100% - 2rem), var(--max));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(16px);
  background: rgba(11, 13, 17, 0.82);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-wrap {
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  color: #fff;
}

.brand img {
  width: 58px;
  height: 58px;
  object-fit: contain;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  padding: 0.2rem;
}

.brand span {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand strong {
  font-size: 1.12rem;
  letter-spacing: 0.03em;
}

.brand small {
  font-size: 0.92rem;
  opacity: 0.86;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.main-nav a {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.main-nav a:hover,
.main-nav a:focus-visible {
  color: var(--yellow);
}

.nav-toggle {
  display: none;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 14px;
  background: transparent;
  padding: 0;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 5px auto;
  border-radius: 99px;
  background: #fff;
}

.hero {
  position: relative;
  min-height: calc(64vh - var(--header-h));
  overflow: hidden;
  color: #fff;
  isolation: isolate;
}

.hero-slides,
.hero-slide,
.hero-overlay,
.hero-watermark {
  position: absolute;
  inset: 0;
}

.hero-slide {
  background-position: center;
  background-size: cover;
  opacity: 0;
  transform: scale(1.03);
  transition: opacity 1s ease, transform 5s ease;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
}

.hero-overlay {
  background:
    linear-gradient(100deg, rgba(11, 13, 17, 0.88) 0%, rgba(11, 13, 17, 0.72) 36%, rgba(11, 13, 17, 0.48) 100%),
    radial-gradient(circle at 75% 22%, rgba(47, 134, 221, 0.2), transparent 24%),
    radial-gradient(circle at 18% 30%, rgba(245, 110, 29, 0.14), transparent 24%);
}

.hero-watermark {
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  opacity: 0.09;
  z-index: -1;
}

.hero-watermark img {
  width: min(68vw, 900px);
  filter: grayscale(1) contrast(1.2);
}

.hero-grid {
  position: relative;
  z-index: 2;
  min-height: calc(84vh - var(--header-h));
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2.2rem;
  align-items: center;
  padding: 3.3rem 0 4rem;
}

.hero-copy h1,
.section-heading h2 {
  margin: 0;
  line-height: 1.02;
}

.hero-copy h1 {
  font-size: clamp(2.8rem, 6vw, 5.45rem);
  max-width: 11ch;
}

.hero-copy p {
  max-width: 62ch;
  margin: 1.25rem 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 1.08rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  padding: 0.46rem 0.9rem;
  border-radius: 999px;
  font-size: 0.92rem;
  letter-spacing: 0.02em;
  margin-bottom: 1rem;
  border: 1px solid transparent;
}

.hero .eyebrow {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.14);
}

.eyebrow-light {
  background: rgba(245, 110, 29, 0.08);
  color: var(--accent-dark);
}

.eyebrow-dark {
  background: rgba(17, 18, 23, 0.06);
  color: var(--black);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0.95rem 1.35rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.btn:hover,
.btn:focus-visible {
  transform: translateY(-1px);
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  box-shadow: 0 16px 32px rgba(211, 77, 13, 0.24);
}

.btn-secondary {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.08);
}

.btn-small {
  min-height: 42px;
  padding: 0.72rem 1rem;
  font-size: 0.94rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2.4rem;
}

.stat-card,
.surface-card,
.info-card,
.hole-card,
.gallery-card,
.score-card {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.stat-card {
  border-radius: 22px;
  padding: 1rem 1.1rem;
  color: var(--text);
}

.stat-card strong {
  display: block;
  font-size: 1.7rem;
  line-height: 1;
}

.stat-card span {
  color: var(--muted);
  font-size: 0.94rem;
}

.hero-panel {
  border-radius: var(--radius);
  padding: 1.6rem;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: none;
  backdrop-filter: blur(18px);
}

.panel-label,
.form-note,
.meta-text,
.score-meta {
  color: var(--muted);
  font-size: 0.95rem;
}

.hero .panel-label,
.hero .panel-note {
  color: rgba(255, 255, 255, 0.76);
}

.hero-panel h2 {
  margin: 0 0 1rem;
  font-size: 1.8rem;
}

.quick-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.quick-links a {
  display: block;
  padding: 0.95rem 1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
  font-weight: 600;
  transition: background 0.2s ease;
}

.quick-links a:hover,
.quick-links a:focus-visible {
  background: rgba(255, 255, 255, 0.14);
}

.section {
  padding: 5.25rem 0;
}

.section-alt {
  background: var(--surface-alt);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.section-heading h2 {
  font-size: clamp(2rem, 4vw, 3.4rem);
}

.section-heading > p {
  max-width: 48ch;
  color: var(--muted);
}

.two-col {
  align-items: stretch;
  gap: 2rem;
}

.two-col > :first-child {
  flex: 1 1 0;
}

.two-col > form {
  flex: 0 0 min(100%, 480px);
}

#top10 .section-heading.two-col {
  display: block;
}

#top10 .section-heading.two-col > :first-child {
  width: 100%;
  max-width: none;
  margin-bottom: 1.5rem;
}

#top10 .section-heading.two-col > form.score-form {
  display: block;
  width: 100%;
  max-width: none;
  margin: 0 auto;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  padding: 0.18rem 0.42rem;
  border-radius: 9px;
  background: rgba(17, 18, 23, 0.06);
  color: var(--accent-dark);
}

.flash-holder {
  padding-top: 1.25rem;
}

.flash {
  padding: 1rem 1.15rem;
  border-radius: 18px;
  margin-top: 1rem;
  font-weight: 600;
}

.flash-success {
  background: rgba(41, 148, 79, 0.1);
  color: #1f703d;
  border: 1px solid rgba(41, 148, 79, 0.18);
}

.flash-error {
  background: rgba(195, 55, 55, 0.1);
  color: #8b2323;
  border: 1px solid rgba(195, 55, 55, 0.18);
}

.card-grid {
  display: grid;
  gap: 1.3rem;
}

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

.info-card {
  border-radius: 26px;
  padding: 1.45rem;
}

.info-card h3,
.hole-card h3,
.gallery-card h3,
.score-card h3 {
  margin: 0;
}

.card-date {
  display: inline-flex;
  margin-bottom: 0.75rem;
  padding: 0.34rem 0.72rem;
  border-radius: 999px;
  background: rgba(17, 18, 23, 0.06);
  color: var(--muted);
  font-size: 0.92rem;
}

.anchor-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border-radius: 24px;
  padding: 1rem 1.15rem;
  margin-bottom: 1.3rem;
}

.anchor-nav-label {
  font-weight: 700;
}

.anchor-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.anchor-links a,
.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 700;
  background: rgba(245, 110, 29, 0.08);
  color: var(--accent-dark);
}

.chip-dark {
  background: rgba(17, 18, 23, 0.06);
  color: var(--text);
}

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

.hole-card {
  position: relative;
  border-radius: 28px;
  padding: 1.4rem;
}

.hole-card:target {
  outline: 3px solid rgba(47, 134, 221, 0.28);
  outline-offset: 5px;
}

.hole-top {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1rem;
}

.hole-number {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(245, 110, 29, 0.16), rgba(242, 202, 25, 0.18));
  color: var(--accent-dark);
  font-size: 1.2rem;
  font-weight: 800;
  flex-shrink: 0;
}

.hole-card h3 {
  margin-top: 0;
  margin-bottom: 0.45rem;
}

.hole-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 1rem 0 1.1rem;
}

.hole-meta span {
  padding: 0.44rem 0.7rem;
  border-radius: 999px;
  background: rgba(17, 18, 23, 0.06);
  color: var(--muted);
  font-size: 0.92rem;
}

.hole-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hole-links a {
  font-weight: 700;
}

.surface-card,
.upload-form,
.score-form,
.table-wrap {
  border-radius: 30px;
}

.upload-form,
.score-form,
.table-wrap {
  padding: 1.45rem;
}

.upload-form h3,
.score-form h3,
.table-head h3 {
  margin-top: 0;
  margin-bottom: 0.3rem;
}

.upload-form label,
.score-form > label {
  display: block;
  font-weight: 600;
  margin-top: 1rem;
}

.upload-form input[type="text"],
.upload-form input[type="file"],
.score-form input[type="text"] {
  width: 100%;
  margin-top: 0.45rem;
  padding: 0.96rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(17, 18, 23, 0.12);
  background: #fff;
}

#galleryWrap {
  margin-top: 2rem;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.1rem;
}

.gallery-card {
  border-radius: 24px;
  overflow: hidden;
}

.gallery-thumb {
  width: 100%;
  aspect-ratio: 1.25 / 1;
  object-fit: cover;
  background: #ddd;
}

.gallery-content {
  padding: 1rem 1.1rem 1.1rem;
}

.gallery-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
}

.gallery-trigger {
  border: none;
  background: transparent;
  color: var(--accent-dark);
  font-weight: 800;
  cursor: pointer;
  padding: 0;
}

.empty-state {
  padding: 2rem;
  border-radius: 26px;
  background: #fff;
  border: 1px dashed rgba(17, 18, 23, 0.16);
  text-align: center;
}

.form-top {
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  align-items: start;
}

.score-summary {
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
  justify-content: end;
}

.score-total-box {
  min-width: 112px;
  padding: 0.9rem 1rem;
  border-radius: 18px;
  background: rgba(17, 18, 23, 0.05);
  text-align: center;
}

.score-total-highlight {
  background: linear-gradient(135deg, rgba(245, 110, 29, 0.14), rgba(242, 202, 25, 0.18));
}

.score-total-box span {
  display: block;
  font-size: 0.88rem;
  color: var(--muted);
}

.score-total-box strong {
  display: block;
  margin-top: 0.15rem;
  font-size: 1.6rem;
}

.score-table-wrap {
  overflow-x: auto;
  margin: 1.25rem 0 1.5rem;
  padding-bottom: 0.25rem;
}

.score-entry-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0.4rem;
  table-layout: fixed;
}

.result-score-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0.4rem;
  min-width: 1020px;
}

.score-entry-table td,
.result-score-table th,
.result-score-table td {
  text-align: center;
  vertical-align: top;
  border-radius: 18px;
  background: rgba(17, 18, 23, 0.05);
  padding: 0.75rem 0.45rem;
}

.result-score-table th {
  min-width: 96px;
  background: rgba(17, 18, 23, 0.08);
}

.score-entry-table .hole-number-cell,
.result-score-table .hole-number-cell {
  font-weight: 800;
  background: linear-gradient(135deg, rgba(245, 110, 29, 0.14), rgba(242, 202, 25, 0.18));
}

.score-entry-table .score-input-cell {
  min-width: 0;
}

.score-entry-table .score-input-cell.score-under-1,
.result-score-table td.score-under-1 {
  background: rgba(114, 200, 117, 0.28);
}

.score-entry-table .score-input-cell.score-over-1,
.result-score-table td.score-over-1 {
  background: rgba(233, 111, 137, 0.18);
}

.score-entry-table .score-input-cell.score-over-2,
.result-score-table td.score-over-2 {
  background: rgba(220, 64, 49, 0.72);
  color: #fff;
}

.score-entry-table .score-input-cell.score-under-2,
.result-score-table td.score-under-2 {
  background: rgba(24, 122, 66, 0.86);
  color: #fff;
}

.score-entry-table .score-input-cell.score-over-2 .cell-meta,
.score-entry-table .score-input-cell.score-under-2 .cell-meta,
.result-score-table td.score-over-2,
.result-score-table td.score-under-2 {
  color: rgba(255, 255, 255, 0.95);
}

.score-entry-table .score-input-cell.score-under-2 .hole-input,
.score-entry-table .score-input-cell.score-over-2 .hole-input {
  border-color: rgba(255, 255, 255, 0.18);
}

.score-entry-table .score-input-cell.score-under-2 .stepper input,
.score-entry-table .score-input-cell.score-over-2 .stepper input {
  background: rgba(255, 255, 255, 0.96);
  color: #111217;
}


.cell-meta {
  display: block;
  margin-bottom: 0.55rem;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.35;
}

.stepper {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.42rem;
}

.stepper button {
  width: 34px;
  height: 34px;
  border: none;
  border-radius: 12px;
  background: #111217;
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.stepper input {
  width: 52px;
  text-align: center;
  padding: 0.6rem 0.4rem;
  border-radius: 12px;
  border: 1px solid rgba(17, 18, 23, 0.14);
  background: #fff;
  font-weight: 700;
  appearance: textfield;
  -moz-appearance: textfield;
  margin: 0 auto;
  display: block;
}

.stepper input::-webkit-outer-spin-button,
.stepper input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.score-input-cell {
  text-align: center;
}

.table-wrap {
  margin-top: 2rem;
}

.table-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.1rem;
}

.score-list {
  display: grid;
  gap: 1rem;
}

.score-card {
  border-radius: 24px;
  padding: 1.25rem;
}

.score-card-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

.score-rank {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-weight: 800;
  background: linear-gradient(135deg, rgba(245, 110, 29, 0.14), rgba(242, 202, 25, 0.16));
  color: var(--accent-dark);
}

.score-headline {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  min-width: 0;
}

.score-card p {
  margin: 0;
}

.result-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.35rem;
}

.result-summary span {
  display: inline-flex;
  padding: 0.42rem 0.68rem;
  border-radius: 999px;
  background: rgba(17, 18, 23, 0.06);
  color: var(--muted);
  font-size: 0.9rem;
}

.score-mainline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  line-height: 1.45;
}

.score-mainline .score-name {
  font-weight: 800;
  color: var(--text);
}

.score-mainline .score-separator {
  color: var(--muted);
}

.score-mainline .score-date,
.score-mainline .score-throws {
  color: var(--muted);
}

.result-score-table .hole-number-cell {
  min-width: 54px;
}

.result-score-table td {
  font-weight: 700;
}

@media (max-width: 680px) {
  .score-card-header {
    align-items: flex-start;
  }

  .score-value {
    font-size: 1.3rem;
  }

  .score-mainline {
    font-size: 0.98rem;
  }
}


.score-value {
  font-size: 1.55rem;
  font-weight: 800;
}

.relative-under {
  color: #1f8b55;
}

.relative-over {
  color: #bf3d23;
}

.relative-even {
  color: var(--blue);
}

.site-footer {
  color: rgba(255, 255, 255, 0.86);
  background: #101217;
  padding: 2.6rem 0 3rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 1.2rem;
}

.site-footer p {
  color: rgba(255, 255, 255, 0.72);
}

.lightbox {
  width: min(92vw, 1000px);
  border: none;
  border-radius: 28px;
  padding: 1rem;
  background: #0d0f14;
  color: #fff;
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.7);
}

.lightbox img {
  width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 18px;
}

.lightbox p {
  margin: 0.9rem 0 0;
  font-weight: 600;
}

.lightbox-close {
  position: absolute;
  top: 0.75rem;
  right: 0.8rem;
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 1.8rem;
  cursor: pointer;
}

@media (max-width: 1100px) {
  .hero {
    min-height: auto;
  }

  .hero-grid,
  .section-heading.two-col,
  .footer-grid,
  .news-grid,
  .course-grid,
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .section-heading {
    align-items: start;
    flex-direction: column;
  }

  .hero-grid {
    min-height: auto;
    padding: 3.25rem 0 4rem;
  }

  .hero-panel {
    max-width: 620px;
  }

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

@media (max-width: 820px) {
  .nav-toggle {
    display: inline-block;
  }

  .main-nav {
    position: absolute;
    top: calc(100% + 10px);
    right: 1rem;
    left: 1rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    border-radius: 22px;
    background: rgba(11, 13, 17, 0.98);
    box-shadow: 0 24px 40px rgba(0, 0, 0, 0.26);
  }

  .main-nav.is-open {
    display: flex;
  }

  .hero-copy h1 {
    max-width: 100%;
  }

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

  .form-top,
  .anchor-nav {
    flex-direction: column;
    align-items: stretch;
  }

  .score-summary {
    justify-content: start;
  }

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

  .site-footer {
    padding-bottom: 2.4rem;
  }
}

@media (max-width: 580px) {
  .container {
    width: min(calc(100% - 1.2rem), var(--max));
  }

  .section {
    padding: 4rem 0;
  }

  .hero-grid {
    padding: 2.8rem 0 3.5rem;
  }

  .hero-stats,
  .quick-links,
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .anchor-links {
    gap: 0.45rem;
  }

  .anchor-links a,
  .chip {
    font-size: 0.88rem;
  }

  .score-total-box {
    min-width: 96px;
  }

  .score-card-header {
    flex-direction: column;
    align-items: start;
  }
}

/* Top10 list uses full container width with neat margins */
#top10 > .container > .table-wrap {
  width: 100%;
  max-width: none;
  margin: 2rem 0 0;
}

#top10 > .container > .table-wrap .table-head,
#top10 > .container > .table-wrap .score-list {
  width: 100%;
  max-width: none;
}


/* Compact Top10 result grid */
#top10 .score-list {
  gap: 0.85rem;
}

#top10 .score-card {
  padding: 1rem;
  border-radius: 20px;
}

#top10 .score-card-header {
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 0.75rem;
}

#top10 .score-headline {
  flex: 1 1 auto;
  min-width: 0;
}

#top10 .score-mainline {
  gap: 0.35rem;
  row-gap: 0.15rem;
}

#top10 .score-rank {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  font-size: 1rem;
  flex-shrink: 0;
}

#top10 .score-value {
  white-space: nowrap;
  font-size: 1.3rem;
  line-height: 1;
}

.compact-score-wrap {
  margin-top: 0.15rem;
}

.compact-score-row {
  display: grid;
  grid-template-columns: repeat(18, minmax(0, 1fr));
  gap: 2px;
}

.compact-score-row + .compact-score-row {
  margin-top: 2px;
}

.compact-score-cell {
  min-width: 0;
  text-align: center;
  border-radius: 7px;
  padding: 0.52rem 0.12rem;
  background: rgba(17, 18, 23, 0.05);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.compact-score-cell.is-hole {
  font-weight: 800;
  background: linear-gradient(135deg, rgba(245, 110, 29, 0.14), rgba(242, 202, 25, 0.18));
  color: var(--text);
}

.compact-score-cell.score-under-1 {
  background: rgba(114, 200, 117, 0.28);
}

.compact-score-cell.score-over-1 {
  background: rgba(233, 111, 137, 0.18);
}

.compact-score-cell.score-over-2 {
  background: rgba(220, 64, 49, 0.72);
  color: #fff;
}

.compact-score-cell.score-under-2 {
  background: rgba(24, 122, 66, 0.86);
  color: #fff;
}

@media (max-width: 820px) {
  #top10 .score-card {
    padding: 0.9rem;
    border-radius: 18px;
  }

  #top10 .score-value {
    font-size: 1.15rem;
  }

  .compact-score-cell {
    padding: 0.42rem 0.08rem;
    font-size: 0.82rem;
    border-radius: 6px;
  }
}

@media (max-width: 580px) {
  #top10 .score-card {
    padding: 0.8rem;
  }

  #top10 .score-card-header {
    flex-direction: column;
    align-items: stretch;
    gap: 0.6rem;
  }

  #top10 .score-headline {
    width: 100%;
  }

  #top10 .score-mainline {
    font-size: 0.92rem;
  }

  #top10 .score-value {
    align-self: flex-end;
    font-size: 1.05rem;
  }

  .compact-score-row {
    gap: 1px;
  }

  .compact-score-row + .compact-score-row {
    margin-top: 1px;
  }

  .compact-score-cell {
    padding: 0.36rem 0.04rem;
    font-size: 0.72rem;
    border-radius: 5px;
  }
}

/* ===== Kuvapino-gallerian lisÃƒÂ¤ykset ===== */

/* Galleria: 3 uusinta + kuvapino */
.gallery-showcase {
  display: grid;
  gap: 1.3rem;
}

.gallery-latest-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.1rem;
}

.gallery-card-latest {
  height: 100%;
}

.gallery-stack-panel {
  border-radius: 28px;
  padding: 1.2rem;
}

.gallery-stack-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.gallery-open-top {
  flex-shrink: 0;
  border: none;
  border-radius: 999px;
  padding: 0.8rem 1rem;
  background: rgba(245, 110, 29, 0.1);
  color: var(--accent-dark);
  font-weight: 800;
  cursor: pointer;
}

.gallery-stack-stage {
  position: relative;
  width: 100%;
  min-height: clamp(360px, 58vw, 660px);
  overflow: visible;
  padding-top: 0.35rem;
}

.gallery-stack-card {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 1px solid rgba(17, 18, 23, 0.12);
  border-radius: 28px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 18px 40px rgba(17, 18, 23, 0.12);
  transform: translateY(calc(var(--stack-index, 0) * 14px)) rotate(var(--stack-rotation, 0deg));
  transform-origin: center center;
  z-index: calc(30 - var(--stack-index, 0));
  pointer-events: none;
  transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.gallery-stack-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #ddd;
}

.gallery-stack-card.is-top {
  pointer-events: auto;
  cursor: pointer;
  box-shadow: 0 24px 48px rgba(17, 18, 23, 0.2);
}

.gallery-stack-card.is-top:hover {
  transform: translateY(calc(var(--stack-index, 0) * 14px - 3px)) rotate(var(--stack-rotation, 0deg));
}

.gallery-stack-overlay {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.9rem 1rem;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(17, 18, 23, 0.08), rgba(17, 18, 23, 0.72));
  color: #fff;
  text-align: left;
}

.gallery-stack-overlay strong {
  font-size: 1.02rem;
}

.gallery-stack-overlay small {
  font-size: 0.88rem;
  opacity: 0.9;
}

@media (max-width: 980px) {
  .gallery-latest-grid {
    grid-template-columns: 1fr;
  }

  .gallery-stack-header {
    flex-direction: column;
    align-items: stretch;
  }
}

@media (max-width: 680px) {
  .gallery-stack-panel {
    padding: 0.9rem;
  }

  .gallery-stack-stage {
    min-height: min(72svh, 112vw);
  }

  .gallery-stack-card {
    border-radius: 24px;
  }

  .gallery-stack-overlay {
    left: 0.7rem;
    right: 0.7rem;
    bottom: 0.7rem;
    padding: 0.8rem 0.9rem;
  }

  .gallery-open-top {
    width: 100%;
  }
}



/* Kuvapino: sama sisÃƒÂ¤ltÃƒÂ¶tyyli kuin kolmessa uusimmassa kuvassa */
.gallery-stack-card {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.gallery-stack-image-wrap {
  flex: 1 1 auto;
  min-height: 0;
}

.gallery-stack-content {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.9rem;
  padding: 1rem 1.05rem;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  box-shadow: 0 12px 28px rgba(17, 18, 23, 0.12);
}

.gallery-stack-text {
  min-width: 0;
}

.gallery-stack-content h3 {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.2;
}

.gallery-stack-content .meta-text {
  margin: 0.35rem 0 0;
}

.gallery-stack-content .gallery-actions {
  margin-left: auto;
  flex-shrink: 0;
}

.gallery-stack-content .gallery-trigger {
  border: none;
  border-radius: 999px;
  padding: 0.8rem 1rem;
  background: rgba(245, 110, 29, 0.1);
  color: var(--accent-dark);
  font-weight: 800;
  cursor: pointer;
}

.gallery-stack-content .gallery-trigger:hover,
.gallery-stack-content .gallery-trigger:focus-visible {
  background: rgba(245, 110, 29, 0.18);
}

.gallery-stack-card.is-top {
  outline: none;
}

.gallery-stack-card.is-top:focus-visible {
  box-shadow: 0 0 0 3px rgba(47, 134, 221, 0.22), 0 24px 48px rgba(17, 18, 23, 0.2);
}

@media (max-width: 680px) {
  .gallery-stack-content {
    left: 0.7rem;
    right: 0.7rem;
    bottom: 0.7rem;
    flex-direction: column;
    align-items: stretch;
    padding: 0.9rem;
  }

  .gallery-stack-content .gallery-actions {
    margin-left: 0;
  }

  .gallery-stack-content .gallery-trigger {
    width: 100%;
  }
}

/* Kuvapino: levÃƒÂ¤llÃƒÂ¤ÃƒÂ¤n pÃƒÂ¶ydÃƒÂ¤llÃƒÂ¤ -hienosÃƒÂ¤ÃƒÂ¤tÃƒÂ¶ */
.gallery-stack-stage {
  min-height: clamp(380px, 60vw, 700px);
  perspective: 1400px;
}

.gallery-stack-card {
  left: 50%;
  right: auto;
  width: min(100%, 780px);
  height: 100%;
  border-radius: 24px;
  border: 1px solid rgba(17, 18, 23, 0.1);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.98), rgba(255,255,255,0.96));
  box-shadow:
    0 24px 50px rgba(17, 18, 23, 0.14),
    0 6px 18px rgba(17, 18, 23, 0.08);
  transform-origin: center 88%;
  transform:
    translate(
      calc(-50% + var(--pile-x, 0px)),
      calc(var(--stack-index, 0) * 14px + var(--pile-y, 0px))
    )
    rotate(var(--pile-rot, 0deg));
}

.gallery-stack-card:nth-child(1) { --pile-x: 0px;   --pile-y: 0px;  --pile-rot: -4.5deg; }
.gallery-stack-card:nth-child(2) { --pile-x: 46px;  --pile-y: 8px;  --pile-rot: 5deg; }
.gallery-stack-card:nth-child(3) { --pile-x: -42px; --pile-y: 16px; --pile-rot: -2.6deg; }
.gallery-stack-card:nth-child(4) { --pile-x: 68px;  --pile-y: 22px; --pile-rot: 7deg; }
.gallery-stack-card:nth-child(5) { --pile-x: -70px; --pile-y: 28px; --pile-rot: -6deg; }
.gallery-stack-card:nth-child(6) { --pile-x: 28px;  --pile-y: 34px; --pile-rot: 2.2deg; }
.gallery-stack-card:nth-child(7) { --pile-x: -24px; --pile-y: 40px; --pile-rot: -1.4deg; }

.gallery-stack-card::before {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  pointer-events: none;
  z-index: 1;
}

.gallery-stack-card img {
  transform: scale(1.01);
}

.gallery-stack-card.is-top {
  box-shadow:
    0 28px 56px rgba(17, 18, 23, 0.18),
    0 10px 26px rgba(17, 18, 23, 0.1);
}

.gallery-stack-card.is-top:hover {
  transform:
    translate(
      calc(-50% + var(--pile-x, 0px)),
      calc(var(--stack-index, 0) * 14px + var(--pile-y, 0px) - 4px)
    )
    rotate(var(--pile-rot, 0deg))
    scale(1.01);
}

.gallery-stack-content {
  left: 1.1rem;
  right: 1.1rem;
  bottom: 1.1rem;
  border-radius: 20px;
}

@media (max-width: 980px) {
  .gallery-stack-card {
    width: min(100%, 92vw);
  }

  .gallery-stack-card:nth-child(1) { --pile-x: 0px;   --pile-y: 0px;  --pile-rot: -3.6deg; }
  .gallery-stack-card:nth-child(2) { --pile-x: 24px;  --pile-y: 7px;  --pile-rot: 4deg; }
  .gallery-stack-card:nth-child(3) { --pile-x: -22px; --pile-y: 14px; --pile-rot: -2.2deg; }
  .gallery-stack-card:nth-child(4) { --pile-x: 30px;  --pile-y: 20px; --pile-rot: 5deg; }
  .gallery-stack-card:nth-child(5) { --pile-x: -32px; --pile-y: 25px; --pile-rot: -4.5deg; }
  .gallery-stack-card:nth-child(6) { --pile-x: 14px;  --pile-y: 30px; --pile-rot: 1.8deg; }
  .gallery-stack-card:nth-child(7) { --pile-x: -12px; --pile-y: 35px; --pile-rot: -1deg; }
}

@media (max-width: 680px) {
  .gallery-stack-stage {
    min-height: min(76svh, 116vw);
  }

  .gallery-stack-card {
    width: 100%;
    border-radius: 22px;
    transform:
      translate(
        calc(-50% + var(--pile-x, 0px)),
        calc(var(--stack-index, 0) * 12px + var(--pile-y, 0px))
      )
      rotate(var(--pile-rot, 0deg));
  }

  .gallery-stack-card:nth-child(1) { --pile-x: 0px;  --pile-y: 0px;  --pile-rot: -2.8deg; }
  .gallery-stack-card:nth-child(2) { --pile-x: 10px; --pile-y: 6px;  --pile-rot: 3deg; }
  .gallery-stack-card:nth-child(3) { --pile-x: -10px; --pile-y: 12px; --pile-rot: -1.8deg; }
  .gallery-stack-card:nth-child(4) { --pile-x: 14px; --pile-y: 16px; --pile-rot: 4deg; }
  .gallery-stack-card:nth-child(5) { --pile-x: -14px; --pile-y: 20px; --pile-rot: -3.2deg; }
  .gallery-stack-card:nth-child(6) { --pile-x: 6px; --pile-y: 24px; --pile-rot: 1.3deg; }
  .gallery-stack-card:nth-child(7) { --pile-x: -6px; --pile-y: 28px; --pile-rot: -0.8deg; }

  .gallery-stack-card.is-top:hover {
    transform:
      translate(
        calc(-50% + var(--pile-x, 0px)),
        calc(var(--stack-index, 0) * 12px + var(--pile-y, 0px))
      )
      rotate(var(--pile-rot, 0deg));
  }

  .gallery-stack-content {
    left: 0.75rem;
    right: 0.75rem;
    bottom: 0.75rem;
  }
}

/* Kuvapino hieman pienemmÃƒÂ¤ksi, jotta pysyy valkoisen laatikon sisÃƒÂ¤llÃƒÂ¤ */
.gallery-stack-stage {
  padding-inline: clamp(0.5rem, 2vw, 1.5rem);
  overflow: hidden;
}

.gallery-stack-card {
  width: min(100%, 700px);
}

@media (max-width: 980px) {
  .gallery-stack-card {
    width: min(100%, 88vw);
  }
}

@media (max-width: 680px) {
  .gallery-stack-stage {
    padding-inline: 0.35rem;
  }

  .gallery-stack-card {
    width: min(100%, calc(100% - 0.4rem));
  }
}

/* Kuvapino: lisÃƒÂ¤ÃƒÂ¤ ylÃƒÂ¤- ja alavaraa, ettei kortit leikkaannu */
.gallery-stack-panel {
  overflow: hidden;
}

.gallery-stack-stage {
  min-height: clamp(460px, 66vw, 780px);
  padding: clamp(1rem, 2vw, 1.4rem) clamp(0.6rem, 2vw, 1.5rem) clamp(3.2rem, 6vw, 4.4rem);
  overflow: visible;
}

.gallery-stack-card {
  top: clamp(0.8rem, 1.8vw, 1.2rem);
  bottom: clamp(2.2rem, 4.8vw, 3.2rem);
  inset-inline: auto;
  height: auto;
  width: min(calc(100% - 2.4rem), 680px);
}

@media (max-width: 980px) {
  .gallery-stack-stage {
    min-height: clamp(430px, 86vw, 700px);
    padding-bottom: clamp(2.4rem, 7vw, 3.4rem);
  }

  .gallery-stack-card {
    width: min(calc(100% - 1.4rem), 88vw);
  }
}

@media (max-width: 680px) {
  .gallery-stack-stage {
    min-height: min(78svh, 120vw);
    padding: 0.7rem 0.25rem 2.3rem;
  }

  .gallery-stack-card {
    top: 0.55rem;
    bottom: 1.7rem;
    width: min(calc(100% - 0.5rem), 100%);
  }

  .gallery-stack-content {
    bottom: 0.6rem;
  }
}

/* Kuvapino: keskitys kuntoon + lisÃƒÂ¤ÃƒÂ¤ alavaraa */
.gallery-stack-panel {
  overflow: hidden;
}

.gallery-stack-stage {
  min-height: clamp(540px, 72vw, 880px);
  padding:
    clamp(1rem, 2vw, 1.4rem)
    clamp(0.9rem, 2.4vw, 1.8rem)
    clamp(5rem, 10vw, 6.6rem);
  overflow: hidden;
}

.gallery-stack-card {
  left: 50%;
  right: auto;
  top: clamp(0.7rem, 1.6vw, 1.1rem);
  bottom: clamp(3.8rem, 8vw, 5.2rem);
  inset-inline: unset;
  width: min(calc(100% - 3.2rem), 700px);
  height: auto;
  transform:
    translate(
      calc(-50% + var(--pile-x, 0px)),
      calc(var(--stack-index, 0) * 14px + var(--pile-y, 0px))
    )
    rotate(var(--pile-rot, 0deg));
}

.gallery-stack-card.is-top:hover {
  transform:
    translate(
      calc(-50% + var(--pile-x, 0px)),
      calc(var(--stack-index, 0) * 14px + var(--pile-y, 0px) - 4px)
    )
    rotate(var(--pile-rot, 0deg))
    scale(1.01);
}

@media (max-width: 980px) {
  .gallery-stack-stage {
    min-height: clamp(480px, 96vw, 760px);
    padding:
      0.9rem
      0.7rem
      clamp(4rem, 9vw, 5rem);
  }

  .gallery-stack-card {
    left: 50%;
    width: min(calc(100% - 1.8rem), 88vw);
    bottom: clamp(3rem, 7vw, 4.2rem);
  }
}

@media (max-width: 680px) {
  .gallery-stack-stage {
    min-height: min(82svh, 128vw);
    padding:
      0.7rem
      0.25rem
      3.4rem;
  }

  .gallery-stack-card {
    left: 50%;
    top: 0.55rem;
    bottom: 2.5rem;
    width: min(calc(100% - 0.5rem), 100%);
    transform:
      translate(
        calc(-50% + var(--pile-x, 0px)),
        calc(var(--stack-index, 0) * 12px + var(--pile-y, 0px))
      )
      rotate(var(--pile-rot, 0deg));
  }

  .gallery-stack-card.is-top:hover {
    transform:
      translate(
        calc(-50% + var(--pile-x, 0px)),
        calc(var(--stack-index, 0) * 12px + var(--pile-y, 0px))
      )
      rotate(var(--pile-rot, 0deg));
  }

  .gallery-stack-content {
    bottom: 0.7rem;
  }
}

/* === KUVAPINO: oikea keskitys + ei alareunan clippingiÃ¤ === */
/* LisÃ¤Ã¤ tÃ¤mÃ¤ aivan tiedoston loppuun */
#galleryWrap .gallery-stack-panel {
  overflow: hidden !important;
}

#galleryWrap .gallery-stack-stage {
  position: relative !important;
  width: 100% !important;
  min-height: clamp(700px, 78vw, 980px) !important;
  padding: 1.2rem 1.25rem 7.5rem !important;
  overflow: hidden !important;
  perspective: 1400px !important;
}

#galleryWrap .gallery-stack-stage .gallery-stack-card {
  position: absolute !important;
  left: 50% !important;
  right: auto !important;
  top: 1rem !important;
  bottom: 5.8rem !important;
  width: min(calc(100% - 3rem), 620px) !important;
  height: auto !important;
  margin: 0 !important;
  border-radius: 24px !important;
  transform-origin: center 88% !important;
  transform:
    translate(
      calc(-50% + var(--pile-x, 0px)),
      calc(var(--stack-index, 0) * 14px + var(--pile-y, 0px))
    )
    rotate(var(--pile-rot, 0deg)) !important;
}

#galleryWrap .gallery-stack-stage .gallery-stack-card.is-top:hover {
  transform:
    translate(
      calc(-50% + var(--pile-x, 0px)),
      calc(var(--stack-index, 0) * 14px + var(--pile-y, 0px) - 4px)
    )
    rotate(var(--pile-rot, 0deg))
    scale(1.01) !important;
}

#galleryWrap .gallery-stack-stage .gallery-stack-content {
  left: 1rem !important;
  right: 1rem !important;
  bottom: 1rem !important;
}

/* Pinon levÃ¤llÃ¤Ã¤n olo, mutta hallitusti keskellÃ¤ */
#galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(1) { --pile-x: 0px;   --pile-y: 0px;  --pile-rot: -4deg; }
#galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(2) { --pile-x: 34px;  --pile-y: 8px;  --pile-rot: 4.5deg; }
#galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(3) { --pile-x: -30px; --pile-y: 16px; --pile-rot: -2.4deg; }
#galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(4) { --pile-x: 46px;  --pile-y: 24px; --pile-rot: 5.6deg; }
#galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(5) { --pile-x: -42px; --pile-y: 32px; --pile-rot: -5deg; }
#galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(6) { --pile-x: 18px;  --pile-y: 38px; --pile-rot: 1.8deg; }
#galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(7) { --pile-x: -16px; --pile-y: 44px; --pile-rot: -1.1deg; }

@media (max-width: 980px) {
  #galleryWrap .gallery-stack-stage {
    min-height: clamp(600px, 106vw, 840px) !important;
    padding: 0.95rem 0.8rem 5.8rem !important;
  }

  #galleryWrap .gallery-stack-stage .gallery-stack-card {
    left: 50% !important;
    top: 0.8rem !important;
    bottom: 4.2rem !important;
    width: min(calc(100% - 1.6rem), 88vw) !important;
  }

  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(1) { --pile-x: 0px;   --pile-y: 0px;  --pile-rot: -3.5deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(2) { --pile-x: 20px;  --pile-y: 7px;  --pile-rot: 3.8deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(3) { --pile-x: -18px; --pile-y: 14px; --pile-rot: -2deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(4) { --pile-x: 24px;  --pile-y: 20px; --pile-rot: 4.8deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(5) { --pile-x: -24px; --pile-y: 26px; --pile-rot: -4deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(6) { --pile-x: 10px;  --pile-y: 31px; --pile-rot: 1.4deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(7) { --pile-x: -8px;  --pile-y: 36px; --pile-rot: -0.9deg; }
}

@media (max-width: 680px) {
  #galleryWrap .gallery-stack-stage {
    min-height: min(84svh, 138vw) !important;
    padding: 0.7rem 0.3rem 4rem !important;
  }

  #galleryWrap .gallery-stack-stage .gallery-stack-card {
    left: 50% !important;
    top: 0.55rem !important;
    bottom: 3rem !important;
    width: calc(100% - 0.6rem) !important;
    transform:
      translate(
        calc(-50% + var(--pile-x, 0px)),
        calc(var(--stack-index, 0) * 12px + var(--pile-y, 0px))
      )
      rotate(var(--pile-rot, 0deg)) !important;
  }

  #galleryWrap .gallery-stack-stage .gallery-stack-card.is-top:hover {
    transform:
      translate(
        calc(-50% + var(--pile-x, 0px)),
        calc(var(--stack-index, 0) * 12px + var(--pile-y, 0px))
      )
      rotate(var(--pile-rot, 0deg)) !important;
  }

  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(1) { --pile-x: 0px;  --pile-y: 0px;  --pile-rot: -2.6deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(2) { --pile-x: 9px;  --pile-y: 6px;  --pile-rot: 2.6deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(3) { --pile-x: -9px; --pile-y: 12px; --pile-rot: -1.6deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(4) { --pile-x: 12px; --pile-y: 17px; --pile-rot: 3.5deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(5) { --pile-x: -12px; --pile-y: 22px; --pile-rot: -2.8deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(6) { --pile-x: 5px; --pile-y: 27px; --pile-rot: 1.1deg; }
  #galleryWrap .gallery-stack-stage .gallery-stack-card:nth-child(7) { --pile-x: -5px; --pile-y: 31px; --pile-rot: -0.8deg; }

  #galleryWrap .gallery-stack-stage .gallery-stack-content {
    left: 0.7rem !important;
    right: 0.7rem !important;
    bottom: 0.7rem !important;
  }
}

/* === Hash-link fix for mobile / QR anchors === */
.hole-card[id] {
  scroll-margin-top: calc(var(--header-h) + 28px);
}

@media (max-width: 820px) {
  html {
    scroll-padding-top: 124px;
  }

  .hole-card[id] {
    scroll-margin-top: 132px;
  }
}

@media (max-width: 580px) {
  html {
    scroll-padding-top: 142px;
  }

  .hole-card[id] {
    scroll-margin-top: 148px;
  }
}


.top10-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.business-btn {
  background: #f56e1d;
  color: #fff;
  border-radius: 999px;
  padding: 0.8rem 1.4rem;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(245, 110, 29, 0.22);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.business-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(245, 110, 29, 0.28);
}

.business-card-overlay {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 3000;
}

.business-card-overlay.is-open {
  display: flex;
}

.business-card-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 18, 23, 0.82);
}

.business-card-modal {
  position: relative;
  z-index: 2;
  width: min(96vw, 1200px);
  height: min(94vh, 94vh);
  display: flex;
  align-items: center;
  justify-content: center;
}

.business-card-image {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
  cursor: pointer;
  background: #fff;
}

.business-contact-button {
  position: fixed;
  top: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: none;
  align-items: center;
  justify-content: center;
  background: #f56e1d;
  color: #fff;
  text-decoration: none;
  padding: 0.95rem 1.4rem;
  border-radius: 999px;
  font-weight: 800;
  box-shadow: 0 14px 30px rgba(245, 110, 29, 0.28);
  z-index: 3100;
  text-align: center;
}

.business-contact-button.is-visible {
  display: inline-flex;
}

@media (max-width: 768px) {
  .business-contact-button {
    width: calc(100vw - 2rem);
    max-width: 520px;
    font-size: 0.95rem;
    line-height: 1.3;
    padding: 0.9rem 1rem;
  }

  .top10-header {
    justify-content: flex-start;
    align-items: center;
  }

  .business-btn {
    width: auto;
    min-width: 180px;
    max-width: 220px;
    flex: 0 0 auto;
    justify-content: center;
    text-align: center;
  }
}


.metrix-logo-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.metrix-logo {
  display: block;
  height: 40px;
  width: auto;
  border-radius: 28px;
}

/* =========================================================
   LIEDON FRISBEEGOLFSEURA.FI
   Verkkokauppa / ratatuki -nosto pääsivulle
   Lisää tämä assets/css/style.css -tiedoston loppuun.
   ========================================================= */

.support-strip {
    width: 100%;
    background: #141414;
    color: #ffffff;
    padding: 34px 0;
}

.support-strip .wrap {
    width: min(1180px, calc(100% - 36px));
    margin: 0 auto;
}

.support-grid {
    display: grid;
    grid-template-columns: 1fr 1.25fr;
    gap: 55px;
    align-items: center;
}

.support-strip .eyebrow.dark {
    display: inline-block;
    color: #f56e1d;
    font-size: 0.78rem;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.support-strip .support-grid h2 {
    margin: 7px 0 0;
    color: #ffffff;
    font-size: clamp(1.7rem, 3vw, 2.5rem);
    line-height: 1.05;
    font-weight: 700;
}

.support-strip .support-grid p {
    margin: 0;
    color: #dddddd;
    font-size: 1.02rem;
    line-height: 1.6;
}

.support-strip .support-grid strong {
    color: #ffffff;
    font-weight: 800;
}

@media (max-width: 900px) {
    .support-strip {
        padding: 30px 0;
    }

    .support-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }
}

@media (max-width: 580px) {
    .support-strip .wrap {
        width: min(100% - 24px, 1180px);
    }

    .support-strip .support-grid h2 {
        font-size: 1.7rem;
    }

    .support-strip .support-grid p {
        font-size: 0.98rem;
    }
}
