/* =========================================================================
   Umenie – galéria a predaj obrazov
   Svetlý, moderný, galerijný dizajn
   ========================================================================= */

:root {
  --bg:        #fbf9f6;
  --bg-soft:   #f3efe9;
  --surface:   #ffffff;
  --ink:       #232020;
  --ink-soft:  #6b6360;
  --line:      #e7e1d8;
  --accent:    #b06a45;   /* hlinená / terakota */
  --accent-dk: #8f5234;
  --gold:      #c8a26a;
  --shadow:    0 18px 50px rgba(40, 30, 20, 0.10);
  --shadow-sm: 0 6px 22px rgba(40, 30, 20, 0.08);
  --radius:    16px;
  --radius-sm: 10px;
  --serif: 'Playfair Display', Georgia, serif;
  --sans:  'Inter', system-ui, -apple-system, sans-serif;
  --maxw: 1180px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.15; letter-spacing: -0.01em; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.eyebrow {
  font-size: 12.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 14px;
}

.section { padding: 100px 0; }
.section--soft { background: var(--bg-soft); }

.section-head { max-width: 640px; margin: 0 auto 56px; text-align: center; }
.section-head h2 { font-size: clamp(30px, 4vw, 46px); margin-bottom: 14px; }
.section-head p { color: var(--ink-soft); font-size: 17px; }

/* ---------- Tlačidlá ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--sans); font-size: 15px; font-weight: 500;
  padding: 13px 26px; border-radius: 100px; border: 1px solid transparent;
  cursor: pointer; transition: all .25s ease; white-space: nowrap;
}
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-dk); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.btn--block { width: 100%; justify-content: center; }
.btn--sm { padding: 9px 16px; font-size: 13.5px; }

/* ---------- Navigácia ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 20px 0; transition: all .3s ease;
}
.nav.scrolled {
  background: rgba(251, 249, 246, 0.88);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  padding: 13px 0; border-bottom: 1px solid var(--line);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; }
.nav__brand { font-family: var(--serif); font-size: 23px; font-weight: 600; letter-spacing: -0.01em; }
.nav__links { display: flex; align-items: center; gap: 34px; }
.nav__links a { font-size: 15px; color: var(--ink-soft); transition: color .2s; position: relative; }
.nav__links a:hover { color: var(--ink); }
.nav__links a::after {
  content: ''; position: absolute; left: 0; bottom: -5px; width: 0; height: 1.5px;
  background: var(--accent); transition: width .25s ease;
}
.nav__links a:hover::after { width: 100%; }
.nav__toggle { display: none; background: none; border: none; cursor: pointer; font-size: 26px; color: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh; display: flex; align-items: center; position: relative;
  padding: 120px 0 80px; overflow: hidden;
}
.hero__bg {
  position: absolute; inset: 0; z-index: 0;
  background-size: cover; background-position: center;
}
.hero__bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(251,249,246,.96) 0%, rgba(251,249,246,.78) 45%, rgba(251,249,246,.30) 100%); }
.hero__inner { position: relative; z-index: 1; max-width: 680px; }
.hero h1 { font-size: clamp(40px, 6.5vw, 76px); line-height: 1.04; margin-bottom: 24px; }
.hero h1 .accent { color: var(--accent); font-style: italic; }
.hero p { font-size: clamp(17px, 2vw, 20px); color: var(--ink-soft); max-width: 520px; margin-bottom: 36px; }
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero__scroll { position: absolute; bottom: 34px; left: 50%; transform: translateX(-50%); z-index: 1; color: var(--ink-soft); font-size: 13px; letter-spacing: .15em; text-transform: uppercase; animation: bob 2.4s ease-in-out infinite; }
@keyframes bob { 0%,100%{ transform: translate(-50%,0);} 50%{ transform: translate(-50%,8px);} }

/* ---------- Galéria ---------- */
.gallery-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 30px;
}
.card {
  background: var(--surface); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow-sm); transition: transform .35s ease, box-shadow .35s ease;
  display: flex; flex-direction: column; cursor: pointer;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.card__media { position: relative; aspect-ratio: 4/5; background: var(--bg-soft); overflow: hidden; }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.card:hover .card__media img { transform: scale(1.05); }
.card__media--empty { display: flex; align-items: center; justify-content: center; color: var(--line); font-size: 44px; }
.badge {
  position: absolute; top: 14px; left: 14px; padding: 6px 13px; border-radius: 100px;
  font-size: 12px; font-weight: 600; letter-spacing: .03em; background: #fff; color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.badge--sold { background: var(--ink); color: #fff; }
.badge--reserved { background: var(--gold); color: #fff; }
.card__body { padding: 22px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.card__title { font-family: var(--serif); font-size: 22px; margin-bottom: 6px; }
.card__meta { font-size: 13.5px; color: var(--ink-soft); margin-bottom: 12px; }
.card__desc { font-size: 14.5px; color: var(--ink-soft); margin-bottom: 18px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card__foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card__price { font-family: var(--serif); font-size: 21px; font-weight: 600; }
.card__price small { font-size: 13px; color: var(--ink-soft); font-family: var(--sans); }

.empty-note { text-align: center; color: var(--ink-soft); padding: 60px 0; grid-column: 1 / -1; }

/* ---------- O mne ---------- */
.about { display: grid; grid-template-columns: 0.85fr 1fr; gap: 64px; align-items: center; }
.about__img { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 4/5; background: var(--bg-soft); }
.about__img img { width: 100%; height: 100%; object-fit: cover; }
.about__img--empty { display: flex; align-items: center; justify-content: center; color: var(--line); font-size: 60px; }
.about h2 { font-size: clamp(30px, 4vw, 46px); margin-bottom: 22px; }
.about__text { color: var(--ink-soft); font-size: 17px; }
.about__text p { margin-bottom: 16px; }

/* ---------- Kontakt ---------- */
.contact { display: grid; grid-template-columns: 1fr 1.1fr; gap: 60px; align-items: start; }
.contact__info h2 { font-size: clamp(30px, 4vw, 46px); margin-bottom: 18px; }
.contact__info p { color: var(--ink-soft); font-size: 17px; margin-bottom: 30px; }
.contact__list { list-style: none; display: flex; flex-direction: column; gap: 18px; }
.contact__list li { display: flex; gap: 14px; align-items: center; font-size: 16px; }
.contact__list .ico { width: 42px; height: 42px; flex: none; border-radius: 50%; background: var(--bg-soft); display: flex; align-items: center; justify-content: center; font-size: 18px; color: var(--accent); }
.contact__list .lbl { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); display: block; }
.socials { display: flex; gap: 12px; margin-top: 30px; }
.socials a { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); display: flex; align-items: center; justify-content: center; transition: all .25s; }
.socials a:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ---------- Formuláre ---------- */
.form { background: var(--surface); padding: 36px; border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.form__row { margin-bottom: 18px; }
.form__row--2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
label { display: block; font-size: 13.5px; font-weight: 500; margin-bottom: 7px; color: var(--ink); }
input, textarea, select {
  width: 100%; font-family: var(--sans); font-size: 15px; color: var(--ink);
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 12px 14px; transition: border-color .2s, box-shadow .2s;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(176,106,69,.12); }
textarea { resize: vertical; min-height: 120px; }
.hp { position: absolute; left: -9999px; }

.form__note { font-size: 13px; color: var(--ink-soft); margin-top: 14px; text-align: center; }
.form-msg { padding: 13px 16px; border-radius: var(--radius-sm); font-size: 14.5px; margin-bottom: 18px; display: none; }
.form-msg.show { display: block; }
.form-msg--ok { background: #e9f5ec; color: #1f7a3d; }
.form-msg--err { background: #fbeaea; color: #b3261e; }

/* ---------- Modál (objednávka / detail) ---------- */
.modal { position: fixed; inset: 0; z-index: 200; display: none; align-items: center; justify-content: center; padding: 24px; }
.modal.open { display: flex; }
.modal__overlay { position: absolute; inset: 0; background: rgba(30,22,16,.55); backdrop-filter: blur(3px); }
.modal__box { position: relative; background: var(--bg); border-radius: var(--radius); max-width: 920px; width: 100%; max-height: 90vh; overflow: auto; box-shadow: var(--shadow); }
.modal__close { position: absolute; top: 16px; right: 16px; z-index: 3; width: 40px; height: 40px; border-radius: 50%; border: none; background: #fff; cursor: pointer; font-size: 20px; box-shadow: var(--shadow-sm); }
.detail { display: grid; grid-template-columns: 1fr 1fr; }
.detail__media { background: var(--bg-soft); min-height: 320px; }
.detail__media img { width: 100%; height: 100%; object-fit: cover; }
.detail__body { padding: 44px 40px; }
.detail__body h3 { font-size: 30px; margin-bottom: 8px; }
.detail__meta { color: var(--ink-soft); margin-bottom: 20px; }
.detail__price { font-family: var(--serif); font-size: 26px; margin-bottom: 22px; }
.detail__desc { color: var(--ink-soft); margin-bottom: 28px; white-space: pre-wrap; }

/* ---------- Footer ---------- */
.footer { background: var(--ink); color: #d9d2cb; padding: 50px 0 34px; text-align: center; }
.footer__brand { font-family: var(--serif); font-size: 24px; color: #fff; margin-bottom: 10px; }
.footer p { font-size: 14px; opacity: .8; }
.footer a { color: var(--gold); }
.footer__bottom { margin-top: 26px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.12); font-size: 13px; opacity: .65; }

/* ---------- Animácie pri scrolle ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Responzív ---------- */
@media (max-width: 900px) {
  .about, .contact, .detail { grid-template-columns: 1fr; gap: 36px; }
  .detail__media { min-height: 280px; aspect-ratio: 4/3; }
  .nav__links {
    position: fixed; inset: 0 0 0 auto; width: min(78vw, 320px); flex-direction: column;
    background: var(--bg); padding: 96px 32px; gap: 22px; align-items: flex-start;
    transform: translateX(100%); transition: transform .3s ease; box-shadow: var(--shadow); z-index: 99;
  }
  .nav__links.open { transform: none; }
  .nav__links a { font-size: 18px; }
  .nav__toggle { display: block; z-index: 101; }
}
@media (max-width: 560px) {
  .section { padding: 70px 0; }
  .form__row--2 { grid-template-columns: 1fr; }
  .form { padding: 26px; }
  .detail__body { padding: 30px 24px; }
}

/* =========================================================================
   ADMIN
   ========================================================================= */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.login-card { background: var(--surface); padding: 44px 40px; border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; max-width: 400px; }
.login-card h1 { font-size: 28px; margin-bottom: 6px; }
.login-card p { color: var(--ink-soft); font-size: 14.5px; margin-bottom: 26px; }

.admin { display: none; min-height: 100vh; }
.admin.show { display: grid; grid-template-columns: 250px 1fr; }
.sidebar { background: var(--ink); color: #cfc8c1; padding: 28px 18px; display: flex; flex-direction: column; }
.sidebar__brand { font-family: var(--serif); font-size: 22px; color: #fff; padding: 0 12px 24px; }
.sidebar__nav { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.sidebar__nav button {
  text-align: left; background: none; border: none; color: #cfc8c1; font-family: var(--sans);
  font-size: 15px; padding: 12px 14px; border-radius: var(--radius-sm); cursor: pointer;
  transition: all .2s; display: flex; align-items: center; gap: 10px;
}
.sidebar__nav button:hover { background: rgba(255,255,255,.07); color: #fff; }
.sidebar__nav button.active { background: var(--accent); color: #fff; }
.sidebar__nav .count { margin-left: auto; background: rgba(255,255,255,.18); border-radius: 100px; padding: 1px 9px; font-size: 12px; }
.sidebar__foot { padding-top: 18px; border-top: 1px solid rgba(255,255,255,.12); display: flex; flex-direction: column; gap: 8px; }
.sidebar__foot a, .sidebar__foot button { font-size: 13.5px; color: #cfc8c1; background: none; border: none; cursor: pointer; text-align: left; padding: 6px 12px; border-radius: 8px; }
.sidebar__foot a:hover, .sidebar__foot button:hover { background: rgba(255,255,255,.07); color: #fff; }

.admin-main { padding: 40px 44px; overflow: auto; max-height: 100vh; background: var(--bg); }
.admin-main h2 { font-size: 28px; margin-bottom: 4px; }
.admin-main .sub { color: var(--ink-soft); margin-bottom: 28px; font-size: 14.5px; }
.panel { display: none; }
.panel.active { display: block; animation: fade .3s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(8px);} to { opacity: 1; } }

.toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; gap: 14px; flex-wrap: wrap; }

.card-admin { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; margin-bottom: 22px; }
.card-admin h3 { font-family: var(--serif); font-size: 20px; margin-bottom: 18px; }

/* admin zoznam diel */
.art-row { display: flex; gap: 16px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px; margin-bottom: 12px; }
.art-row__thumb { width: 64px; height: 64px; border-radius: 8px; object-fit: cover; background: var(--bg-soft); flex: none; }
.art-row__info { flex: 1; min-width: 0; }
.art-row__info strong { font-size: 15.5px; }
.art-row__info .m { font-size: 13px; color: var(--ink-soft); }
.art-row__actions { display: flex; gap: 8px; }
.pill { font-size: 11.5px; padding: 3px 10px; border-radius: 100px; font-weight: 600; }
.pill--available { background: #e9f5ec; color: #1f7a3d; }
.pill--reserved { background: #fbf0db; color: #946100; }
.pill--sold { background: #efe9e5; color: #6b6360; }
.icon-btn { width: 36px; height: 36px; border-radius: 8px; border: 1px solid var(--line); background: #fff; cursor: pointer; font-size: 15px; transition: all .2s; }
.icon-btn:hover { border-color: var(--accent); color: var(--accent); }
.icon-btn--danger:hover { border-color: #c0392b; color: #c0392b; }

/* objednávky */
.order-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 18px 20px; margin-bottom: 14px; }
.order-card.unread { border-left: 3px solid var(--accent); }
.order-card__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; gap: 10px; flex-wrap: wrap; }
.order-card__head strong { font-size: 16px; }
.order-card__date { font-size: 12.5px; color: var(--ink-soft); }
.order-card__meta { font-size: 13.5px; color: var(--ink-soft); margin-bottom: 8px; }
.order-card__meta a { color: var(--accent); }
.order-card__msg { font-size: 14.5px; white-space: pre-wrap; background: var(--bg); padding: 12px 14px; border-radius: 8px; }
.order-card__actions { margin-top: 12px; display: flex; gap: 8px; }
.tag { display: inline-block; font-size: 12px; background: var(--bg-soft); padding: 2px 9px; border-radius: 6px; color: var(--accent); margin-left: 6px; }

.help { font-size: 13px; color: var(--ink-soft); margin-top: 6px; }
.upload-prev { margin-top: 12px; }
.upload-prev img { width: 130px; border-radius: 8px; border: 1px solid var(--line); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.checkbox { display: flex; align-items: center; gap: 9px; }
.checkbox input { width: auto; }
.muted { color: var(--ink-soft); font-size: 14px; }

@media (max-width: 760px) {
  .admin.show { grid-template-columns: 1fr; }
  .sidebar { flex-direction: row; flex-wrap: wrap; align-items: center; padding: 14px; }
  .sidebar__brand { padding: 0 10px 0 4px; }
  .sidebar__nav { flex-direction: row; flex-wrap: wrap; flex: 1; }
  .sidebar__foot { flex-direction: row; border: none; padding: 0; }
  .admin-main { padding: 24px 18px; max-height: none; }
  .grid-2 { grid-template-columns: 1fr; }
}
