:root {
  --sidebar-width: 250px;
  --topbar-height: 10.5rem;
  --hero-height: 600px;
  --accent: #7CFC00;
  --accent-dark: #5DB800;
  --btn-color: #0BDA51;
  --btn-color-dark: #09B843;
  --table-green: #089a38;
  --text-dark: #111;
  --panel-dark: rgba(0, 0, 0, 0.98);
  --panel-border: rgba(255, 255, 255, 0.08);
  --shadow-soft: 0 12px 40px rgba(0, 0, 0, 0.1);
  --shadow-hero: 0 6px 20px rgba(124, 252, 0, 0.4);
  --radius-sm: 0.3rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.8rem;
}

* {
  box-sizing: border-box;
}

/* ── Language switcher ──────────────────────────────────────── */
.lang-switcher-bar {
  position: absolute;
  right: 4rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.lang-flag {
  line-height: 1;
  text-decoration: none;
  opacity: 0.5;
  transition: opacity 0.15s, transform 0.15s;
  display: inline-flex;
  align-items: center;
  border-radius: 2px;
}
.lang-flag img { display: block; border-radius: 2px; }
.lang-flag:hover  { opacity: 0.9; transform: scale(1.15); }
.lang-flag-active {
  opacity: 1;
  outline: 2px solid #4da6ff;
  outline-offset: 2px;
  border-radius: 3px;
}

.mobile-lang-switcher {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem 0 0.25rem;
  justify-content: center;
}
@media (min-width: 981px) {
  .mobile-lang-switcher { display: none; }
}
@media (max-width: 980px) {
  .lang-switcher-bar { display: none; }
}

/* ── Mobile single-flag language toggle (top-left of header) ─── */
.mobile-lang-btn {
  display: none;
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2010;
}
.mobile-lang-btn > button {
  background: none;
  border: none;
  padding: 2px;
  cursor: pointer;
  display: flex;
  align-items: center;
  border-radius: 3px;
  outline: 2px solid #4da6ff;
  outline-offset: 2px;
}
.mobile-lang-btn > button img { display: block; border-radius: 2px; }
.mobile-lang-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 0.4rem);
  left: 0;
  width: max-content;
  flex-direction: column;
  gap: 0;
  background: #1e2235;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 0.45rem;
  padding: 0.3rem 0;
  z-index: 3000;
  box-shadow: 0 4px 16px rgba(0,0,0,0.45);
}
.mobile-lang-dropdown.open { display: flex; }
.mobile-lang-dropdown a {
  display: flex;
  align-items: center;
  padding: 0.6rem 0.8rem;
  opacity: 0.6;
  transition: opacity 0.15s;
}
.mobile-lang-dropdown a img {
  display: block;
  border-radius: 2px;
  width: 39px;
  height: 30px;
  max-width: none;
  flex-shrink: 0;
}
.mobile-lang-dropdown a:hover { opacity: 1; }
@media (max-width: 980px) {
  .mobile-lang-btn { display: block; }
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  position: relative;
  font-family: Arial, sans-serif;
  background: url('pictures/background.png') center / cover no-repeat;
  background-attachment: scroll;
  color: var(--text-dark);
}

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

/* Inline text links inside paragraphs and labels in the main content and modals */
main p a,
main label a,
.modal-content p a,
.modal-content label a {
  color: #4da6ff;
  text-decoration: underline;
  text-underline-offset: 2px;
}

main p a:hover,
main label a:hover {
  color: #80c1ff;
}

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

.sidebar-logo-bar {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--topbar-height);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 2rem;
  background: transparent;
  color: #111;
  z-index: 2002;
}

.sidebar-logo {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  height: calc(var(--topbar-height) - 1rem);
  width: auto;
  display: block;
  border: 5px solid #fff;
  border-radius: 4px;
}

.sidebar-logo-bar .hamburger-btn {
  position: absolute;
  right: 1rem;
}

.hamburger-btn {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.hamburger-btn span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 999px;
}

.mobile-menu {
  display: none;
}

@media (min-width: 981px) {
  .sidebar-nav-wrap {
    top: 0;
    left: 0;
  }

  body.page-home .hero {
    background: transparent;
  }
}

.hero-bg {
  display: none;
}

.sidebar-nav-wrap {
  position: absolute;
  top: var(--topbar-height);
  left: 0;
  width: var(--sidebar-width);
  height: calc(var(--hero-height) - 0px);
  z-index: 1001;
}

.nav-bg-rectangle {
  display: none;
}

.sidebar-nav {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  width: 9.2rem;
  background: #FEE96B;
  border-radius: 0 0 0.5rem 0.5rem;
  box-shadow: 2px 4px 18px rgba(0, 0, 0, 0.13);
  overflow: hidden;
}

.sidebar-nav a {
  display: flex;
  align-items: center;
  min-height: 3.85rem;
  padding: 0 2rem;
  color: #111;
  font-weight: 600;
  font-size: 0.98rem;
  text-align: left;
  transition: background 0.2s ease, color 0.2s ease;
  border-bottom: 1px solid #f5d060;
}

.sidebar-nav a:first-child {
  border-top: 1px solid #f5d060;
}

.sidebar-nav a:hover {
  background: rgba(255, 255, 100, 0.15);
}

.nav-logout-btn {
  display: flex;
  align-items: center;
  min-height: 3.85rem;
  padding: 0 2rem;
  color: #111;
  font-weight: 600;
  font-size: 0.98rem;
  text-align: left;
  background: none;
  border: none;
  border-bottom: 1px solid #f5d060;
  cursor: pointer;
  width: 100%;
  transition: background 0.2s ease, color 0.2s ease;
}

.sidebar-nav > *:last-child {
  border-bottom: none;
}

.nav-logout-btn:hover {
  background: rgba(255, 255, 100, 0.15);
}

.main-content {
  position: relative;
  z-index: 1;
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  background: transparent;
}

.hero {
  position: relative;
  z-index: 1;
  height: var(--hero-height);
  min-height: var(--hero-height);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 2rem;
  text-align: center;
  color: #fff;
  background: linear-gradient(135deg, rgba(0,0,0,0.55), rgba(0,0,0,0.35)), url('pictures/teniszpalya.png') center / cover no-repeat;
  margin-left: calc(-1 * var(--sidebar-width));
  width: calc(100% + var(--sidebar-width));
}

.hero-content {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1rem 0;
  margin-top: 200px;
}

.hero-title {
  margin: 0 0 2rem;
  font-size: clamp(3.2rem, 6vw, 5.5rem);
  line-height: 0.98;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 4px 10px rgba(0, 0, 0, 0.85), 0 1px 2px rgba(0, 0, 0, 0.8);
}

.hero-button {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  text-align: center;
  width: 160px;
  height: 160px;
  border-radius: 0;
  background: url('pictures/teniszlabda.png') center / contain no-repeat transparent;
  -webkit-mask-image: radial-gradient(circle at 50% calc(50% + 2px), black 61%, transparent 68%);
  mask-image: radial-gradient(circle at 50% calc(50% + 2px), black 61%, transparent 68%);
  color: #2a2a00 !important;
  font-size: 1rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  line-height: 1.3;
  border: none;
  box-shadow: 0 6px 24px rgba(180, 200, 0, 0.5);
  transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
}

.hero-button-text {
  display: inline-block;
  background: #fff;
  padding: 0.1rem 0.35rem;
  border-radius: 0.2rem;
}

.hero-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(124, 252, 0, 0.5);
  filter: brightness(1.05);
}

/* Navbar for subpages (login, register, appointment, etc.) */
header {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 2002;
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: var(--topbar-height);
  background: #000;
  border-bottom: 1px solid var(--panel-border);
}

.nav-logo {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #fff;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  flex-wrap: wrap;
}

.nav-links a {
  color: #fff;
  font-weight: 600;
  font-size: 0.98rem;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--accent);
}

/* Subpage sidebar – full height, not just hero height */
body > aside.sidebar-nav-wrap {
  height: 100vh;
}

/* Subpage main – offset for sidebar */
body > main {
  margin-left: var(--sidebar-width);
  padding: calc(var(--topbar-height) + 3rem) 3rem 3rem;
  min-height: 100vh;
  background: transparent;
}

body > main > section {
  background: #fff;
  border-radius: 0.5rem;
  padding: 2rem 2.5rem;
  color: #111;
  overflow: hidden;
}

/* Index page main (inside .main-content sidebar layout) */
.main-content main {
  position: relative;
  z-index: 2;
  background: transparent;
  color: #111;
  margin: 0 0 0 calc(-1 * var(--sidebar-width));
  padding: 3rem 2.5rem 3rem calc(var(--sidebar-width) + 2.5rem);
  text-align: left;
}

.main-content main section {
  margin: 0;
  padding: 0;
  max-width: none;
  text-align: left;
}

.section-title,
main p,
main a,
main h2,
main h3 {
  text-align: left;
}

section + section {
  margin-top: 2rem;
}

.section-title {
  margin: 0 0 1rem;
  font-size: 2.2rem;
  line-height: 1.1;
  color: #111;
  font-weight: 800;
}

p {
  margin: 0 0 1rem;
  max-width: 72ch;
  line-height: 1.65;
}

.booking-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.card {
  background: #f5f7fa;
  border: 1px solid rgba(124, 252, 0, 0.25);
  border-radius: 1rem;
  box-shadow: var(--shadow-soft);
  padding: 2rem;
  color: #111;
}

.card h3 {
  margin-top: 0;
}

label {
  display: block;
  margin: 1rem 0 0.5rem;
  font-weight: 700;
  color: #111;
}

input,
select,
textarea {
  width: 100%;
  padding: 1rem;
  border: 2px solid #e1e5e9;
  border-radius: 0.6rem;
  font: inherit;
  background: #fff;
  color: #111;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124, 252, 0, 0.1);
}

input.field-invalid,
select.field-invalid,
textarea.field-invalid {
  border-color: #e53e3e;
  box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.15);
}

input.field-invalid:focus,
select.field-invalid:focus,
textarea.field-invalid:focus {
  border-color: #e53e3e;
  box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.25);
}

input[type='submit'],
.modal-content button:not(.modal-close):not(.nonmember-opt),
.booking-button-container button {
  border: 0;
  background: linear-gradient(135deg, var(--btn-color), var(--btn-color-dark));
  color: #fff;
  cursor: pointer;
  font-weight: 800;
  text-transform: uppercase;
}

input[type='submit'] {
  margin-top: 1.2rem;
  padding: 0.8rem 1.6rem;
  border-radius: 0.48rem;
  font-size: 0.88rem;
}

input[type='submit']:hover {
  transform: translateY(-1.5px);
  box-shadow: 0 8px 24px rgba(124, 252, 0, 0.4);
}

.pw-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.pw-wrap input {
  flex: 1;
  padding-right: 2.6rem;
}
.pw-toggle {
  position: absolute;
  right: 0.6rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  color: #888;
  display: flex;
  align-items: center;
}
.pw-toggle:hover { color: #fff; }

.alert {
  margin: 0 0 1.5rem;
  padding: 1rem 1.5rem;
  border-radius: 0.6rem;
  font-weight: 600;
}

.alert-success {
  background: linear-gradient(135deg, #e6f9f7, #d1f2ee);
  color: #025b54;
  border-left: 5px solid var(--accent);
}

.alert-error {
  background: linear-gradient(135deg, #fbe5e5, #f8d7d7);
  color: #7d1616;
  border-left: 5px solid #dc3545;
}

/* ── intl-tel-input dark theme ──────────────────────────────────── */
.iti { display: block; }

.iti__selected-flag,
.iti__selected-country {
  background: transparent !important;
  border: none;
  outline: none;
}

.iti__selected-flag:hover,
.iti__selected-flag:focus,
.iti__selected-country:hover,
.iti__selected-country:focus {
  background: rgba(255, 255, 255, 0.06) !important;
}

.iti__selected-dial-code { color: #e2e8f0; }

.iti__dropdown-content,
.iti__country-list {
  background: #1a1a2e !important;
  border: 1px solid #3a3a5e !important;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.6);
}

.iti__country { color: #e2e8f0 !important; }

.iti__country:hover,
.iti__country.iti__highlight,
.iti__country--highlight { background: rgba(124, 252, 0, 0.10) !important; }

.iti__country-name { color: #e2e8f0 !important; }

.iti__dial-code { color: #8a9ab5 !important; }

.iti__divider { border-bottom-color: #3a3a5e !important; }

.iti__search-input {
  background: #0f0f23 !important;
  color: #e2e8f0 !important;
  border-color: #3a3a5e !important;
}

.iti__search-input::placeholder { color: #6a7a8f; }

.bookings-list {
  margin-top: 1rem;
}

.booking-item {
  padding: 0.75rem 0;
  border-bottom: 1px solid #eee;
}

.booking-item:last-child {
  border-bottom: none;
}

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

.week-arrow {
  font-size: 2.2rem;
  line-height: 1;
  color: #111;
  padding: 0 0.3rem;
  transition: color 0.15s, transform 0.15s;
  user-select: none;
}

.week-arrow:hover {
  color: var(--btn-color);
  transform: scaleX(1.3);
}

.calendar-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.calendar-grid {
  width: 100%;
  border-collapse: separate;
  border-spacing: 3px;
  table-layout: fixed;
  background: transparent;
}

.calendar-grid th,
.calendar-grid td {
  border: none;
  text-align: center;
  padding: 0.35rem;
  font-size: 0.86rem;
}

.calendar-grid th {
  position: sticky;
  top: 0;
  z-index: 3;
  background: var(--table-green);
  color: #111;
  border-radius: 0.35rem;
}

.day-name-short { display: none; }

.calendar-slot {
  background: #c8d8c0;
  color: #1a2a1a;
  border-radius: 0.35rem;
  cursor: pointer;
}

.calendar-slot.booked {
  background: #b52222;
  color: #fff;
  cursor: not-allowed;
}


.calendar-slot.own-pending {
  background: #c9960a;
  color: #fff;
  cursor: pointer;
}

.calendar-slot.own {
  background: #3d8f5a;
  color: #fff;
  cursor: default;
}

.calendar-slot.past {
  background: #8a8a8a;
  color: #e0e0e0;
  cursor: not-allowed;
}


.calendar-slot.selected {
  outline: 3px solid #00666b;
  background: #5abfb8;
  color: #fff;
}

.slot-legend {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem 1.2rem;
  margin-top: 0.8rem;
  font-size: 0.86rem;
}

.slot-legend span {
  padding: 0.22rem 0.6rem;
  border-radius: 0.35rem;
  color: #222;
}

.slot-legend .free {
  background: #c8d8c0;
  color: #1a2a1a;
  border: 1px solid #ccc;
}

.slot-legend .booked {
  background: #b52222;
  color: #111;
}



.slot-legend .own {
  background: #3d8f5a;
  color: #111;
}

.slot-legend .own-pending {
  background: #c9960a;
  color: #111;
  border: 1px solid #f0c040;
}

.slot-legend .past {
  background: #8a8a8a;
  color: #111;
  border: 1px solid #bbb;
}


.booking-button-container {
  position: fixed;
  right: 2rem;
  bottom: 2rem;
  z-index: 50;
}

.booking-button-container button {
  padding: 0.72rem 1.2rem;
  border-radius: 0.48rem;
  font-size: 0.8rem;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: flex-start;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
  z-index: 200;
  overflow-y: auto;
  padding: calc(var(--topbar-height) + 1rem) 0 1rem;
}

.modal.active {
  display: flex;
}

.modal-content {
  position: relative;
  width: 90%;
  max-width: 420px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2rem;
  background: #fff;
  border-radius: 0.8rem;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
  color: #111;
}

.modal-content h3 {
  margin-top: 0;
}

.modal-content label {
  margin-top: 1rem;
  font-weight: 600;
  color: #111;
}

.modal-content input {
  margin-top: 0.3rem;
  padding: 0.7rem;
  border: 1px solid #ccc;
  border-radius: 0.45rem;
  background: #fff;
  color: #111;
}

.modal-content button {
  width: 100%;
  margin-top: 0.96rem;
  padding: 0.68rem;
  border-radius: 0.36rem;
  font-size: 0.96rem;
}

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  border: 0;
  background: none;
  font-size: 1.8rem;
  line-height: 1;
  color: #999;
  cursor: pointer;
  width: auto;
  margin-top: 0;
  padding: 0;
}

@media (max-width: 980px) {
  body {
    background-image: url('pictures/background1.png');
  }
}

@media (max-width: 980px) {
  :root {
    --sidebar-width: 0px;
    --topbar-height: 5.25rem; /* explicit mobilra, var() újraszámítás elkerülése */
  }

  .sidebar-logo-bar {
    position: fixed;
  }

  header {
    position: fixed;
  }

  .sidebar-nav-wrap {
    display: none;
  }

  .main-content {
    margin-left: 0;
  }

  .main-content main {
    margin-left: 0;
    padding: 3rem 2.5rem;
  }

  body > main {
    margin-left: 0;
    padding: calc(var(--topbar-height) + 2rem) 1.5rem 2rem;
  }

  .hero {
    padding-top: 2rem;
    background: transparent;
  }

  .booking-wrapper {
    grid-template-columns: 1fr;
  }

  .hamburger-btn {
    display: inline-flex;
  }

  .hamburger-btn span {
    background: #111 !important;
  }

  .hamburger-btn {
    background: #f0d730;
    border-radius: 6px;
    width: 52px;
    height: 52px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
  }

  .mobile-menu {
    position: fixed;
    top: var(--topbar-height);
    right: -100%;
    width: min(44vw, 170px);
    height: auto;
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 0;
    background: #FEE96B;
    z-index: 3000;
    transition: right 0.28s ease;
    box-shadow: -4px 4px 16px rgba(0, 0, 0, 0.2);
    border-radius: 0 0 0 0.5rem;
    overflow: hidden;
  }

  .mobile-menu.open {
    right: 0;
  }

  .mobile-menu a,
  .mobile-menu .nav-logout-btn {
    color: #111;
    font-size: 1rem;
    padding: 0.9rem 1.5rem;
    border-bottom: 1px solid #f5d060;
    font-weight: 600;
  }

  .mobile-menu a:first-child {
    border-top: 1px solid #f5d060;
  }

  .mobile-menu > *:last-child {
    border-bottom: none;
  }

  .mobile-menu .nav-logout-btn {
    min-height: unset;
    background: none;
    border-left: none;
    border-right: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
  }

  .mobile-menu-close {
    display: none;
  }
}

@media (max-width: 680px) {
  body {
    font-size: clamp(0.75rem, 3.8vw, 1rem);
  }

  .sidebar-logo-bar {
    height: 4.75rem;
    padding: 0 1rem;
    border: none;
    border-radius: 0;
    background: url('pictures/header.png') center / cover no-repeat;
  }

  .sidebar-logo {
    display: none;
  }

  .hero {
    height: calc(100vh - var(--topbar-height));
    min-height: 540px;
  }

  .hero-content {
    padding: 1rem 0.5rem 0;
    margin-top: 2rem;
  }

  .hero-title {
    font-size: clamp(2.4rem, 10vw, 4.2rem);
    margin-bottom: 1.6rem;
  }

  .hero-button {
    width: 130px;
    height: 130px;
    font-size: 0.85rem;
  }

  .main-content main {
    padding: 2rem 1.25rem;
  }

  .main-content main section {
    padding: 0;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .calendar-nav {
    gap: 0.3rem;
  }

  .court-tabs {
    justify-content: center;
  }

  .calendar-nav .section-title {
    font-size: clamp(0.65rem, 3.8vw, 1.1rem);
    white-space: nowrap;
    margin: 0;
    padding: 0.3rem 0.6rem;
  }

  .week-arrow {
    font-size: clamp(1.6rem, 6vw, 2.2rem);
  }

  .day-name-full  { display: none; }
  .day-name-short { display: inline; }

  .calendar-wrap {
    box-sizing: border-box;
  }

  .calendar-grid {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
    border: none;
  }

  .calendar-grid th,
  .calendar-grid td {
    padding: 0.44rem 0.1rem;
    font-size: clamp(0.5rem, 1.9vw, 0.75rem);
    vertical-align: middle;
    overflow: hidden;
    word-break: break-all;
  }

  .calendar-grid th:first-child,
  .calendar-grid td:first-child {
    white-space: nowrap;
  }
}

/* ----------------------------------------------------------------
   Pálya tab-ok (appointment.php)
   ---------------------------------------------------------------- */
.court-tabs {
  display: flex;
  gap: 0.4rem;
  margin-bottom: 1.2rem;
}

.court-tab {
  padding: 0.5rem 1.4rem;
  border-radius: 0.4rem;
  border: 2px solid #000;
  background: var(--btn-color);
  color: #fff;
  font-weight: 600;
  font-size: 0.95rem;
  transition: background 0.15s;
}

.court-tab:hover {
  background: var(--btn-color-dark);
  color: #fff;
}

.court-tab.active {
  background: var(--btn-color);
  color: #fff;
  border-color: #000;
  outline: 3px solid #fff;
  outline-offset: 2px;
}

/* ----------------------------------------------------------------
   Foglalás lista táblázat (profile.php, checkout.php)
   ---------------------------------------------------------------- */
.bookings-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.bookings-table th,
.bookings-table td {
  padding: 0.55rem 0.8rem;
  border: 1px solid #e0e0e0;
  text-align: left;
}

.bookings-table th {
  background: #003e3c;
  color: #fff;
  font-weight: 600;
}

.bookings-table tr:nth-child(even) td {
  background: #f0f4f8;
}

/* ----------------------------------------------------------------
   Státusz badge-ek
   ---------------------------------------------------------------- */
.status-badge {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 0.3rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.status-confirmed  { background: #d1f2ee; color: #025b54; }
.status-pending    { background: #fff3cd; color: #7d5a00; }
.status-cancelled  { background: #f8d7d7; color: #7d1616; }
.status-membership { background: #cce5ff; color: #004085; }

/* ----------------------------------------------------------------
   Általános elsődleges gomb
   ---------------------------------------------------------------- */
.btn-primary {
  display: inline-block;
  margin-top: 1rem;
  background: linear-gradient(135deg, var(--btn-color), var(--btn-color-dark));
  color: #fff;
  border: 0;
  padding: 0.85rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 700;
  font-size: 1.05rem;
  cursor: pointer;
  transition: filter 0.2s, transform 0.2s;
}

.btn-primary:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

/* ----------------------------------------------------------------
   Lemondás gomb (profile.php)
   ---------------------------------------------------------------- */
.btn-cancel {
  padding: 0.3rem 0.8rem;
  border: 1px solid #dc3545;
  background: #1a1a2e;
  color: #dc3545;
  border-radius: 0.35rem;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.btn-cancel:hover {
  background: #dc3545;
  color: #fff;
}

/* ----------------------------------------------------------------
   Checkout összesítő
   ---------------------------------------------------------------- */
.checkout-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem 1rem;
  background: #f0faf9;
  border: 1px solid var(--accent);
  border-radius: 0.5rem;
  font-size: 1rem;
  color: #111;
}

.checkout-summary strong {
  font-size: 1.15rem;
  color: var(--accent-dark);
}

/* Booking button – legyen elég széles a dinamikus szövegnek */
.booking-button-container button {
  white-space: nowrap;
  padding: 0.72rem 1.4rem;
}

.btn-cancel-float {
  background: #dc3545;
  color: #fff;
  border: none;
  border-radius: 0.48rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s;
}
.btn-cancel-float:hover {
  background: #b02a37;
}

/* Tagság kártya (profile.php) */
.membership-card {
  padding: 0.9rem 1.2rem;
  border-radius: 0.5rem;
  font-size: 0.95rem;
  overflow: hidden;
}

.membership-active {
  background: #d1f2ee;
  color: #025b54;
  border: 1px solid #7CFC00;
}

/* Fizetési státuszok */
.status-succeeded { background: #d1f2ee; color: #025b54; }
.status-failed    { background: #f8d7d7; color: #7d1616; }
.status-refunded  { background: #e2e3e5; color: #383d41; }

/* Barion fizetés gomb */
.btn-barion-pay {
  width: 100%;
  padding: 1rem;
  background: linear-gradient(135deg, #1a6fd4, #1050a8);
  color: #fff;
  border: 0;
  border-radius: 0.5rem;
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  transition: filter 0.2s, transform 0.2s;
}

.btn-barion-pay:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

/* ---------------------------------------------------------------
   Admin panel
   --------------------------------------------------------------- */

.admin-section {
  max-width: 1100px;
  margin: 0 auto;
}

/* Admin sub-navigation */
.admin-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 1rem 0 1.5rem;
}
.admin-subnav a {
  padding: 0.4rem 1rem;
  border-radius: 0.4rem;
  background: rgba(0,0,0,0.12);
  color: inherit;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: background 0.15s;
}
.admin-subnav a:hover {
  background: rgba(0,169,157,0.2);
  color: #00a99d;
}
.admin-subnav a.active {
  background: rgba(0,169,157,0.25);
  color: #00a99d;
}
.admin-subnav-select {
  padding: 0.4rem 1rem;
  border-radius: 0.4rem;
  background: rgba(0,0,0,0.12);
  color: inherit;
  border: none;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  width: auto;
  transition: background 0.15s;
}
.admin-subnav-select.active {
  background: rgba(0,169,157,0.25);
  color: #00a99d;
}

/* Filter form */
.admin-filter-form {
  background: #f5f7fa;
  border: 1px solid #d0d7e3;
  border-radius: 0.6rem;
  padding: 1rem 1.2rem;
  margin-bottom: 1.2rem;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-end;
}

.filter-row label {
  display: flex;
  flex-direction: column;
  font-size: 0.82rem;
  color: #555;
  gap: 0.25rem;
}

.filter-row input[type="text"],
.filter-row input[type="date"],
.filter-row select {
  background: #fff;
  border: 1px solid #ccd3de;
  border-radius: 0.35rem;
  color: #111;
  padding: 0.4rem 0.6rem;
  font-size: 0.9rem;
  min-width: 130px;
}

/* Admin buttons */
.admin-btn {
  display: inline-block;
  padding: 0.42rem 0.9rem;
  background: #7CFC00;
  color: #fff;
  border: none;
  border-radius: 0.35rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: filter 0.15s;
  white-space: nowrap;
}

.admin-btn:hover {
  filter: brightness(1.1);
}

.admin-btn-danger {
  background: #e53e3e;
}

.admin-btn-ghost {
  background: transparent;
  border: 1px solid #ccd3de;
  color: #555;
}

.admin-btn-ghost:hover {
  background: #e8ecf2;
  color: #111;
  filter: none;
}

/* Table wrapper */
.admin-table-wrap {
  overflow-x: auto;
  border-radius: 0.5rem;
  border: 1px solid #d0d7e3;
}

/* stat cards */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  background: #f5f7fa;
  border: 1px solid #d0d7e3;
  border-radius: 0.6rem;
  padding: 1.2rem 1.4rem;
  color: #111;
}

.stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: #7CFC00;
  line-height: 1.1;
}

.stat-label {
  font-size: 0.9rem;
  color: #111;
  margin-top: 0.25rem;
}

.stat-sub {
  font-size: 0.78rem;
  color: #888;
  margin-top: 0.2rem;
}

/* Membership expiry warning */
.membership-expiring {
  color: #f59e0b;
  font-weight: 600;
}

/* Admin topbar / sidebar overrides */
.admin-topbar {
  background: #0d1117;
}

.admin-main {
  margin-left: var(--sidebar-width);
  padding: calc(var(--topbar-height) + 2rem) 2rem 2rem;
}

.admin-sidebar .sidebar-nav a {
  border-radius: 0.4rem;
}

/* ----------------------------------------------------------------
   Site footer
   ---------------------------------------------------------------- */
footer.site-footer {
  background: #FEE96B;
  color: #111;
  padding: 2.5rem 3rem 2.5rem calc(var(--sidebar-width) + 3rem);
}

.footer-inner {
  max-width: 1100px;
  display: grid;
  grid-template-columns: 1fr 1fr 1.4fr;
  gap: 2rem 3rem;
}

.footer-col h3 {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin: 0 0 1rem;
  color: #111;
}

.footer-hours {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.18rem 1.2rem;
  font-size: 0.85rem;
}

.footer-hours .day {
  font-weight: 700;
}

.footer-col ul {
  list-style: disc;
  padding-left: 1.1rem;
  margin: 0;
}

.footer-col ul li {
  margin-bottom: 0.4rem;
}

.footer-col ul li a {
  color: #333;
  font-size: 0.86rem;
  text-decoration: none;
}

.footer-col ul li a:hover {
  color: #000;
  text-decoration: underline;
}

.footer-brand {
  font-size: 1.25rem;
  font-weight: 800;
  color: #111;
  margin: 0 0 0.6rem;
}

.footer-contact {
  font-size: 0.86rem;
  line-height: 1.8;
}

.footer-contact a {
  color: #333;
  text-decoration: none;
}

.footer-contact a:hover {
  color: #000;
  text-decoration: underline;
}

.footer-bottom {
  background: #f0d730;
  color: #333;
  text-align: center;
  font-size: 0.78rem;
  padding: 0.65rem 1rem;
}

@media (max-width: 980px) {
  footer.site-footer {
    padding: 2.5rem 3rem;
  }
}

@media (max-width: 680px) {
  footer.site-footer {
    padding: 2rem 1.25rem;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .bookings-table {
    font-size: 0.82rem;
    width: calc(100% + 5rem - 4px);
    margin-left: calc(-2.5rem + 2px);
    margin-right: calc(-2.5rem + 2px);
  }

  details {
    overflow: visible;
  }

  .bookings-table th,
  .bookings-table td {
    padding: 0.4rem 0.6rem;
    white-space: nowrap;
  }

  .bookings-table td:last-child,
  .bookings-table th:last-child {
    white-space: normal;
    padding-left: 0;
    text-align: center;
  }

  .status-badge {
    display: inline-block;
    white-space: nowrap;
  }
}

/* ----------------------------------------------------------------
   Cookie banner
   ---------------------------------------------------------------- */
#cookieBanner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9000;
  background: #1a1f2e;
  border-top: 1px solid #2d3748;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.45);
  animation: cookieSlideUp 0.3s ease;
}
@keyframes cookieSlideUp {
  from { transform: translateY(100%); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}
#cookieBanner .cookie-text {
  flex: 1;
  font-size: 0.88rem;
  color: #b0b8c8;
  line-height: 1.5;
}
#cookieBanner .cookie-text strong {
  color: #e0e4ec;
  display: block;
  margin-bottom: 0.2rem;
}
#cookieBanner .cookie-actions {
  display: flex;
  gap: 0.6rem;
  flex-shrink: 0;
}
#cookieBanner .cookie-accept {
  padding: 0.55rem 1.2rem;
  background: linear-gradient(135deg, #0BDA51, #09B843);
  color: #fff;
  border: none;
  border-radius: 0.4rem;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}
#cookieBanner .cookie-details {
  padding: 0.55rem 1rem;
  background: transparent;
  color: #4da6ff;
  border: 1px solid #4da6ff;
  border-radius: 0.4rem;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
}
#cookieBanner.hidden {
  display: none;
}
@media (max-width: 680px) {
  #cookieBanner {
    bottom: auto;
    top: 50%;
    left: 50%;
    right: auto;
    transform: translate(-50%, -50%);
    width: min(88vw, 360px);
    border-radius: 0.75rem;
    border: 1px solid #2d3748;
    flex-direction: column;
    align-items: stretch;
    gap: 0.85rem;
    padding: 1.25rem;
    animation: cookieFadeIn 0.25s ease;
  }
  @keyframes cookieFadeIn {
    from { opacity: 0; transform: translate(-50%, -48%); }
    to   { opacity: 1; transform: translate(-50%, -50%); }
  }
  #cookieBanner .cookie-actions {
    justify-content: stretch;
  }
  #cookieBanner .cookie-accept,
  #cookieBanner .cookie-details {
    flex: 1;
    text-align: center;
    justify-content: center;
  }
}

/* ----------------------------------------------------------------
   Hónap választó popup
   ---------------------------------------------------------------- */
.date-picker-trigger {
  cursor: pointer;
  background: #e8e8e8;
  color: #111 !important;
  border-radius: 0.5rem;
  padding: 0.4rem 1.1rem;
  font-size: 1.1rem !important;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  border: none;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
  transition: background 0.15s;
}

.date-picker-trigger:hover {
  background: #e8e8e8;
}

.month-picker-popup {
  display: none;
  position: absolute;
  z-index: 500;
  background: #fff;
  border: 2px solid var(--btn-color);
  border-radius: 0.6rem;
  padding: 0.5rem;
  box-shadow: 0 8px 32px rgba(0,0,0,0.15);
  min-width: 200px;
}

.month-picker-popup.open {
  display: block;
}

.month-picker-btn {
  padding: 0.45rem 0.8rem;
  border: 1px solid #d0d7e3;
  border-radius: 0.35rem;
  background: transparent;
  color: #111;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.month-picker-btn:hover {
  background: var(--btn-color);
  color: #fff;
  border-color: var(--btn-color);
}

.month-picker-btn.current {
  background: var(--btn-color);
  color: #fff;
  border-color: var(--btn-color);
  font-weight: 700;
}

/* Tagság oldal kártyák */
.membership-plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.2rem;
  margin-top: 1.5rem;
}

.membership-plan-card {
  background: #f5f7fa;
  border: 1px solid #d0d7e3;
  border-radius: 0.75rem;
  padding: 1.4rem 1.2rem;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.membership-plan-card:hover {
  border-color: var(--btn-color);
  box-shadow: 0 4px 20px rgba(0,169,157,0.15);
}

.membership-plan-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #111;
  margin-bottom: 0.5rem;
}

.membership-plan-price {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--btn-color);
  margin-bottom: 0.5rem;
}

.membership-plan-desc {
  font-size: 0.88rem;
  color: #333;
  line-height: 1.5;
  flex: 1;
}

.membership-plan-btn {
  display: block;
  width: 100%;
  padding: 0.7rem;
  border: 0;
  border-radius: 0.45rem;
  background: linear-gradient(135deg, var(--btn-color), var(--btn-color-dark));
  color: #111;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: opacity 0.15s;
}

.membership-plan-btn:hover {
  opacity: 0.88;
}

.day-picker-btn {
  display: block;
  width: 100%;
  text-align: left;
  margin-bottom: 0.2rem;
}

.nonmember-opt {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  width: 100% !important;
  padding: 0.7rem 1rem !important;
  border: 1px solid #d0d7e3 !important;
  border-radius: 0.45rem !important;
  background: #f5f7fa !important;
  color: #111 !important;
  font-size: 0.95rem !important;
  font-weight: 600 !important;
  text-transform: none !important;
  cursor: pointer !important;
  transition: background 0.15s, border-color 0.15s;
}
.nonmember-opt:hover {
  background: #e8ecf2 !important;
  border-color: var(--btn-color) !important;
}

/* ----------------------------------------------------------------
   Slot toast értesítő
   ---------------------------------------------------------------- */
#slotToast {
  position: fixed;
  bottom: 5rem;
  left: 50%;
  transform: translateX(-50%) translateY(1rem);
  background: #333;
  color: #fff;
  padding: 0.65rem 1.4rem;
  border-radius: 0.5rem;
  font-size: 0.92rem;
  font-weight: 600;
  white-space: nowrap;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

#slotToast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* form success banner */
.form-success {
  background: #d1f2ee;
  color: #025b54;
  border: 1px solid #7CFC00;
  border-radius: 0.4rem;
  padding: 0.65rem 1rem;
  font-size: 0.9rem;
}

/* ── Naptár lapozás slide animáció (View Transitions API) ───────── */
@keyframes vt-slide-out-left  { to   { transform: translateX(-100%); } }
@keyframes vt-slide-in-right  { from { transform: translateX(100%);  } }
@keyframes vt-slide-out-right { to   { transform: translateX(100%);  } }
@keyframes vt-slide-in-left   { from { transform: translateX(-100%); } }

html[data-nav-dir="next"] ::view-transition-old(root) {
  animation: 0.32s ease-in-out both vt-slide-out-left;
}
html[data-nav-dir="next"] ::view-transition-new(root) {
  animation: 0.32s ease-in-out both vt-slide-in-right;
}
html[data-nav-dir="prev"] ::view-transition-old(root) {
  animation: 0.32s ease-in-out both vt-slide-out-right;
}
html[data-nav-dir="prev"] ::view-transition-new(root) {
  animation: 0.32s ease-in-out both vt-slide-in-left;
}

@media (prefers-reduced-motion: reduce) {
  html[data-nav-dir] ::view-transition-old(root),
  html[data-nav-dir] ::view-transition-new(root) {
    animation: none;
  }
}