:root {
  --blue: #246db4;
  --deep: #123e67;
  --ink: #182c3f;
  --muted: #647585;
  --surface: #f3f6f8;
  --line: #dce4ea;
  --green: #287657;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: #fff; font-family: Arial, Helvetica, sans-serif; font-size: 16px; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
.content-width { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.eyebrow { margin: 0 0 12px; font-size: .75rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.eyebrow.blue { color: var(--blue); }
.button, button { display: inline-flex; justify-content: center; align-items: center; min-height: 46px; padding: 0 18px; border: 0; color: #fff; background: var(--blue); font-weight: 700; cursor: pointer; }
.button:hover, button:hover { background: var(--deep); }
.button.secondary { color: var(--blue); background: #eaf2f9; }
.button.secondary:hover { color: white; background: var(--deep); }

.site-header { height: 86px; position: relative; z-index: 10; background: white; border-bottom: 1px solid var(--line); }
.header-inner { width: min(1240px, calc(100% - 40px)); height: 100%; margin: auto; display: flex; align-items: center; gap: 28px; }
.brand-link img { display: block; width: 210px; height: auto; }
.site-header nav { margin-left: auto; display: flex; gap: 26px; align-items: center; }
.site-header nav a { padding: 31px 0; color: #344556; font-size: .875rem; font-weight: 700; }
.site-header nav a:hover { color: var(--blue); }
.site-header nav .login-link { margin-left: 2px; padding: 11px 16px; color: white; background: var(--blue); }
.site-header nav .login-link:hover { color: white; background: var(--deep); }
.phone-link { padding-left: 16px; border-left: 1px solid var(--line); color: var(--blue); font-size: .875rem; font-weight: 700; }

.hero { min-height: 500px; position: relative; overflow: hidden; display: flex; align-items: center; color: #fff; background: url('/assets/brand/ghv-hero.jpg') center 52% / cover no-repeat; }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(8,37,65,.94), rgba(20,73,119,.78) 48%, rgba(17,67,110,.24)); }
.hero-content { position: relative; padding: 70px 0 52px; }
.hero h1 { max-width: 760px; margin: 0; font-size: clamp(2.7rem, 6vw, 4.6rem); line-height: .98; letter-spacing: -.035em; font-weight: 300; }
.hero-copy { max-width: 620px; margin: 22px 0 0; color: rgba(255,255,255,.88); font-size: 1.25rem; line-height: 1.55; }
.hero-metrics { width: fit-content; display: flex; margin-top: 46px; border: 1px solid rgba(255,255,255,.3); background: rgba(10,44,75,.32); backdrop-filter: blur(8px); }
.hero-metrics div { min-width: 145px; padding: 17px 24px; display: flex; flex-direction: column; border-right: 1px solid rgba(255,255,255,.22); }
.hero-metrics div:last-child { border: 0; }
.hero-metrics strong { font-size: 1.45rem; }
.hero-metrics span { margin-top: 3px; color: rgba(255,255,255,.72); font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; }
.auction-strip { background: white; border-bottom: 1px solid var(--line); box-shadow: 0 8px 30px rgba(25,52,77,.06); }
.strip-inner { min-height: 68px; display: flex; justify-content: space-between; align-items: center; gap: 24px; color: var(--muted); font-size: .875rem; }
.strip-inner > div { display: flex; align-items: center; gap: 12px; }
.strip-inner strong { color: var(--ink); }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: #f2a900; box-shadow: 0 0 0 5px rgba(242,169,0,.14); }

.catalog-section { padding-top: 78px; padding-bottom: 92px; }
.section-heading h2, .detail-content-grid h2 { margin: 0; font-size: clamp(2rem, 4vw, 2.85rem); line-height: 1.1; font-weight: 400; letter-spacing: -.025em; }
.filter-bar { margin-top: 38px; padding: 14px; display: grid; grid-template-columns: minmax(250px, 1fr) 220px 205px auto; gap: 10px; background: var(--surface); border: 1px solid var(--line); }
.filter-bar label { height: 48px; display: flex; align-items: center; padding: 0 14px; background: white; border: 1px solid #d2dce5; }
.filter-bar input, .filter-bar select { width: 100%; border: 0; outline: 0; background: transparent; color: var(--ink); }
.result-line { min-height: 62px; display: flex; justify-content: space-between; align-items: center; color: var(--muted); font-size: .82rem; }
.result-line strong { color: var(--ink); }
.catalog-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.catalog-card { min-width: 0; display: block; background: white; border: 1px solid var(--line); transition: transform .2s, box-shadow .2s, border-color .2s; }
.catalog-card:hover, .catalog-card:focus-visible { transform: translateY(-4px); border-color: #abc7df; box-shadow: 0 18px 44px rgba(22,54,82,.13); outline: none; }
.item-visual { height: 220px; position: relative; overflow: hidden; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #1d5e9c, #123d68) center / cover no-repeat; isolation: isolate; }
.item-visual[style]::before { content: ''; position: absolute; inset: 0; z-index: 0; background: linear-gradient(180deg, rgba(7,31,51,.08), rgba(7,31,51,.5)); }
.item-visual::after { content: ''; width: 260px; height: 260px; position: absolute; z-index: -1; right: -55px; top: -105px; border: 1px solid rgba(255,255,255,.22); border-radius: 50%; box-shadow: 0 0 0 42px rgba(255,255,255,.045), 0 0 0 84px rgba(255,255,255,.035); }
.visual-machine { background: linear-gradient(135deg, #405261, #1d3448); }
.visual-office { background: linear-gradient(135deg, #4b7187, #1f4a68); }
.visual-warehouse { background: linear-gradient(135deg, #2e6e78, #164450); }
.visual-property { background: linear-gradient(135deg, #316b9b, #1d4567); }
.visual-service { background: linear-gradient(135deg, #526273, #263849); }
.lot-watermark { position: absolute; z-index: 1; left: 20px; top: 14px; color: rgba(255,255,255,.25); font-size: 4rem; line-height: 1; font-weight: 800; letter-spacing: -.08em; text-shadow: 0 1px 10px rgba(0,0,0,.28); }
.visual-symbol { position: relative; z-index: 1; font-size: 2rem; font-weight: 300; letter-spacing: .12em; opacity: .92; }
.visual-caption { position: absolute; z-index: 1; left: 18px; bottom: 15px; color: rgba(255,255,255,.9); font-size: .75rem; }
.card-content { padding: 21px 22px 20px; }
.card-meta { display: flex; justify-content: space-between; gap: 12px; align-items: center; color: var(--blue); font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 800; }
.status-pill { display: inline-flex; padding: 6px 9px; border-radius: 99px; color: var(--green); background: #e8f4ee; font-size: .68rem; text-transform: uppercase; letter-spacing: .05em; }
.catalog-card h3 { min-height: 52px; margin: 16px 0 8px; font-size: 1.3rem; line-height: 1.25; }
.catalog-card p { min-height: 44px; margin: 0; color: var(--muted); font-size: .875rem; line-height: 1.55; }
.location { margin-top: 18px; color: #627180; font-size: .82rem; }
.card-footer { margin-top: 18px; padding-top: 17px; display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); }
.card-footer div { display: flex; flex-direction: column; gap: 3px; }
.card-footer span { color: var(--muted); font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; }
.card-footer strong { font-size: 1.12rem; }
.card-footer .arrow { width: 42px; height: 42px; display: grid; place-items: center; color: white; background: var(--blue); font-size: 1.35rem; }
.empty-state { padding: 65px 24px; text-align: center; background: var(--surface); border: 1px solid var(--line); }
.empty-state p { color: var(--muted); }

.detail-main { padding-top: 34px; padding-bottom: 88px; }
.back-link { display: inline-block; margin-bottom: 25px; color: var(--blue); font-size: .875rem; font-weight: 700; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(330px, .85fr); gap: 30px; }
.detail-grid > * { min-width: 0; }
.item-visual-large { height: 510px; }
.item-visual-large .lot-watermark { font-size: 8rem; }
.item-visual-large .visual-symbol { font-size: 4rem; }
.image-strip { padding: 12px; display: flex; gap: 10px; overflow-x: auto; background: white; border: 1px solid var(--line); border-top: 0; }
.gallery { width: 100%; min-width: 0; max-width: 100%; overflow: hidden; }
.gallery-main { width: 100%; max-width: 100%; height: clamp(300px, 42vw, 510px); position: relative; display: block; padding: 0; overflow: hidden; contain: layout paint; background: #e7edf2; cursor: zoom-in; }
.gallery-main > img { width: 100%; height: 100%; max-width: 100%; max-height: 100%; display: block; object-fit: contain; object-position: center; }
.gallery-zoom { position: absolute; right: 16px; bottom: 16px; padding: 9px 12px; color: white; background: rgba(10,34,54,.78); font-size: .75rem; font-weight: 700; }
.gallery-thumb { flex: 0 0 auto; width: 98px; height: 72px; padding: 3px; background: white; border: 2px solid transparent; opacity: .68; }
.gallery-thumb:hover { background: white; opacity: 1; }
.gallery-thumb.active { border-color: var(--blue); opacity: 1; }
.gallery-thumb img { width: 88px; height: 62px; display: block; object-fit: cover; }
.lightbox { width: 100vw; max-width: none; height: 100vh; height: 100dvh; max-height: none; margin: 0; padding: 0; overflow: hidden; color: white; background: rgba(5,16,26,.96); border: 0; }
.lightbox::backdrop { background: rgba(5,16,26,.82); }
.lightbox[open] { display: grid; grid-template-columns: 80px minmax(0, 1fr) 80px; place-items: center; }
.lightbox figure { width: 100%; height: 100%; min-width: 0; min-height: 0; margin: 0; padding: 38px 0 24px; overflow: hidden; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 12px; }
.lightbox figure > img { width: auto; height: auto; max-width: min(100%, calc(100vw - 190px)); max-height: calc(100vh - 180px); max-height: calc(100dvh - 180px); display: block; object-fit: contain; object-position: center; }
.lightbox figcaption { color: rgba(255,255,255,.82); font-size: .875rem; }
.lightbox-thumbs { max-width: min(760px, 90vw); padding: 4px; display: flex; gap: 8px; overflow-x: auto; }
.lightbox-thumb { flex: 0 0 auto; width: 72px; height: 54px; padding: 2px; background: rgba(255,255,255,.12); border: 2px solid transparent; opacity: .62; }
.lightbox-thumb:hover { background: rgba(255,255,255,.2); opacity: 1; }
.lightbox-thumb.active { border-color: #fff; opacity: 1; }
.lightbox-thumb img { width: 64px; height: 46px; display: block; object-fit: cover; }
.lightbox-close, .lightbox-nav { position: relative; z-index: 2; padding: 0; display: grid; place-items: center; color: white; background: rgba(255,255,255,.12); border-radius: 50%; }
.lightbox-close:hover, .lightbox-nav:hover { background: var(--blue); }
.lightbox-close { width: 48px; height: 48px; position: absolute; top: 18px; right: 20px; font-size: 2rem; }
.lightbox-nav { width: 52px; height: 52px; font-size: 2.4rem; }
.detail-summary { padding: 34px; background: white; border-top: 4px solid var(--blue); box-shadow: 0 12px 32px rgba(21,50,76,.08); }
.detail-meta { display: flex; justify-content: space-between; align-items: center; color: var(--blue); font-size: .75rem; font-weight: 800; text-transform: uppercase; }
.detail-summary h1 { margin: 24px 0 12px; font-size: clamp(2rem, 3.3vw, 2.8rem); line-height: 1.05; font-weight: 400; }
.detail-summary > p { color: var(--muted); line-height: 1.6; }
.detail-location { margin-top: 20px; color: #5c6b79; }
.price-box { margin-top: 28px; padding: 22px 0; display: flex; flex-direction: column; border-block: 1px solid var(--line); }
.price-box > span { color: var(--muted); font-size: .7rem; text-transform: uppercase; }
.price-box strong { margin: 5px 0; color: var(--blue); font-size: 1.8rem; }
.price-box small { color: #8a949e; }
.primary-action { margin-top: 22px; padding: 15px 17px; display: flex; justify-content: space-between; color: white; background: var(--blue); font-weight: 700; }
.detail-content-grid { margin-top: 30px; display: grid; grid-template-columns: 1.5fr .85fr; gap: 30px; }
.detail-content-grid > section, .facts-card { padding: 42px; background: #fff; border: 1px solid var(--line); }
.detail-content-grid section > p:not(.eyebrow) { color: var(--muted); line-height: 1.8; }
.facts-card { padding: 30px; }
.facts-card h2 { margin-top: 0; }
.facts-card > div { padding: 13px 0; display: flex; justify-content: space-between; gap: 20px; border-top: 1px solid var(--line); font-size: .875rem; }
.facts-card span { color: var(--muted); }
.facts-card > p { padding: 13px; color: var(--green); background: #edf7f2; font-size: .8rem; font-weight: 700; }

.login-page { min-height: calc(100vh - 190px); padding: 70px 20px; display: grid; place-items: center; background: linear-gradient(135deg, #edf4f9, #f8fafb); }
.login-card { width: min(440px, 100%); padding: 42px; background: white; border-top: 4px solid var(--blue); box-shadow: 0 20px 60px rgba(20,50,75,.14); }
.login-card img { width: 200px; margin-bottom: 38px; }
.login-card h1 { margin: 0; font-size: 2.3rem; font-weight: 400; }
.login-card > p:not(.eyebrow) { color: var(--muted); line-height: 1.6; }
.login-form { margin-top: 26px; display: grid; gap: 16px; }
.login-form label { display: grid; gap: 7px; font-size: .85rem; font-weight: 700; }
.login-form input { height: 48px; padding: 0 13px; border: 1px solid #cbd7e1; }
.login-form button { margin-top: 4px; }
.alert.error { padding: 12px 14px; color: #8a2830; background: #fff0f1; border: 1px solid #edc5c8; font-size: .875rem; }

.admin-main { padding-block: 55px 90px; }
.admin-heading { display: flex; justify-content: space-between; align-items: end; gap: 20px; }
.admin-heading h1 { margin: 0; font-size: 2.8rem; font-weight: 400; }
.admin-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.stat-grid { margin-top: 35px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px; }
.stat-grid div { padding: 24px; display: flex; flex-direction: column; background: var(--deep); color: white; }
.stat-grid strong { font-size: 2rem; }
.stat-grid span { margin-top: 5px; color: rgba(255,255,255,.72); font-size: .78rem; text-transform: uppercase; }
.admin-panel { margin-top: 26px; padding: 30px; background: white; border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(20,50,75,.06); }
.admin-panel h2 { margin: 0; font-size: 1.5rem; }
.admin-panel p { color: var(--muted); line-height: 1.6; }
.compact-panel { padding-top: 12px; }
.endpoint-link { text-align: right; color: var(--muted); font-size: .78rem; }
.endpoint-link a { color: var(--blue); }
.table-wrap { margin-top: 22px; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .84rem; }
th, td { padding: 13px 12px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; }
td small { display: block; margin-top: 5px; color: #a3343d; }
.manual-label { width: fit-content; padding: 3px 6px; color: #855c00; background: #fff2cc; font-size: .65rem; text-transform: uppercase; letter-spacing: .04em; }
.table-action { color: var(--blue); font-weight: 700; white-space: nowrap; }
.admin-search { margin-top: 30px; display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.admin-search input { min-height: 48px; padding: 0 14px; border: 1px solid #cbd7e1; }
.narrow-admin { max-width: 930px; }
.alert { margin-top: 18px; padding: 13px 15px; border: 1px solid; font-size: .875rem; }
.alert.success { color: #23684d; background: #edf8f3; border-color: #bcdcca; }
.edit-form { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.edit-form label, .upload-card label { display: grid; gap: 7px; color: #425465; font-size: .82rem; font-weight: 700; }
.edit-form label.full, .edit-form .full { grid-column: 1 / -1; }
.edit-form input, .edit-form textarea, .edit-form select, .upload-card input { width: 100%; padding: 12px 13px; color: var(--ink); background: #fff; border: 1px solid #cbd7e1; outline: 0; }
.edit-form input:focus, .edit-form textarea:focus, .edit-form select:focus, .upload-card input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(36,109,180,.1); }
.edit-form textarea { resize: vertical; line-height: 1.55; }
.form-actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.danger-outline { color: #9b2832; background: white; border: 1px solid #dfb5b9; }
.danger-outline:hover { color: white; background: #9b2832; }
.upload-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(250px, .65fr); gap: 24px; }
.upload-card, .upload-help { margin-top: 28px; }
.upload-card h2, .upload-help h2 { margin-top: 0; }
.upload-zone { min-height: 145px; margin: 22px 0 16px; place-items: center; align-content: center; color: var(--blue) !important; background: #f5faff; border: 2px dashed #aec8df; cursor: pointer; }
.upload-zone input { width: auto; max-width: 90%; border: 0; background: transparent; }
.selected-files { margin: -6px 0 16px; padding: 10px 12px; display: block; color: #425465; background: #edf4fa; font-size: .78rem; line-height: 1.5; }
.upload-progress { margin-top: 12px; padding: 11px 13px; display: block; color: #245b85; background: #edf5fb; font-size: .8rem; }
.upload-progress[hidden] { display: none; }
.upload-card details { margin: 16px 0; padding: 14px; background: var(--surface); }
.upload-card summary { color: var(--blue); font-weight: 700; cursor: pointer; }
.upload-card details label { margin-top: 14px; }
.upload-card > small { margin-top: 14px; display: block; color: var(--muted); line-height: 1.5; }
.upload-help div { padding: 15px 0; display: flex; flex-direction: column; gap: 4px; border-top: 1px solid var(--line); }
.upload-help span { color: var(--muted); font-size: .78rem; }
.image-admin-grid { margin-top: 22px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.image-admin-grid article { display: grid; grid-template-columns: 100px 1fr; border: 1px solid var(--line); background: var(--surface); }
.image-admin-grid img { width: 100px; height: 100%; min-height: 125px; object-fit: cover; }
.image-admin-grid article > div { min-width: 0; padding: 12px; display: flex; flex-direction: column; gap: 5px; }
.image-admin-grid span, .image-admin-grid small { overflow: hidden; color: var(--muted); font-size: .72rem; text-overflow: ellipsis; white-space: nowrap; }
.image-admin-grid form { margin-top: auto; }
.text-danger { min-height: auto; padding: 0; color: #9b2832; background: transparent; font-size: .75rem; }
.text-danger:hover { color: #6e141c; background: transparent; }

footer { padding: 45px 0; background: #112b42; color: rgba(255,255,255,.72); }
.footer-grid { display: grid; grid-template-columns: 120px 1.5fr 1fr; gap: 50px; font-size: .82rem; line-height: 1.8; }
.footer-grid > img { width: 74px; }
.footer-grid > div { display: flex; flex-direction: column; }
.footer-grid strong { color: white; }

@media (max-width: 900px) {
  .site-header nav a:not(.login-link):not(.admin-link), .phone-link { display: none; }
  .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filter-bar { grid-template-columns: 1fr 1fr; }
  .search-field { grid-column: 1 / -1; }
  .detail-grid, .detail-content-grid { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .upload-layout { grid-template-columns: 1fr; }
  .image-admin-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 620px) {
  .content-width, .header-inner { width: min(100% - 28px, 1180px); }
  .site-header { height: 72px; }
  .brand-link img { width: 155px; }
  .site-header nav { gap: 15px; }
  .site-header nav a { padding: 25px 0; font-size: .75rem; }
  .hero { min-height: 490px; }
  .hero-content { padding: 54px 0 35px; }
  .hero h1 { font-size: 2.75rem; }
  .hero-copy { font-size: 1.05rem; }
  .hero-metrics { width: 100%; }
  .hero-metrics div { min-width: 0; flex: 1; padding: 14px 10px; }
  .hero-metrics strong { font-size: 1.15rem; }
  .hero-metrics span { font-size: .55rem; }
  .strip-inner { padding-block: 15px; flex-direction: column; align-items: flex-start; }
  .catalog-section { padding-block: 58px; }
  .filter-bar { grid-template-columns: 1fr; }
  .search-field { grid-column: auto; }
  .result-line { padding-block: 15px; flex-direction: column; align-items: flex-start; }
  .catalog-grid { grid-template-columns: 1fr; }
  .item-visual-large, .gallery-main { height: clamp(260px, 70vw, 360px); }
  .lightbox[open] { grid-template-columns: 54px minmax(0, 1fr) 54px; }
  .lightbox-nav { width: 42px; height: 42px; }
  .lightbox figure > img { max-width: calc(100vw - 116px); max-height: calc(100vh - 170px); max-height: calc(100dvh - 170px); }
  .detail-summary, .detail-content-grid > section, .facts-card { padding: 25px 21px; }
  .login-card { padding: 32px 24px; }
  .admin-heading { align-items: flex-start; flex-direction: column; }
  .edit-form { grid-template-columns: 1fr; }
  .edit-form label.full, .edit-form .full { grid-column: auto; }
  .stat-grid { grid-template-columns: 1fr; }
  .admin-panel { padding: 22px 16px; }
  .footer-grid { grid-template-columns: 80px 1fr; gap: 24px; }
  .footer-grid > div:last-child { display: none; }
  .image-admin-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
