:root {
  --bg: #f5eee6;
  --bg-deep: #e7dac9;
  --surface: rgba(255, 250, 245, 0.74);
  --surface-strong: rgba(255, 248, 240, 0.92);
  --text: #2f241f;
  --muted: #756258;
  --accent: #a35b3e;
  --accent-dark: #7c4029;
  --line: rgba(86, 57, 43, 0.14);
  --shadow: 0 22px 60px rgba(69, 43, 31, 0.16);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Cormorant Garamond', serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(235, 196, 160, 0.58), transparent 30%),
    radial-gradient(circle at top right, rgba(177, 115, 83, 0.2), transparent 28%),
    linear-gradient(180deg, #f6efe8 0%, #efe3d6 54%, #eadfce 100%);
}

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

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

.page-shell {
  min-height: 100vh;
  overflow: hidden;
}

.hero,
.about-section,
.catalog-section,
.footer {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
}

.hero {
  position: relative;
  padding: 28px 0 84px;
}

.hero::before,
.hero::after {
  content: '';
  position: absolute;
  border-radius: 999px;
  filter: blur(6px);
  z-index: -1;
}

.hero::before {
  top: 110px;
  right: -120px;
  width: 360px;
  height: 360px;
  background: radial-gradient(circle, rgba(163, 91, 62, 0.24), transparent 70%);
}

.hero::after {
  left: -140px;
  top: 160px;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(240, 225, 207, 0.8), transparent 70%);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 18px;
  background: rgba(255, 249, 242, 0.5);
  border: 1px solid var(--line);
  border-radius: 999px;
  backdrop-filter: blur(16px);
  box-shadow: 0 14px 30px rgba(96, 63, 49, 0.08);
}

.brand-mini,
.topbar-links a,
.eyebrow,
.section-label,
.about-details span,
.footer-note {
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.brand-mini {
  font-size: 0.95rem;
}

.topbar-links {
  display: flex;
  gap: 24px;
  font-size: 1rem;
}

.cart-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 4px 4px 0;
}

.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
  padding: 0 7px;
  border-radius: 999px;
  color: #fff8f2;
  background: var(--accent);
  font-size: 0.9rem;
  line-height: 1;
  box-shadow: 0 8px 18px rgba(124, 64, 41, 0.24);
}

.cart-badge[data-empty='true'] {
  color: var(--muted);
  background: rgba(124, 64, 41, 0.12);
  box-shadow: none;
}

.cart-button.is-flash .cart-badge {
  animation: cart-pop 520ms ease;
}

.hero-content {
  max-width: 720px;
  padding: 92px 0 36px;
  animation: fade-up 900ms ease both;
}

.eyebrow,
.section-label {
  font-size: 0.82rem;
  color: var(--muted);
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  margin-top: 14px;
  font-family: 'Imperial Script', cursive;
  font-size: clamp(4.8rem, 12vw, 8.8rem);
  font-weight: 400;
  line-height: 0.9;
}

.subtitle {
  margin-top: 8px;
  font-size: clamp(1.5rem, 3vw, 2.15rem);
  color: var(--accent-dark);
}

.hero-text {
  max-width: 540px;
  margin-top: 24px;
  font-size: 1.35rem;
  line-height: 1.45;
}

.hero-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 32px;
  padding: 16px 28px;
  font-size: 1.1rem;
  color: #fff8f2;
  background: linear-gradient(135deg, var(--accent) 0%, #8b4d33 100%);
  border-radius: 999px;
  box-shadow: 0 18px 32px rgba(124, 64, 41, 0.25);
  transition: transform 200ms ease, box-shadow 200ms ease;
}

.hero-button:hover,
.hero-button:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 22px 36px rgba(124, 64, 41, 0.32);
}

.about-section {
  display: grid;
  grid-template-columns: minmax(280px, 0.88fr) minmax(0, 1.12fr);
  gap: 44px;
  align-items: center;
  padding: 30px 0 86px;
}

.portrait-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  overflow: visible;
  min-height: 300px;
}

.portrait-photo {
  position: absolute;
  inset: 10%;
  width: 80%;
  height: 80%;
  object-fit: cover;
  border-radius: 4px;
  filter: saturate(0.95) contrast(1.03);
}

.portrait-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  pointer-events: none;
  z-index: 1;
  filter: drop-shadow(0 18px 40px rgba(70, 41, 18, 0.28));
}

.about-copy {
  padding: 34px;
  background: var(--surface);
  border: 1px solid rgba(113, 82, 62, 0.14);
  border-radius: 32px;
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
}

.about-copy h2,
.section-heading h2,
.footer h2 {
  margin-top: 12px;
  font-size: clamp(2.5rem, 4vw, 4rem);
  line-height: 0.98;
}

.about-copy p,
.section-heading p,
.footer-note,
.card-description {
  margin-top: 18px;
  font-size: 1.26rem;
  line-height: 1.5;
  color: var(--muted);
}

.about-details {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.about-details span {
  display: inline-flex;
  padding: 10px 16px;
  font-size: 0.84rem;
  border: 1px solid rgba(124, 64, 41, 0.16);
  border-radius: 999px;
  background: rgba(255, 252, 248, 0.66);
}

.catalog-section {
  padding: 0 0 92px;
}

.section-heading {
  max-width: 740px;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 26px;
  margin-top: 36px;
}

.art-card {
  overflow: hidden;
  background: var(--surface-strong);
  border: 1px solid rgba(99, 72, 57, 0.14);
  border-radius: 28px;
  box-shadow: var(--shadow);
  transform: translateY(20px);
  opacity: 0;
  animation: reveal 700ms ease forwards;
}

.art-card:nth-child(2) {
  animation-delay: 90ms;
}

.art-card:nth-child(3) {
  animation-delay: 180ms;
}

.art-card:nth-child(4) {
  animation-delay: 270ms;
}

.art-card:nth-child(5) {
  animation-delay: 360ms;
}

.art-card:nth-child(6) {
  animation-delay: 450ms;
}

.card-image {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 18px;
  border: 0;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 248, 240, 0.9), transparent 60%),
    linear-gradient(160deg, #efe3d6 0%, #e2d2bd 100%);
  aspect-ratio: 4 / 4.6;
  overflow: hidden;
  cursor: zoom-in;
  font: inherit;
  color: inherit;
}

.card-image img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  box-shadow: 0 14px 30px rgba(69, 43, 31, 0.22);
  transition: transform 280ms ease;
}

.art-card:hover .card-image img,
.card-image:focus-visible img {
  transform: scale(1.03);
}

.card-image:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.card-image-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  padding: 6px 12px;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  color: #fff8f2;
  background: rgba(47, 36, 31, 0.55);
  border-radius: 999px;
  backdrop-filter: blur(6px);
}

/* --- Lightbox --- */

.lightbox[hidden] {
  display: none;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(28, 18, 12, 0.78);
  backdrop-filter: blur(8px);
}

.lightbox-dialog {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: min(1000px, 100%);
  max-height: 92vh;
  padding: 22px;
  background: var(--surface-strong);
  border-radius: 24px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}

.lightbox-header {
  display: flex;
  align-items: center;
  gap: 16px;
}

.lightbox-title {
  margin: 0;
  font-size: 1.6rem;
}

.lightbox-counter {
  font-size: 0.95rem;
  color: var(--muted);
  letter-spacing: 0.08em;
}

.lightbox-close {
  margin-left: auto;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 999px;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  background: rgba(124, 64, 41, 0.1);
  color: var(--text);
}

.lightbox-close:hover {
  background: rgba(124, 64, 41, 0.2);
}

.lightbox-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  flex: 1;
  background: #1a1108;
  border-radius: 16px;
  overflow: hidden;
}

.lightbox-image {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  font-size: 1.2rem;
  cursor: pointer;
  background: rgba(255, 248, 240, 0.9);
  color: var(--text);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.3);
}

.lightbox-nav:hover {
  background: #fff;
}

.lightbox-prev {
  left: 14px;
}

.lightbox-next {
  right: 14px;
}

.lightbox-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.lightbox-thumb {
  width: 70px;
  height: 70px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  background: #1a1108;
  transition: border-color 180ms ease, transform 180ms ease;
}

.lightbox-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.lightbox-thumb.is-active {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.card-content {
  padding: 22px 22px 24px;
}

.card-title-row,
.card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.card-title {
  font-size: 2rem;
}

.card-size {
  font-size: 1rem;
  color: var(--muted);
}

.card-price {
  display: inline-flex;
  padding: 9px 14px;
  font-size: 1.05rem;
  border-radius: 999px;
  background: rgba(163, 91, 62, 0.1);
  color: var(--accent-dark);
}

.card-actions {
  margin-top: 20px;
}

.buy-button {
  border: 0;
  cursor: pointer;
  padding: 14px 18px;
  font: inherit;
  font-size: 1.12rem;
  color: #fff8f2;
  background: linear-gradient(135deg, var(--accent) 0%, #7c4029 100%);
  border-radius: 16px;
  transition: transform 200ms ease, opacity 200ms ease;
}

.buy-button:hover,
.buy-button:focus-visible {
  transform: translateY(-2px);
  opacity: 0.94;
}

.card-image-placeholder,
.catalog-empty {
  color: var(--muted);
  font-size: 1.2rem;
}

/* --- Floating mini cart --- */

.floating-cart {
  position: fixed;
  right: max(18px, env(safe-area-inset-right));
  bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 80;
  width: min(390px, calc(100vw - 28px));
  color: var(--text);
  filter: drop-shadow(0 24px 44px rgba(45, 29, 21, 0.26));
}

.floating-cart-head {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
  width: 100%;
  padding: 13px 15px;
  border: 1px solid rgba(124, 64, 41, 0.18);
  border-radius: 24px;
  background: rgba(255, 249, 242, 0.9);
  color: inherit;
  cursor: pointer;
  text-align: left;
  font: inherit;
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 32px rgba(86, 57, 43, 0.12);
}

.floating-cart-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: #fff8f2;
  font-size: 1.25rem;
}

.floating-cart-head b,
.floating-cart-head small {
  display: block;
}

.floating-cart-head b {
  font-size: 1.28rem;
  line-height: 1.1;
}

.floating-cart-head small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.98rem;
}

.floating-cart-body {
  display: none;
  margin-top: 10px;
  padding: 14px;
  border: 1px solid rgba(124, 64, 41, 0.14);
  border-radius: 28px;
  background:
    radial-gradient(circle at top right, rgba(228, 185, 145, 0.34), transparent 45%),
    rgba(255, 250, 245, 0.96);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.floating-cart.is-open .floating-cart-body {
  display: block;
  animation: fade-up 260ms ease both;
}

.floating-cart.is-pulsing {
  animation: cart-float-pop 620ms ease;
}

.floating-cart-items {
  display: grid;
  gap: 10px;
  max-height: min(48vh, 360px);
  overflow: auto;
  padding-right: 4px;
}

.floating-cart-item {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr) auto;
  gap: 11px;
  align-items: center;
  padding: 9px;
  border: 1px solid rgba(124, 64, 41, 0.1);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.52);
}

.floating-cart-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 62px;
  height: 62px;
  overflow: hidden;
  border-radius: 16px;
  background: #eadfce;
}

.floating-cart-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.floating-cart-copy {
  min-width: 0;
}

.floating-cart-copy strong,
.floating-cart-copy span {
  display: block;
}

.floating-cart-copy strong {
  overflow: hidden;
  font-size: 1.08rem;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.floating-cart-copy span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.95rem;
}

.floating-cart-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
}

.floating-cart-controls button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  padding: 0 9px;
  border: 1px solid rgba(124, 64, 41, 0.14);
  border-radius: 999px;
  background: rgba(255, 249, 242, 0.9);
  color: var(--text);
  cursor: pointer;
  font: inherit;
}

.floating-cart-remove {
  color: var(--accent-dark) !important;
}

.floating-cart-price {
  align-self: start;
  padding-top: 4px;
  color: var(--accent-dark);
  font-weight: 700;
  white-space: nowrap;
}

.floating-cart-empty {
  margin: 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.35;
}

.floating-cart-footer {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(124, 64, 41, 0.12);
  font-size: 1.1rem;
}

.floating-cart-footer strong {
  color: var(--accent-dark);
  font-size: 1.45rem;
}

.floating-cart-checkout,
.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  margin-top: 14px;
  padding: 14px 18px;
  border: 0;
  border-radius: 17px;
  color: #fff8f2;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  box-shadow: 0 16px 28px rgba(124, 64, 41, 0.22);
  cursor: pointer;
  font: inherit;
  font-size: 1.14rem;
  transition: transform 200ms ease, opacity 200ms ease, box-shadow 200ms ease;
}

.floating-cart-checkout:hover,
.floating-cart-checkout:focus-visible,
.primary-button:hover,
.primary-button:focus-visible {
  transform: translateY(-2px);
  opacity: 0.96;
  box-shadow: 0 20px 34px rgba(124, 64, 41, 0.28);
}

/* --- Cart page --- */

.hero-compact {
  padding-bottom: 46px;
}

.cart-page-heading {
  max-width: 760px;
  padding: 72px 0 14px;
}

.cart-page-title {
  font-size: clamp(4.4rem, 10vw, 7.8rem);
}

.cart-page-subtitle {
  max-width: 620px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 1.32rem;
  line-height: 1.45;
}

.return-link {
  display: inline-flex;
  align-items: center;
  margin-top: 24px;
  color: var(--accent-dark);
  font-size: 1.12rem;
}

.cart-page {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto 70px;
}

.cart-page-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, 0.95fr);
  gap: 26px;
  align-items: start;
}

.cart-column,
.checkout-column,
.checkout-success {
  border: 1px solid rgba(99, 72, 57, 0.13);
  border-radius: 34px;
  background:
    linear-gradient(180deg, rgba(255, 252, 248, 0.88), rgba(247, 237, 225, 0.88)),
    var(--surface-strong);
  box-shadow: var(--shadow);
}

.cart-column,
.checkout-column {
  padding: 26px;
}

.checkout-column {
  position: sticky;
  top: 18px;
}

.cart-block-head {
  margin-bottom: 20px;
}

.block-title {
  margin: 6px 0 0;
  font-size: clamp(2.1rem, 3.2vw, 3.25rem);
  line-height: 1;
}

.cart-list {
  display: grid;
  gap: 16px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.cart-item {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(124, 64, 41, 0.12);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.52);
}

.cart-item-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 112px;
  height: 112px;
  overflow: hidden;
  border-radius: 20px;
  background: linear-gradient(160deg, #efe3d6 0%, #e2d2bd 100%);
  box-shadow: inset 0 0 0 1px rgba(124, 64, 41, 0.08);
}

.cart-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item-title {
  font-size: 1.55rem;
  font-weight: 700;
  line-height: 1.08;
}

.cart-item-meta {
  margin-top: 5px;
  color: var(--muted);
  font-size: 1.05rem;
}

.cart-item-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
}

.cart-item-controls button,
.link-button {
  border: 1px solid rgba(124, 64, 41, 0.14);
  border-radius: 999px;
  background: rgba(255, 249, 242, 0.9);
  color: var(--text);
  cursor: pointer;
  font: inherit;
}

.cart-item-controls button {
  min-width: 34px;
  min-height: 34px;
  padding: 0 12px;
}

.cart-remove,
.link-button {
  color: var(--accent-dark) !important;
}

.cart-item-price {
  align-self: start;
  padding: 10px 12px;
  border-radius: 999px;
  background: rgba(163, 91, 62, 0.1);
  color: var(--accent-dark);
  font-size: 1.12rem;
  font-weight: 700;
  white-space: nowrap;
}

.cart-empty-state {
  display: grid;
  justify-items: start;
  gap: 18px;
  padding: 42px;
  border: 1px dashed rgba(124, 64, 41, 0.24);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.42);
}

.cart-empty-state p {
  color: var(--muted);
  font-size: 1.35rem;
}

.cart-summary {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid rgba(124, 64, 41, 0.12);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.52);
}

.sum-row,
.sum-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.sum-row {
  color: var(--muted);
  font-size: 1.08rem;
}

.sum-total {
  font-size: 1.32rem;
}

.sum-total strong {
  color: var(--accent-dark);
  font-size: 2rem;
}

.summary-note {
  margin-top: 2px;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.35;
}

.cart-trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0 18px;
}

.cart-trust-row span {
  display: inline-flex;
  padding: 8px 11px;
  border: 1px solid rgba(124, 64, 41, 0.12);
  border-radius: 999px;
  background: rgba(255, 249, 242, 0.72);
  color: var(--muted);
  font-size: 0.95rem;
}

.checkout-form,
.payment-block {
  display: grid;
  gap: 16px;
}

.form-group {
  display: grid;
  gap: 12px;
  padding: 18px;
  margin: 0;
  border: 1px solid rgba(124, 64, 41, 0.12);
  border-radius: 24px;
}

.form-group legend {
  padding: 0 8px;
  color: var(--accent-dark);
  font-size: 1.18rem;
  font-weight: 700;
}

.form-group label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 1rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  border: 1px solid rgba(124, 64, 41, 0.16);
  border-radius: 15px;
  background: rgba(255, 252, 248, 0.9);
  color: var(--text);
  font: inherit;
  font-size: 1.12rem;
  outline: none;
  padding: 12px 14px;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.form-group textarea {
  resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: rgba(163, 91, 62, 0.55);
  box-shadow: 0 0 0 4px rgba(163, 91, 62, 0.1);
}

.primary-button:disabled,
.link-button:disabled {
  cursor: not-allowed;
  opacity: 0.62;
  transform: none;
}

.payment-title {
  margin: 0;
  font-size: 1.7rem;
}

#payment-element {
  padding: 14px;
  border: 1px solid rgba(124, 64, 41, 0.12);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.66);
}

.link-button {
  justify-self: center;
  padding: 10px 15px;
  background: transparent;
}

.checkout-error {
  min-height: 1.3em;
  margin-top: 14px;
  color: #9b2f21;
  font-size: 1.05rem;
  line-height: 1.35;
}

.checkout-success {
  max-width: 720px;
  padding: 42px;
  margin: 0 auto;
  text-align: center;
}

.checkout-success h2 {
  margin: 0;
  font-size: clamp(2.5rem, 5vw, 4rem);
}

.checkout-success p {
  margin-top: 14px;
  color: var(--muted);
  font-size: 1.2rem;
  line-height: 1.45;
}

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

.admin-body {
  min-height: 100vh;
}

.admin-shell {
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
  padding: 36px 0 70px;
}

.admin-login-card,
.admin-panel,
.admin-header {
  border: 1px solid rgba(99, 72, 57, 0.13);
  border-radius: 34px;
  background:
    linear-gradient(180deg, rgba(255, 252, 248, 0.9), rgba(247, 237, 225, 0.9)),
    var(--surface-strong);
  box-shadow: var(--shadow);
}

.admin-login-card {
  width: min(520px, 100%);
  margin: 9vh auto 0;
  padding: 34px;
}

.admin-title {
  font-size: clamp(4rem, 9vw, 7rem);
}

.admin-muted {
  margin-top: 14px;
  color: var(--muted);
  font-size: 1.24rem;
  line-height: 1.42;
}

.admin-login-form,
.admin-product-form {
  display: grid;
  gap: 16px;
  margin-top: 24px;
}

.admin-login-form label,
.admin-product-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 1.02rem;
}

.admin-login-form input,
.admin-product-form input,
.admin-product-form textarea {
  width: 100%;
  border: 1px solid rgba(124, 64, 41, 0.16);
  border-radius: 15px;
  background: rgba(255, 252, 248, 0.92);
  color: var(--text);
  font: inherit;
  font-size: 1.12rem;
  outline: none;
  padding: 12px 14px;
}

.admin-login-form input:focus,
.admin-product-form input:focus,
.admin-product-form textarea:focus {
  border-color: rgba(163, 91, 62, 0.55);
  box-shadow: 0 0 0 4px rgba(163, 91, 62, 0.1);
}

.admin-product-form small {
  color: var(--muted);
  font-size: 0.92rem;
}

.admin-dashboard {
  display: grid;
  gap: 26px;
}

.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 26px 30px;
}

.admin-header-actions,
.admin-panel-head,
.admin-product-actions,
.admin-image-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.admin-grid {
  display: grid;
  grid-template-columns: minmax(360px, 0.9fr) minmax(0, 1.1fr);
  gap: 26px;
  align-items: start;
}

.admin-panel {
  padding: 26px;
}

.admin-panel-head {
  justify-content: space-between;
  margin-bottom: 20px;
}

.admin-panel-head h2 {
  margin-top: 6px;
  font-size: clamp(2rem, 3vw, 3rem);
  line-height: 1;
}

.admin-two-cols {
  display: grid;
  grid-template-columns: 1fr 0.8fr;
  gap: 14px;
}

.admin-check-row {
  display: flex !important;
  align-items: center;
  grid-template-columns: auto 1fr;
  gap: 10px !important;
}

.admin-check-row input {
  width: 18px;
  height: 18px;
}

.admin-upload-box {
  display: grid;
  gap: 10px;
  padding: 18px;
  border: 1px dashed rgba(124, 64, 41, 0.24);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.42);
}

.admin-upload-box p,
.admin-empty {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.35;
}

.admin-secondary-button,
.admin-danger-button,
.admin-image-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 9px 14px;
  border: 1px solid rgba(124, 64, 41, 0.16);
  border-radius: 999px;
  background: rgba(255, 249, 242, 0.86);
  color: var(--accent-dark);
  cursor: pointer;
  font: inherit;
  font-size: 1rem;
}

.admin-danger-button,
.admin-image-actions button:last-child {
  color: #9b2f21;
}

.admin-secondary-button:hover,
.admin-danger-button:hover,
.admin-image-actions button:hover {
  background: rgba(255, 255, 255, 0.95);
}

.admin-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  border-radius: 999px;
  background: rgba(163, 91, 62, 0.1);
  color: var(--accent-dark);
  font-weight: 700;
}

.admin-products,
.admin-images {
  display: grid;
  gap: 14px;
}

.admin-product-card,
.admin-image-card {
  display: grid;
  gap: 14px;
  border: 1px solid rgba(124, 64, 41, 0.11);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.5);
}

.admin-product-card {
  grid-template-columns: 110px minmax(0, 1fr);
  padding: 12px;
}

.admin-product-card.is-muted {
  opacity: 0.66;
}

.admin-product-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 110px;
  height: 110px;
  overflow: hidden;
  border-radius: 18px;
  background: #eadfce;
}

.admin-product-thumb img,
.admin-image-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.admin-product-copy {
  min-width: 0;
}

.admin-product-topline {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.admin-product-topline h3 {
  margin: 0;
  font-size: 1.45rem;
  line-height: 1.1;
}

.admin-product-topline span {
  color: var(--accent-dark);
  font-weight: 700;
  white-space: nowrap;
}

.admin-product-copy p,
.admin-product-copy small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
}

.admin-product-actions {
  margin-top: 12px;
}

.admin-image-card {
  grid-template-columns: 76px minmax(0, 1fr);
  align-items: center;
  padding: 10px;
}

.admin-image-card img {
  width: 76px;
  height: 76px;
  border-radius: 16px;
}

.admin-image-card strong,
.admin-image-card small {
  display: block;
}

.admin-image-card small {
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-image-actions {
  grid-column: 1 / -1;
}

.admin-error,
.admin-success {
  min-height: 1.25em;
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.35;
}

.admin-error {
  color: #9b2f21;
}

.admin-success {
  color: #427039;
}

.footer {
  display: grid;
  gap: 24px;
  padding: 42px 28px 56px;
  margin-bottom: 30px;
  background: linear-gradient(180deg, rgba(255, 251, 247, 0.8), rgba(241, 228, 212, 0.92));
  border: 1px solid rgba(90, 58, 42, 0.1);
  border-radius: 34px;
  box-shadow: var(--shadow);
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.footer-grid a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 18px;
  font-size: 1.08rem;
  border-radius: 999px;
  background: rgba(255, 249, 243, 0.9);
  border: 1px solid rgba(124, 64, 41, 0.12);
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(26px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes reveal {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes cart-pop {
  0% {
    transform: scale(1);
  }
  45% {
    transform: scale(1.22);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes cart-float-pop {
  0% {
    transform: translateY(0) scale(1);
  }
  45% {
    transform: translateY(-6px) scale(1.015);
  }
  100% {
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 980px) {
  .about-section,
  .catalog-grid {
    grid-template-columns: 1fr;
  }

  .cart-page-grid {
    grid-template-columns: 1fr;
  }

  .admin-grid {
    grid-template-columns: 1fr;
  }

  .checkout-column {
    position: static;
  }

  .portrait-frame {
    display: block;
    width: 100%;
    max-width: 340px;
    margin: 0 auto;
    aspect-ratio: 4 / 5;
    min-height: 380px;
  }

  .hero-content {
    padding-top: 70px;
  }

  .card-image {
    aspect-ratio: 5 / 4;
  }
}

@media (max-width: 720px) {
  .hero,
  .about-section,
  .catalog-section,
  .footer {
    width: min(100% - 24px, 1160px);
  }

  .topbar {
    flex-direction: column;
    border-radius: 28px;
  }

  .topbar-links {
    flex-wrap: wrap;
    justify-content: center;
  }

  .hero-content {
    padding-top: 56px;
  }

  h1 {
    font-size: clamp(4.1rem, 24vw, 6.5rem);
  }

  .about-copy,
  .footer {
    padding-left: 22px;
    padding-right: 22px;
  }

  .portrait-frame {
    display: block;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
    min-height: 340px;
  }

  .card-title-row,
  .card-actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .buy-button {
    width: 100%;
  }

  .cart-page {
    width: min(100% - 24px, 1160px);
    margin-bottom: 42px;
  }

  .cart-column,
  .checkout-column,
  .checkout-success {
    border-radius: 26px;
    padding: 20px;
  }

  .cart-item {
    grid-template-columns: 86px minmax(0, 1fr);
  }

  .cart-item-thumb {
    width: 86px;
    height: 86px;
  }

  .cart-item-price {
    grid-column: 2;
    justify-self: start;
  }

  .floating-cart {
    right: 12px;
    bottom: 12px;
    width: min(360px, calc(100vw - 24px));
  }

  .floating-cart-item {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .floating-cart-thumb {
    width: 54px;
    height: 54px;
  }

  .floating-cart-price {
    grid-column: 2;
    justify-self: start;
  }

  .admin-shell {
    width: min(100% - 24px, 1240px);
    padding-top: 18px;
  }

  .admin-header,
  .admin-login-card,
  .admin-panel {
    border-radius: 26px;
    padding: 20px;
  }

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

  .admin-two-cols,
  .admin-product-card {
    grid-template-columns: 1fr;
  }

  .admin-product-thumb {
    width: 100%;
    height: 190px;
  }
}