/* V2.1 components; existing blue/gold visual system retained. */
@media (min-width: 1051px) {
  #rolunk .about-layout {
    grid-template-columns: minmax(0, 1fr) 520px;
    gap: 5vw;
  }
}
@media (min-width: 851px) and (max-width: 1050px) {
  #rolunk .about-layout {
    grid-template-columns: minmax(0, 1fr) 390px;
  }
}
/* Az eredeti nappali újragenerált, feliratok nélküli változata. */
#fooldal .hero-photo {
  width: 52%;
  background-image: url("assets/kk-home-clean.webp");
  background-size: auto 115%;
  background-position: left center;
}
@media (min-width: 1570px) {
  #fooldal .hero-photo {
    background-size: 115% auto;
  }
}
@media (max-width: 700px) {
  #fooldal .hero-photo {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
  }
}

#admin-panel-properties > .admin-featured-summary {
  margin: 14px 0 0;
}
#admin-panel-properties > .transfer-actions {
  margin: 16px 0 0;
}
#admin-panel-properties #transfer-status:empty {
  display: none;
}
textarea:not([readonly]) {
  resize: vertical;
  max-width: 100%;
  min-width: 0;
}
.editor-dialog input:not([type="radio"]):not([type="checkbox"]),
.editor-dialog select,
.editor-dialog textarea,
.editor-dialog input[type="file"]::file-selector-button {
  border-radius: 6px;
}
#property-form .editor-section {
  margin: 0;
  padding: 24px 0;
  border: 0;
  border-top: 1px solid var(--line);
}
#property-form .editor-section:first-of-type {
  border-top: 0;
  padding-top: 0;
}
#property-form .editor-section h3 {
  margin: 0 0 18px;
  font-size: 15px;
  color: var(--navy);
  font-weight: 700;
}
#property-size-fields:not(:has(> :not([hidden]))) {
  display: none;
}
#property-size-fields,
#property-extra-features {
  margin-top: 17px;
}
.image-upload-help {
  margin: -8px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}
#app-loader {
  display: none;
}
.app-loading {
  overflow: hidden;
}
.app-loading > :not(#app-loader):not(#data-warning) {
  visibility: hidden;
}
.app-loading #app-loader {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  background: #fff;
  color: var(--navy);
  font-size: 16px;
}
.app-loading #app-loader::before {
  content: "";
  width: 24px;
  height: 24px;
  border: 2px solid #e5e8e9;
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: loading-spin 800ms linear infinite;
}
@keyframes loading-spin {
  to {
    transform: rotate(360deg);
  }
}
@media (prefers-reduced-motion: reduce) {
  .app-loading #app-loader::before {
    animation: none;
  }
}
#data-warning {
  position: relative;
  z-index: 110;
  background: #fff1cd;
  color: #553b00;
  padding: 16px;
  margin: 0;
}
#data-warning[hidden] {
  display: none;
}
.filter-field select {
  min-height: 42px;
  max-width: 100%;
  border: 0;
  background: transparent;
  color: var(--navy, #172b46);
  font: inherit;
}
.filter-field small {
  font-size: 10px;
}
.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 12px;
}
.gallery-summary {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}
.gallery-item {
  min-width: 0;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.gallery-thumbnail {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  background: var(--paper);
  cursor: grab;
}
.gallery-thumbs img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  border-radius: 8px;
}
.gallery-image-number,
.gallery-cover-badge {
  position: absolute;
  top: 8px;
  padding: 4px 8px;
  border-radius: 5px;
  font-size: 11px;
  font-weight: 700;
}
.gallery-image-number {
  left: 8px;
  background: rgba(12, 34, 64, 0.85);
  color: white;
}
.gallery-cover-badge {
  right: 8px;
  background: #f4e4c5;
  color: #604718;
}
.gallery-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  margin-top: 8px;
}
.gallery-actions button {
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 0;
  height: 36px;
  margin: 0;
  padding: 0;
  border: 1px solid #dce2e8;
  background: #f7f9fb;
  border-radius: 7px;
  color: var(--navy);
  cursor: pointer;
}
.gallery-actions button:hover:not(:disabled) {
  background: #eaf0f6;
  border-color: #aabbd0;
}
.gallery-actions [data-gallery="remove"] {
  color: #a44040;
}
.gallery-actions [data-gallery="remove"]:hover:not(:disabled) {
  background: #fff0ef;
  border-color: #e4b5b1;
}
.gallery-actions button:disabled {
  opacity: 0.4;
  cursor: default;
}
.gallery-item:first-child [data-gallery="cover"] {
  opacity: 1;
  color: #987127;
  background: #faf4e9;
  border-color: #ebd9b6;
}
.gallery-item:first-child [data-gallery="cover"] svg {
  fill: #ebd9b6;
}
.gallery-item.is-dragging {
  opacity: 0.45;
}
.gallery-item.is-drop-target {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
  background: #fcf8f0;
}
.gallery-actions svg {
  pointer-events: none;
}
.gallery-thumbs button:focus-visible {
  outline: 2px solid #a77f36;
  outline-offset: 2px;
}
@media (max-width: 480px) {
  #gallery-editor .gallery-thumbs {
    grid-template-columns: 1fr;
  }
  .gallery-thumbs img {
    height: 170px;
  }
  .gallery-actions button {
    height: 40px;
  }
}
.public-gallery > .gallery-image-trigger {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #f2f4f5;
  cursor: zoom-in;
}
.public-gallery .detail-image {
  width: 100%;
  height: 340px;
  object-fit: cover;
  margin: 0;
}
.detail-actions button,
[data-link-share],
.transfer-actions button {
  border: 1px solid #c7d0db;
  background: white;
  padding: 10px 15px;
  border-radius: 6px;
  cursor: pointer;
  color: #18334e;
}
.detail-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
[data-link-status] input {
  display: block;
  width: 100%;
  padding: 10px;
}
.detail-body > p {
  white-space: pre-line;
}
.transfer-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 12px 0 24px;
}
.transfer-actions p {
  width: 100%;
  margin: 0;
}
#inquiry-search,
#inquiry-status {
  display: block;
  max-width: 100%;
  padding: 10px;
  border: 1px solid #c7d0db;
  border-radius: 6px;
}
#admin-inquiries-list .status-badge {
  margin-left: 10px;
}
body:has(dialog[open]) {
  overflow: hidden;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
@media (max-width: 600px) {
  .public-gallery .detail-image {
    height: 230px;
  }
  .gallery-thumbs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .filter-field select {
    width: 100%;
  }
  .transfer-actions {
    align-items: stretch;
    flex-direction: column;
  }
  #gallery-editor {
    min-width: 0;
  }
  .detail-actions > * {
    width: 100%;
    text-align: center;
  }
}

.app-error main,
.app-error header,
.app-error footer {
  pointer-events: none;
  visibility: hidden;
}
#data-warning button {
  margin-left: 12px;
  padding: 8px 12px;
}

.sort-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 20px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  color: var(--navy);
}
.sort-row select {
  min-height: 44px;
  padding: 8px;
  border: 1px solid #c7d0db;
  border-radius: 5px;
  background: white;
  max-width: 100%;
}
.sort-row small {
  color: var(--muted);
}
@media (max-width: 600px) {
  .sort-row {
    justify-content: flex-start;
    padding: 12px 16px;
  }
  .sort-row small {
    width: 100%;
  }
}
/* Requested interface refinements. */
#data-warning {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.detail-actions .v21-action,
.gallery-lightbox .v21-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  min-width: 44px;
  padding: 11px 16px;
  border: 1px solid #bec9d5;
  border-radius: 6px;
  background: #fff;
  color: var(--navy);
  font:
    600 14px "DM Sans",
    Arial,
    sans-serif;
  text-transform: none;
  letter-spacing: normal;
  line-height: 1.3;
  text-decoration: none;
  cursor: pointer;
  transition:
    background 0.15s,
    border-color 0.15s;
}
.detail-actions .v21-action:hover,
.gallery-lightbox .v21-action:hover {
  background: #f5eddf;
  border-color: var(--gold);
  color: var(--navy);
}
.v21-action:focus-visible,
.admin-secondary-action:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}
.results-line {
  gap: 20px;
  flex-wrap: wrap;
  align-items: center;
}
.results-line .sort-row {
  padding: 0;
  border: 0;
  margin-left: auto;
  gap: 10px;
  justify-content: flex-end;
}
.results-line #reset-filters {
  white-space: nowrap;
}
.image-url-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.image-url-controls {
  display: flex;
  align-items: stretch;
  gap: 10px;
}
.image-url-controls input {
  flex: 1;
  min-width: 0;
}
.admin-secondary-action,
#gallery-add-url.admin-secondary-action {
  border: 1px solid #bec9d5;
  border-radius: 6px;
  background: #fff;
  color: var(--navy);
  padding: 11px 16px;
  min-height: 44px;
  white-space: nowrap;
  font-weight: 600;
  font-size: 13px;
}
.admin-secondary-action:hover {
  background: #f5eddf;
  border-color: var(--gold);
}
dialog.gallery-lightbox {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #fff;
  overflow: hidden;
  box-sizing: border-box;
}
.gallery-lightbox::backdrop {
  background: rgba(8, 19, 31, 0.62);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.lightbox-toolbar {
  position: absolute;
  z-index: 2;
  top: 16px;
  left: 24px;
  right: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.lightbox-stage {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 84px 84px 40px;
  box-sizing: border-box;
}
#lightbox-image {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  user-select: none;
}
.gallery-lightbox .lightbox-prev,
.gallery-lightbox .lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
}
.lightbox-prev {
  left: 20px;
}
.lightbox-next {
  right: 20px;
}
@media (max-width: 600px) {
  .results-line .sort-row {
    margin: 0;
    justify-content: flex-start;
    order: 3;
    width: 100%;
  }
  .image-url-controls {
    flex-direction: column;
  }
  .image-url-controls button {
    align-self: flex-start;
  }
  .lightbox-toolbar {
    left: 16px;
    right: 16px;
    top: 12px;
  }
  .lightbox-stage {
    padding: 80px 12px 90px;
  }
  .gallery-lightbox .lightbox-prev,
  .gallery-lightbox .lightbox-next {
    top: auto;
    bottom: 20px;
    transform: none;
  }
  .lightbox-prev {
    left: calc(50% - 58px);
  }
  .lightbox-next {
    right: calc(50% - 58px);
  }
}

html:has(#gallery-lightbox[open]) {
  overflow: hidden;
  scrollbar-gutter: auto;
}
.editor-fields > .full {
  grid-column: 1 / -1;
}

/* Image-edge navigation replaces the old gallery toolbar. */
.public-gallery {
  position: relative;
  isolation: isolate;
}
.public-gallery > .gallery-edge {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(48px, 13%, 88px);
  padding: 0;
  border: 0;
  border-radius: 0;
  color: #fff;
  cursor: pointer;
  opacity: 0.8;
  transition: opacity 0.18s;
}
.gallery-edge-prev {
  left: 0;
  background: linear-gradient(to right, rgba(8, 19, 31, 0.48), transparent);
}
.gallery-edge-next {
  right: 0;
  background: linear-gradient(to left, rgba(8, 19, 31, 0.48), transparent);
}
.public-gallery > .gallery-edge:hover,
.public-gallery > .gallery-edge:focus-visible {
  opacity: 1;
}
.public-gallery > .gallery-edge:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: -4px;
}
.gallery-edge svg {
  pointer-events: none;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.45));
}
.gallery-position {
  position: absolute;
  bottom: 12px;
  left: 50%;
  z-index: 1;
  transform: translateX(-50%);
  padding: 4px 10px;
  border-radius: 20px;
  color: #fff;
  background: rgba(8, 19, 31, 0.48);
  font-size: 12px;
  line-height: 1.5;
  pointer-events: none;
}
#property-dialog > #detail-close {
  z-index: 3;
}

/* Only the inline gallery slides; the lightbox changes images immediately. */
.public-gallery > .gallery-image-trigger {
  position: relative;
  overflow: hidden;
}
.public-gallery .gallery-slide-previous {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
/* Complete public navigation, shared contacts and discreet legal links. */
.site-footer .footer-inner {
  display: grid;
  grid-template-columns: minmax(220px, 1.1fr) minmax(240px, 1fr) minmax(
      240px,
      1fr
    );
  gap: 48px;
  align-items: start;
}
.site-footer h2 {
  font:
    600 13px/1.5 "DM Sans",
    Arial,
    sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold2);
  margin: 0 0 20px;
}
.site-footer .footer-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 24px;
  align-items: start;
}
.site-footer .footer-links a,
.footer-social {
  font-size: 13px;
  line-height: 1.6;
  width: fit-content;
}
.site-footer a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.site-footer .contact-line {
  display: grid;
  grid-template-columns: 1fr;
  gap: 5px;
  padding: 0;
  margin: 0 0 16px;
  border: 0;
  font-size: 13px;
}
.site-footer .contact-line > span {
  color: #b6c2ce;
  font-size: 11px;
}
.site-footer .contact-line a {
  color: #fff;
  font-weight: 500;
  overflow-wrap: anywhere;
}
/* One contact per row on the contact page and in the footer. */
.contact-phones {
  display: grid;
  grid-template-columns: minmax(0, max-content);
  gap: 14px 16px;
  min-width: 0;
  max-width: 100%;
  width: fit-content;
}
.contact-phones:has(.contact-phone-name) {
  grid-template-columns: minmax(0, max-content) minmax(0, max-content);
}
#public-contacts .contact-phones {
  margin-left: auto;
  text-align: right;
}
.contact-line .contact-phone {
  display: grid;
  grid-column: 1/-1;
  grid-template-columns: subgrid;
  align-items: baseline;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  color: var(--navy);
  line-height: 1.6;
  font-weight: 600;
}
.site-footer .contact-line .contact-phone {
  color: #fff;
  font-weight: 500;
}
.contact-line .contact-phone span {
  color: inherit;
}
.contact-line .contact-phone .contact-phone-name {
  overflow-wrap: anywhere;
  font-weight: 400;
  opacity: 0.72;
}
.contact-phone-number {
  grid-column: -2/-1;
  text-align: left;
  overflow-wrap: anywhere;
  font-variant-numeric: tabular-nums;
}
.contact-phone-name + .contact-phone-number {
  border-inline-start: 1px solid rgb(201 161 90 / 45%);
  padding-inline-start: 16px;
}
.site-footer .footer-social {
  display: inline-block;
  color: var(--gold2);
  margin-top: 3px;
}
.site-footer .footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 32px;
}
.site-footer .footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  font-size: 11px;
  line-height: 1.7;
  color: #c0cbd6;
}
.legal-document-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px 28px;
  border-top: 1px solid var(--line);
  padding: 26px 0;
}
.legal-document-heading h3 {
  font-size: 16px;
  color: var(--navy);
  margin: 0 0 10px;
}
.legal-document-heading h3 small {
  font-size: 12px;
  color: var(--muted);
  font-weight: 400;
}
.legal-document-heading p {
  font-size: 13px;
  overflow-wrap: anywhere;
  margin: 0;
  color: var(--muted);
}
.legal-document-heading a {
  text-decoration: underline;
  text-underline-offset: 3px;
  color: var(--navy);
}
.legal-document-form label {
  font-size: 12px;
  font-weight: 600;
  color: var(--navy);
}
.legal-document-form input {
  display: block;
  max-width: 100%;
  margin-top: 10px;
  font-size: 13px;
}
.legal-document-actions {
  grid-column: 1/-1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.legal-document-actions [data-document-delete] {
  color: #a43131;
}
.legal-document-form button:disabled {
  opacity: 0.55;
  cursor: wait;
}
.inquiry-privacy {
  font-size: 11px !important;
  line-height: 1.6 !important;
  margin: 16px 0 0 !important;
}
.inquiry-privacy a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
@media (max-width: 1000px) {
  .site-footer .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .site-footer .footer-inner > div:first-child {
    grid-column: 1/-1;
  }
}
@media (max-width: 600px) {
  .site-footer .footer-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .site-footer .footer-links {
    grid-template-columns: 1fr 1fr;
  }
  .site-footer .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }
  .legal-document-form {
    grid-template-columns: 1fr;
  }
}
