:root {
  --bg: #f6f8fc;
  --text: #132238;
  --muted: #5d6b80;
  --primary: #e63946;
  --primary-dark: #bf1f2b;
  --white: #ffffff;
  --border: #dbe2ee;
  --shadow: 0 12px 30px rgba(19, 34, 56, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: "Inter", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
}

.container {
  width: min(1120px, calc(100vw - 2 * clamp(0.75rem, 4vw, 1.25rem)));
  margin-inline: auto;
}

.topbar {
  background: #0f1a2a;
  color: #d9e1ef;
  font-size: 0.9rem;
}

.topbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: calc(0.6rem + env(safe-area-inset-top, 0px)) 0 0.6rem;
}

.topbar a {
  color: #d9e1ef;
  text-decoration: none;
}

.navbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-start;
  gap: 0.75rem 1rem;
  padding: 0.75rem 0;
  min-height: 3.75rem;
  position: relative;
}

.logo {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  min-width: 0;
  text-decoration: none;
  color: var(--text);
  line-height: 0;
}

.logo:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: 4px;
}

.logo:hover .logo-img {
  opacity: 0.92;
}

.logo-img {
  display: block;
  width: auto;
  max-width: min(100%, 24rem);
  height: clamp(2.05rem, 3.9vw, 2.75rem);
  object-fit: contain;
  object-position: left center;
}

.menu {
  display: flex;
  flex: 1;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  list-style: none;
  gap: clamp(0.6rem, 1.4vw, 1.4rem);
  margin: 0;
  padding: 0 0.5rem;
  min-width: 0;
}

.menu li {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.menu a {
  display: inline-flex;
  align-items: center;
  min-height: 2.4rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
  font-size: clamp(0.86rem, 1.1vw, 0.95rem);
  line-height: 1.2;
}

.menu-toggle {
  display: none;
  border: none;
  background: transparent;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.nav-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.35rem;
  flex-shrink: 0;
}

.user-menu-wrap,
.user-nav-cluster {
  position: relative;
}

.nav-user-cluster {
  display: flex;
  align-items: center;
  gap: 0.2rem;
}

.nav-notif-wrap {
  position: relative;
}

.nav-notif-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--white);
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.nav-notif-btn:hover {
  background: #f6f8fc;
  border-color: #cfd8e8;
}

.nav-notif-btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.nav-notif-icon {
  display: block;
}

.nav-notif-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 1.1rem;
  height: 1.1rem;
  padding: 0 0.28rem;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1.1rem;
  text-align: center;
  pointer-events: none;
}

.nav-notif-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 50;
  width: min(22rem, calc(100vw - 2rem));
  max-height: min(70vh, 24rem);
  overflow: auto;
  padding: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 14px 40px rgba(15, 23, 42, 0.12);
}

.nav-notif-dropdown[hidden] {
  display: none !important;
}

.nav-notif-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.88rem;
}

.nav-notif-link {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
  white-space: nowrap;
}

.nav-notif-link:hover {
  text-decoration: underline;
}

.nav-notif-list {
  list-style: none;
  margin: 0;
  padding: 0.35rem 0;
}

.nav-notif-item {
  padding: 0.55rem 0.85rem;
  border-bottom: 1px solid #f0f3f9;
  font-size: 0.86rem;
  line-height: 1.45;
}

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

.nav-notif-item--unread {
  background: #f8fbff;
}

.nav-notif-item-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.65rem;
}

.nav-notif-item strong {
  font-size: 0.88rem;
  color: var(--text);
  font-weight: 700;
  flex: 1;
  min-width: 0;
}

.nav-notif-item time {
  flex-shrink: 0;
  font-size: 0.72rem;
  color: #8a96a8;
  white-space: nowrap;
}

.nav-notif-empty {
  margin: 0;
  padding: 1rem 0.85rem;
  font-size: 0.86rem;
  color: var(--muted);
  text-align: center;
}

.user-menu {
  position: relative;
}

.user-menu-icon {
  display: none;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

.user-menu-icon svg {
  display: block;
}

.user-menu-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.55rem 0.35rem 0.45rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--white);
  color: var(--text);
  font: inherit;
  font-weight: 600;
  font-size: clamp(0.86rem, 1.1vw, 0.95rem);
  cursor: pointer;
  max-width: min(100%, 14rem);
}

.user-menu-trigger:hover {
  background: #f6f8fc;
  border-color: #cfd8e8;
}

.user-menu-trigger:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.user-menu-trigger .user-greeting {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-menu-chevron {
  flex-shrink: 0;
  font-size: 0.65rem;
  color: var(--muted);
  line-height: 1;
}

.user-menu-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 45;
  min-width: 200px;
  padding: 0.35rem 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 10px 32px rgba(15, 23, 42, 0.1);
}

.user-menu-dropdown[hidden] {
  display: none !important;
}

.user-menu-item {
  display: block;
  width: 100%;
  padding: 0.55rem 1rem;
  border: none;
  background: transparent;
  text-align: left;
  font: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
  cursor: pointer;
}

.user-menu-item:hover {
  background: #f0f4fc;
}

.user-menu-item--logout {
  color: var(--muted);
  border-top: 1px solid var(--border);
  margin-top: 0.25rem;
  padding-top: 0.65rem;
}

a.user-menu-item {
  text-decoration: none;
  box-sizing: border-box;
}

/* Stranica Moj profil — korisničke informacije */
.account-page-body {
  min-height: 100vh;
}

.account-page-main {
  padding: 2rem 0 3rem;
}

.profile-container {
  max-width: 960px;
}

.profile-shell {
  display: grid;
  grid-template-columns: minmax(12.5rem, 15.5rem) minmax(0, 1fr);
  gap: 1.75rem 2rem;
  align-items: start;
}

.profile-side {
  position: sticky;
  top: 5.25rem;
  align-self: start;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.1rem 0.75rem 1.15rem;
  box-shadow: var(--shadow);
}

.profile-side__title {
  margin: 0 0 0.85rem;
  padding: 0 0.5rem;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--primary);
}

.profile-side__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.profile-side__btn {
  width: 100%;
  text-align: left;
  padding: 0.68rem 0.8rem;
  border: none;
  border-radius: 10px;
  background: transparent;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
  line-height: 1.3;
}

.profile-side__btn:hover {
  background: #f0f4fa;
}

.profile-side__btn.is-active {
  background: linear-gradient(170deg, #0f1a2a, #1d3657);
  color: #f3f7ff;
}

.profile-side__btn.is-active:hover {
  color: #f3f7ff;
}

.profile-side__btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.profile-content {
  min-width: 0;
}

.profile-panel {
  display: none;
}

.profile-panel.is-active {
  display: block;
}

.profile-content .ki-card--profile-block {
  max-width: none;
  margin-inline: 0;
  margin-top: 0;
}

.account-back-link {
  flex-shrink: 0;
  font-weight: 600;
  font-size: 0.9rem;
}

.ki-card {
  max-width: 32rem;
  margin-inline: auto;
  padding: 2rem 2.25rem 2.5rem;
  background: var(--white);
  border-radius: 16px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.ki-title {
  margin: 0 0 0.35rem;
  font-size: 1.35rem;
  font-weight: 700;
  color: #0c4a5e;
  letter-spacing: -0.02em;
}

.ki-lead {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.45;
}

.ki-hint {
  margin: 0.35rem 0 0;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.4;
}

.profile-review-gate {
  color: var(--muted);
}

.ki-rule {
  margin: 0 0 1.5rem;
  border: none;
  border-bottom: 1px solid #e2e8f0;
}

.ki-form {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.ki-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.ki-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #0c4a5e;
}

.ki-label-sub {
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
  color: var(--muted);
  margin-top: -0.1rem;
}

.ki-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 10px;
  background: #f0f2f5;
  font: inherit;
  font-size: 0.95rem;
  color: var(--text);
  transition: box-shadow 0.15s ease;
}

.ki-input:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(12, 74, 94, 0.25);
}

.ki-input::placeholder {
  color: #8a96a8;
}

.ki-input-readonly {
  background: #e8ecf1;
  color: var(--muted);
  cursor: default;
}

.ki-textarea {
  width: 100%;
  min-height: 140px;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 10px;
  background: #f0f2f5;
  font: inherit;
  font-size: 0.95rem;
  color: var(--text);
  resize: vertical;
}

.ki-textarea:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(12, 74, 94, 0.25);
}

.ki-submit {
  margin-top: 0.5rem;
  align-self: flex-start;
}

.ki-message {
  margin: 0;
  min-height: 1.25em;
}

.ki-card--notif {
  margin-top: 1.5rem;
}

.ki-card--review {
  margin-top: 1.5rem;
}

.settings-block-spaced {
  margin-top: 1.5rem;
}

.settings-forgot {
  margin-top: 1.25rem;
}

.settings-forgot a {
  color: #0c4a5e;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.settings-forgot a:hover {
  color: #063446;
}

.utisak-lead-bullets {
  margin-top: 0.65rem;
}

.settings-list {
  margin: 0.35rem 0 0;
  padding-left: 1.25rem;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--muted);
}

.settings-list li {
  margin: 0.4rem 0;
}

.settings-lead-tight {
  font-size: 0.88rem;
  line-height: 1.45;
  margin: 0.5rem 0 0;
}

.settings-logout-card .btn {
  margin-top: 0.5rem;
}

@media (max-width: 760px) {
  .profile-shell {
    grid-template-columns: 1fr;
  }

  .profile-side {
    position: static;
    padding: 0.85rem 0.65rem;
  }

  .profile-side__list {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.4rem;
  }

  .profile-side__btn {
    flex: 1 1 auto;
    min-width: min(100%, 9.5rem);
    text-align: center;
    font-size: 0.8rem;
    padding: 0.55rem 0.5rem;
  }
}

.review-star-bar {
  display: flex;
  gap: 0.15rem;
  margin-top: 0.35rem;
}

.review-star-bar button {
  padding: 0.15rem 0.2rem;
  border: none;
  background: none;
  cursor: pointer;
  font-size: 1.65rem;
  line-height: 1;
  color: #dbe2ee;
  transition: color 0.15s ease, transform 0.15s ease;
}

.review-star-bar button.is-on {
  color: #c9a227;
}

.review-star-bar button:hover,
.review-star-bar button:focus-visible {
  color: #d4a017;
  transform: scale(1.08);
  outline: none;
}

.review-star-bar button:focus-visible {
  box-shadow: 0 0 0 2px rgba(201, 162, 39, 0.45);
  border-radius: 4px;
}

.legal-page-main {
  padding: 2rem 0 2.5rem;
  flex: 1;
}

.legal-page.ki-card {
  max-width: 44rem;
}

.legal-page h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.35rem, 2.5vw, 1.65rem);
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}

.legal-lead {
  margin: 0 0 1.75rem;
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.55;
}

.legal-lead a {
  font-weight: 600;
}

.legal-section h2 {
  margin: 0 0 0.45rem;
  font-size: 1.02rem;
  font-weight: 700;
  color: #0c4a5e;
}

.legal-section p {
  margin: 0 0 0.65rem;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text);
}

.legal-section p:last-child {
  margin-bottom: 0;
}

.legal-section ul {
  margin: 0.25rem 0 0;
  padding-left: 1.2rem;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text);
}

.legal-section li {
  margin-bottom: 0.35rem;
}

.ki-title--sub {
  font-size: 1.15rem;
}

#obavjesti {
  scroll-margin-top: 5.5rem;
}

.profile-notif-toolbar {
  margin-bottom: 0.75rem;
}

.profile-notif-mark {
  font-size: 0.88rem;
  padding: 0.45rem 0.85rem;
}

.profile-notif-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.profile-notif-item {
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
  line-height: 1.45;
}

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

.profile-notif-item--unread {
  background: linear-gradient(90deg, rgba(230, 57, 70, 0.06), transparent);
  margin: 0 -0.5rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
  border-radius: 8px;
}

.profile-notif-item-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
}

.profile-notif-item strong {
  color: var(--text);
  font-size: 0.92rem;
  flex: 1;
  min-width: 0;
}

.profile-notif-item time {
  flex-shrink: 0;
  font-size: 0.78rem;
  color: #8a96a8;
  white-space: nowrap;
}

.profile-notif-empty {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  text-align: center;
  padding: 1rem 0;
}

.nav-cart-wrap {
  position: relative;
}

.nav-cart {
  position: relative;
}

.nav-cart-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--white);
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.nav-cart-btn:hover {
  background: #f6f8fc;
  border-color: #cfd8e8;
}

.nav-cart-btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.nav-cart-icon {
  display: block;
}

.cart-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  line-height: 1.15rem;
  text-align: center;
}

.cart-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 40;
  width: min(100vw - 1.5rem, 340px);
  max-height: min(70vh, 420px);
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(15, 23, 42, 0.12);
  overflow: hidden;
}

/* display:flex iznad poništava [hidden] bez ovoga — panel mora biti sakriven dok nije klik na korpu */
.cart-dropdown[hidden] {
  display: none !important;
}

.cart-dropdown-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}

.cart-dropdown-close {
  border: none;
  background: transparent;
  font-size: 1.35rem;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
  padding: 0.2rem;
  border-radius: 6px;
}

.cart-dropdown-close:hover {
  color: var(--text);
  background: #f0f4fc;
}

.cart-list {
  list-style: none;
  margin: 0;
  padding: 0.35rem 0;
  overflow-y: auto;
  flex: 1;
  min-height: 0;
}

.cart-list__item {
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
  padding: 0.55rem 0.85rem;
  border-bottom: 1px solid #eef2f8;
}

.cart-list__item:last-child {
  border-bottom: none;
}

.cart-list__body {
  flex: 1;
  min-width: 0;
}

.cart-list__label {
  margin: 0;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.35;
}

.cart-list__meta {
  margin: 0.2rem 0 0;
  font-size: 0.75rem;
  color: var(--muted);
}

.cart-list__price {
  margin: 0.35rem 0 0;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text);
}

.cart-list__remove {
  flex-shrink: 0;
  width: 1.75rem;
  height: 1.75rem;
  border: none;
  border-radius: 8px;
  background: #f0f4fc;
  color: var(--muted);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}

.cart-list__remove:hover {
  background: #ffe6e8;
  color: var(--primary);
}

.cart-empty {
  margin: 0;
  padding: 1rem 0.85rem 1.25rem;
  font-size: 0.88rem;
  color: var(--muted);
  text-align: center;
}

.cart-dropdown-foot {
  padding: 0.5rem 0.85rem 0.75rem;
  border-top: 1px solid var(--border);
}

.cart-clear-btn {
  font-size: 0.85rem;
  padding: 0;
}

.cart-toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  z-index: 120;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.75rem 1.1rem;
  max-width: min(92vw, 380px);
  translate: -50% 120%;
  opacity: 0;
  background: var(--text);
  color: #fff;
  border-radius: 14px;
  font-size: 0.92rem;
  font-weight: 600;
  box-shadow: 0 10px 36px rgba(15, 23, 42, 0.22);
  pointer-events: none;
  transition: translate 0.35s ease, opacity 0.35s ease;
}

.cart-toast.cart-toast--show {
  translate: -50% 0;
  opacity: 1;
}

.cart-toast__icon {
  display: inline-flex;
  width: 1.35rem;
  height: 1.35rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #0f8a4b;
  color: #fff;
  font-size: 0.75rem;
}

.cart-toast__text {
  line-height: 1.35;
}

.hero {
  padding: 3.25rem 0 3.5rem;
}

.hero--split {
  background: var(--white);
}

.hero-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.22fr);
  gap: clamp(1.75rem, 4vw, 3.25rem);
  align-items: center;
}

.hero-split__content {
  padding: 0.25rem 0;
  max-width: 36rem;
}

.hero--split h1 {
  font-weight: 800;
  letter-spacing: -0.03em;
}

.hero--split h1 .hero-title-emphasis {
  color: var(--primary);
}

.hero-divider {
  width: 100%;
  max-width: 6.5rem;
  height: 1px;
  margin: 1.35rem 0 0.25rem;
  background: var(--border);
  border: none;
}

.btn-hero-outline {
  background: var(--white);
  color: var(--text);
  border: 2px solid var(--text);
  border-radius: 999px;
  padding: 0.72rem 1.35rem;
}

.btn-hero-outline:hover {
  background: var(--text);
  color: var(--white);
}

.hero-highlights-row {
  list-style: none;
  margin: 1.85rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 0.65rem;
  align-items: stretch;
}

.hero-highlight-box {
  flex: 1 1 0;
  min-width: 0;
  margin: 0;
  background: linear-gradient(170deg, #0f1a2a, #1d3657);
  color: #f3f7ff;
  border-radius: 12px;
  padding: 0.95rem 0.65rem;
  box-shadow: var(--shadow);
  font-size: clamp(0.78rem, 1.65vw, 0.92rem);
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-split__visual {
  min-width: 0;
}

.hero-visual {
  position: relative;
  border-radius: clamp(18px, 2.5vw, 28px);
  overflow: hidden;
  background: #0f1a2a;
  box-shadow: 0 24px 60px rgba(15, 26, 42, 0.18), 0 4px 16px rgba(19, 34, 56, 0.08);
  min-height: clamp(20rem, 52vh, 36rem);
  display: flex;
  flex-direction: column;
}

.hero-visual__tag {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 3;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
  box-shadow: 0 8px 28px rgba(15, 26, 42, 0.12);
  pointer-events: none;
}

.hero-visual__inner {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.hero-visual__loading,
.hero-visual__fallback {
  flex: 1;
  min-height: clamp(18rem, 48vh, 32rem);
  display: grid;
  place-items: center;
  text-align: center;
  padding: 2rem 1.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  background: linear-gradient(160deg, #1a2740, #0f1a2a);
}

.hero-visual__fallback {
  border: 1px dashed rgba(255, 255, 255, 0.2);
  margin: 1rem;
  border-radius: 16px;
  min-height: auto;
}

.hero-visual__fallback a {
  color: #ffb4bc;
  font-weight: 700;
}

.hero-visual__media {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  text-decoration: none;
  color: inherit;
}

.hero-visual__stage {
  flex: 1;
  position: relative;
  min-height: clamp(16rem, 42vh, 28rem);
}

.hero-visual__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.45s ease;
}

.hero-visual__media:hover .hero-visual__img {
  transform: scale(1.04);
}

.hero-visual__media:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: -2px;
}

.hero-visual__caption-wrap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  padding: 1.25rem 1.25rem 1.1rem;
  background: linear-gradient(180deg, transparent 0%, rgba(15, 26, 42, 0.55) 38%, rgba(15, 26, 42, 0.88) 100%);
}

.hero-visual__caption {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.95);
  padding-left: 0.75rem;
  border-left: 2px solid rgba(255, 255, 255, 0.65);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-visual__actions {
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding: 0.9rem 1.15rem;
  background: var(--white);
  border-top: 1px solid var(--border);
}

.hero-visual__profile {
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--text);
  text-decoration: none;
}

.hero-visual__profile:hover {
  color: var(--primary);
}

.hero-visual__cta {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
}

.hero-visual__cta:hover {
  text-decoration: underline;
}

.eyebrow {
  color: var(--primary);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  margin: 0;
}

h1,
h2,
h3 {
  line-height: 1.2;
  margin: 0.4rem 0 0.8rem;
}

h1 {
  font-size: clamp(2rem, 3.8vw, 3.2rem);
}

h2 {
  font-size: clamp(1.6rem, 2.8vw, 2.4rem);
}

.lead {
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 62ch;
}

.cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin: 1.3rem 0;
}

.btn {
  display: inline-block;
  border-radius: 12px;
  padding: 0.78rem 1.15rem;
  text-decoration: none;
  font-weight: 700;
  border: none;
  cursor: pointer;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-dark);
}

.btn-secondary {
  background: #e9eef8;
  color: var(--text);
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.badges span {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.28rem 0.7rem;
  font-size: 0.86rem;
}

.about-card {
  background: linear-gradient(170deg, #0f1a2a, #1d3657);
  color: #f3f7ff;
  border-radius: 20px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
}

.section {
  padding: 4rem 0;
}

.section.alt {
  background: #eef3fb;
}

.section-head {
  max-width: 700px;
  margin-bottom: 1.4rem;
}

.order-section-note {
  margin: 0.6rem 0 0;
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.5;
  max-width: 640px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.1rem;
  box-shadow: var(--shadow);
}

.card p {
  color: var(--muted);
}

.card-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem 0.75rem;
  margin-top: 0.6rem;
}

.card-bottom .btn {
  flex-shrink: 0;
}

.card--poster-okvir .card-slider,
.card--poster-canvas .card-slider {
  position: relative;
  margin: 0 0 0.85rem;
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: #e8edf5;
}

.card--3d-letters .card-photo {
  margin: 0 0 0.85rem;
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: #e8edf5;
}

.card--3d-letters .card-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-slider__viewport {
  position: relative;
  width: 100%;
  height: 100%;
}

.card-slider__slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.55s ease;
}

.card-slider__slide.is-active {
  opacity: 1;
}

/* Samo Auto poster (canvas): zum na središte slike (crop rubova u okviru slajdera) */
.card--poster-canvas .card-slider__slide {
  object-position: center center;
  transform: scale(1.5);
  transform-origin: center center;
}

@media (prefers-reduced-motion: reduce) {
  .card-slider__slide {
    transition: none;
  }
}

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.steps article {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1rem;
}

.steps span {
  display: inline-flex;
  width: 32px;
  height: 32px;
  justify-content: center;
  align-items: center;
  border-radius: 999px;
  background: #ffe6e8;
  color: var(--primary);
  font-weight: 700;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.reviews-lead {
  margin: 0 0 1.35rem;
  max-width: 46rem;
  font-size: 0.98rem;
  color: var(--muted);
  line-height: 1.55;
}

.reviews-lead strong {
  color: var(--text);
}

.reviews-lead a {
  color: var(--primary);
  font-weight: 700;
}

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 17.5rem), 1fr));
  gap: 1.15rem;
}

.reviews-state,
.reviews-empty {
  margin: 0;
  grid-column: 1 / -1;
  padding: 2rem 1.25rem;
  text-align: center;
  color: var(--muted);
  font-weight: 600;
  background: var(--white);
  border: 1px dashed var(--border);
  border-radius: 16px;
}

.reviews-empty a {
  color: var(--primary);
  font-weight: 700;
}

.review-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 1.2rem 1.25rem 1.15rem;
  box-shadow: 0 8px 26px rgba(19, 34, 56, 0.06);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.review-card__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 0.75rem;
}

.review-card__author {
  margin: 0;
  font-weight: 800;
  font-size: 1rem;
  color: var(--text);
  letter-spacing: -0.02em;
}

.review-stars {
  display: inline-flex;
  gap: 0.08rem;
  font-size: 1rem;
  line-height: 1;
  letter-spacing: 0.02em;
}

.review-star {
  color: #dbe2ee;
}

.review-star--on {
  color: #d4a017;
}

.review-card__text {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--muted);
  white-space: pre-line;
}

.review-card__date {
  font-size: 0.78rem;
  font-weight: 600;
  color: #8a96a8;
  margin-top: auto;
  padding-top: 0.15rem;
}

.gallery-note {
  margin: 0 0 1rem;
  color: var(--muted);
}

.gallery-note a {
  color: var(--primary);
  font-weight: 700;
}

#galerija .gallery-note {
  margin: 0 0 0.5rem;
  line-height: 1.6;
  max-width: 42rem;
}

.gallery-note--fallback {
  font-size: 0.92rem;
  color: #5d6b80;
}

.gallery-note--fallback::after {
  content: " Prikaz primjera radova; užive objave s @posterart.ba nakon povezivanja Instagram tokena u postavkama hostinga (Vercel env).";
  font-weight: 500;
  display: block;
  margin-top: 0.35rem;
  font-size: 0.88rem;
}

.gallery-item {
  min-height: 160px;
  border-radius: 16px;
  background: linear-gradient(135deg, #d7deeb, #f6f8fc);
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  font-weight: 700;
  color: #344967;
}

.gallery-item.loading,
.gallery-item.error {
  grid-column: 1 / -1;
}

/* Instagram: puna slika (bez crop), zaobljeni blokovi, bez border stroke-a */
#galerija #instagramGallery.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: start;
  gap: 1rem;
  margin-top: 0.65rem;
  padding: clamp(1rem, 2.5vw, 1.35rem);
  background: #f0f3f9;
  border: none;
  border-radius: 20px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.insta-card {
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: 2px;
  border: 1px solid rgba(15, 26, 42, 0.08);
  background: #0f0f0f;
  min-height: 0;
  aspect-ratio: 1 / 1;
}

#galerija .insta-card {
  border: none;
  outline: none;
  box-shadow: 0 8px 28px rgba(19, 34, 56, 0.1);
  border-radius: 16px;
  background: #12151c;
  aspect-ratio: unset;
  min-height: 0;
  overflow: hidden;
  transition: box-shadow 0.22s ease, transform 0.22s ease;
}

#galerija .insta-card::after {
  display: none;
  content: none;
}

@media (hover: hover) and (pointer: fine) {
  #galerija .insta-card:hover {
    box-shadow: 0 14px 40px rgba(19, 34, 56, 0.16);
    transform: translateY(-3px);
  }
}

.insta-card::after {
  content: "";
  position: absolute;
  inset: 0;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  pointer-events: none;
  border-radius: 2px;
}

.insta-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  transition: transform 0.25s ease;
}

#galerija .insta-card img {
  position: static;
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: center;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.insta-card:hover img {
  transform: scale(1.04);
}

@media (hover: hover) and (pointer: fine) {
  #galerija .insta-card:hover img {
    transform: scale(1.02);
  }
}

.about {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 1.5rem;
  align-items: start;
}

.order-form {
  display: grid;
  gap: 0.9rem;
  max-width: 720px;
}

.order-form label {
  display: grid;
  gap: 0.35rem;
  font-weight: 600;
}

.order-poster-size {
  display: block;
  margin: -0.15rem 0 0.15rem;
}

.order-poster-size[hidden] {
  display: none !important;
}

.order-3dletters-note {
  margin: -0.2rem 0 0;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
  line-height: 1.5;
  max-width: 640px;
}

.order-3dletters-note[hidden] {
  display: none !important;
}

.order-poster-size label {
  display: grid;
  gap: 0.35rem;
  font-weight: 600;
}

.order-form input,
.order-form select,
.order-form textarea {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.72rem 0.8rem;
  font-size: 1rem;
}

.order-form textarea {
  font-family: inherit;
  resize: vertical;
  min-height: 4.5rem;
}

.order-form input[type="file"] {
  padding: 0.5rem 0.6rem;
  font-size: 0.95rem;
  background: #fafbfe;
  cursor: pointer;
}

.order-images-count {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
}

.summary {
  background: #f0f4fc;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0.8rem 1rem;
}

.order-section-title {
  margin: 0 0 0.65rem;
  font-size: clamp(1.2rem, 2.4vw, 1.45rem);
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.order-cta-card.summary p {
  margin: 0 0 0.65rem;
}

.order-cta-card.summary p:last-child {
  margin-bottom: 0;
}

.faq-lead {
  max-width: 700px;
  margin: 0 0 1.5rem;
  color: var(--muted);
  line-height: 1.6;
  font-size: 1.02rem;
}

.faq-list {
  max-width: 720px;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.faq-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 1px 0 rgba(15, 26, 42, 0.04);
  overflow: hidden;
}

.faq-q {
  display: block;
  padding: 1rem 2.4rem 1rem 1rem;
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--text);
  cursor: pointer;
  list-style: none;
  position: relative;
  line-height: 1.4;
  transition: background 0.15s ease;
}

.faq-q::-webkit-details-marker {
  display: none;
}

.faq-q::after {
  content: "";
  position: absolute;
  right: 1rem;
  top: 50%;
  width: 0.5rem;
  height: 0.5rem;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: translateY(-60%) rotate(45deg);
  transition: transform 0.2s ease;
}

.faq-item[open] .faq-q::after {
  transform: translateY(-20%) rotate(-135deg);
}

.faq-q:hover,
.faq-item[open] .faq-q {
  background: #f6f8fd;
}

.faq-a {
  padding: 0 1rem 1rem 1rem;
  border-top: 1px solid #e6ecf5;
}

.faq-a p {
  margin: 0.75rem 0 0;
  color: var(--muted);
  line-height: 1.65;
  font-size: 0.98rem;
}

.faq-a p:first-child {
  margin-top: 0.85rem;
}

.form-message {
  margin: 0;
  font-weight: 600;
}

.footer {
  background: #0f1a2a;
  color: #c9d5ea;
  padding: 2.5rem 0 1rem;
  margin-top: 2rem;
}

.footer a {
  color: #e0ebff;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1.5rem 2rem;
}

.footer-brand-link {
  display: inline-block;
  text-decoration: none;
  line-height: 0;
}

.footer-brand-link:focus-visible {
  outline: 2px solid #e0ebff;
  outline-offset: 4px;
  border-radius: 8px;
}

.footer-brand-logo {
  display: block;
  max-width: min(280px, 100%);
  width: auto;
  height: auto;
  max-height: 56px;
  object-fit: contain;
}

.footer-brand-tagline {
  margin: 0.65rem 0 0;
  font-size: 0.92rem;
  color: #95a7c2;
  line-height: 1.45;
  max-width: 22rem;
}

.footer-contact {
  text-align: right;
}

.footer-email {
  margin: 0 0 0.35rem;
}

.footer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: flex-end;
  margin-top: 0.45rem;
}

.footer-social__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.55rem;
  height: 2.55rem;
  border: 1px solid rgba(224, 235, 255, 0.28);
  border-radius: 12px;
  color: #e0ebff;
  background: rgba(255, 255, 255, 0.06);
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.footer-social__btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(224, 235, 255, 0.45);
  transform: translateY(-1px);
}

.copyright {
  text-align: center;
  margin-top: 1rem;
  color: #95a7c2;
}

.copyright .footer-legal {
  color: #c9d5ea;
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.copyright .footer-legal:hover {
  color: #e0ebff;
}

.hidden {
  display: none !important;
}

.auth-nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.4rem 0.5rem;
  margin-left: 0.1rem;
}

.auth-nav-icon {
  display: none;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

.auth-nav-icon svg {
  display: block;
}

.auth-nav-btn {
  gap: 0.35rem;
}

.btn-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.4rem;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.35rem 0.8rem;
  font: inherit;
  font-size: clamp(0.86rem, 1.05vw, 0.92rem);
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  line-height: 1.2;
}

.btn-link:hover {
  background: #f0f4fc;
}

.btn-link-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

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

.user-greeting {
  font-size: 0.92rem;
  color: var(--muted);
}

.user-greeting strong {
  color: var(--text);
}

.order-modal {
  z-index: 60;
}

.order-modal-card {
  width: min(520px, 100%);
  max-width: 100%;
  max-height: min(92vh, 880px);
  overflow-x: hidden;
  overflow-y: auto;
  padding: 1.5rem 1.5rem 1.25rem;
  border: 1px solid var(--border);
  box-sizing: border-box;
}

.order-modal__title {
  margin: 0 0 0.35rem;
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text);
}

.order-modal__hint {
  margin: 0 0 1rem;
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.45;
}

.order-vehicle-specs {
  margin: 0 0 1rem;
  padding: 0.85rem 1rem 1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #f7f9fc;
}

.order-vehicle-specs__legend {
  padding: 0 0.35rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
}

.order-vehicle-specs label {
  display: block;
  margin-top: 0.65rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}

.order-vehicle-specs label:first-of-type {
  margin-top: 0.35rem;
}

.order-vehicle-specs input {
  margin-top: 0.25rem;
  width: 100%;
  box-sizing: border-box;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  box-sizing: border-box;
  overflow-x: hidden;
  overflow-y: auto;
}

.modal.open {
  display: flex;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 26, 42, 0.55);
  backdrop-filter: blur(2px);
}

.modal-card {
  position: relative;
  background: var(--white);
  border-radius: 18px;
  box-shadow: var(--shadow);
  width: min(420px, 100%);
  padding: 1.8rem 1.6rem 1.4rem;
  z-index: 1;
}

.modal-card.auth-card {
  width: min(440px, 100%);
  max-width: 100%;
  max-height: min(90vh, 900px);
  overflow-x: hidden;
  overflow-y: auto;
  padding: 2rem 1.75rem 1.5rem;
  border: 1px solid var(--border);
  box-sizing: border-box;
}

.modal-close {
  position: absolute;
  top: 0.6rem;
  right: 0.8rem;
  background: transparent;
  border: none;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  color: var(--muted);
}

.modal-close:hover {
  color: var(--text);
}

.auth-panel {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  min-width: 0;
  max-width: 100%;
}

.auth-heading {
  margin: 0 0 0.25rem;
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
  text-align: left;
}

.auth-field {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  min-height: 3rem;
  padding: 0 0.85rem 0 0.75rem;
  border: 1px solid var(--primary);
  border-radius: 999px;
  background: var(--white);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.auth-field:focus-within {
  border-color: var(--primary-dark);
  box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.18);
}

.auth-field__icon {
  display: flex;
  flex-shrink: 0;
  color: var(--muted);
}

.auth-input {
  flex: 1 1 auto;
  min-width: 0;
  border: none;
  background: transparent;
  padding: 0.7rem 0.15rem;
  font: inherit;
  font-size: 0.98rem;
  color: var(--text);
}

.auth-input::placeholder {
  color: #8b97a8;
}

.auth-input:focus {
  outline: none;
}

.auth-toggle-password {
  flex-shrink: 0;
  border: none;
  background: transparent;
  color: var(--primary);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0.4rem 0.2rem;
  text-transform: none;
  letter-spacing: 0.01em;
}

.auth-toggle-password:hover {
  color: var(--primary-dark);
}

.auth-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 0.1rem;
}

.auth-remember {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  user-select: none;
}

.auth-remember input {
  width: 1.05rem;
  height: 1.05rem;
  accent-color: var(--primary);
  cursor: pointer;
}

button.auth-link {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  cursor: pointer;
  text-align: right;
}

.auth-forgot-hint {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: var(--muted, #5d6b80);
  line-height: 1.45;
}

.auth-link {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  white-space: nowrap;
}

.auth-link:hover {
  text-decoration: underline;
  color: var(--primary-dark);
}

.auth-submit {
  width: 100%;
  text-align: center;
  border-radius: 999px;
  padding: 0.85rem 1.1rem;
  font-size: 1rem;
  margin-top: 0.1rem;
}

.auth-message {
  min-height: 1.2em;
  margin: 0;
  text-align: center;
  line-height: 1.45;
  font-size: 0.9rem;
}

.auth-message a {
  font-weight: 700;
}

.auth-code-inline {
  font-size: 0.88em;
  background: #f0f4fc;
  padding: 0.08em 0.3em;
  border-radius: 4px;
  font-weight: 600;
}

.auth-or {
  position: relative;
  text-align: center;
  margin: 0.4rem 0 0.1rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--muted);
}

.auth-or::before,
.auth-or::after {
  content: "";
  position: absolute;
  top: 50%;
  width: calc(50% - 5.5rem);
  height: 1px;
  background: var(--border);
}

.auth-or::before {
  left: 0;
}

.auth-or::after {
  right: 0;
}

.auth-or span {
  position: relative;
  display: inline-block;
  padding: 0 0.5rem;
  background: var(--white);
  z-index: 1;
}

.auth-social {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.auth-social__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid var(--primary);
  border-radius: 12px;
  color: var(--text);
  background: #fff9fa;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.auth-social__btn:hover {
  background: #ffe6e8;
  color: var(--primary);
  transform: translateY(-1px);
}

.auth-footer {
  margin: 0.35rem 0 0;
  text-align: center;
  font-size: 0.95rem;
  color: var(--muted);
  font-weight: 500;
}

.auth-inline,
.auth-inline-link {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  font-weight: 700;
  color: var(--primary);
  cursor: pointer;
  text-decoration: none;
  display: inline;
}

.reset-password-page {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem 4rem;
}

.reset-password-page .auth-card {
  width: 100%;
  max-width: 28rem;
  margin: 0 auto;
}

.reset-password-back {
  display: inline-block;
  margin-bottom: 1.25rem;
  font-size: 0.9rem;
  color: var(--accent, #bf1f2b);
  text-decoration: none;
}

.reset-password-back:hover {
  text-decoration: underline;
}

.auth-inline:hover,
.auth-inline-link:hover {
  text-decoration: underline;
  color: var(--primary-dark);
}

.auth-name-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 0.5rem;
  min-width: 0;
  width: 100%;
}

.auth-name-row .auth-field {
  min-width: 0;
  max-width: 100%;
}

.auth-terms {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.86rem;
  line-height: 1.45;
  font-weight: 500;
  color: var(--muted);
  margin: 0.1rem 0 0;
  cursor: pointer;
}

.auth-terms input {
  margin-top: 0.2rem;
  width: 1.05rem;
  height: 1.05rem;
  flex-shrink: 0;
  accent-color: var(--primary);
  cursor: pointer;
}

.auth-terms a {
  color: var(--primary);
  font-weight: 700;
  text-decoration: none;
}

.auth-terms a:hover {
  text-decoration: underline;
  color: var(--primary-dark);
}

@media (max-width: 960px) {
  .hero-split {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .hero-visual {
    min-height: clamp(22rem, 58vw, 32rem);
  }

  .hero-visual__stage {
    min-height: clamp(20rem, 50vw, 30rem);
  }

  .hero {
    padding: 2.5rem 0 3rem;
  }
}

@media (max-width: 900px) {
  .about,
  .cards,
  .steps,
  .gallery {
    grid-template-columns: 1fr 1fr;
  }

  /* Instagram: 3 kolone (ne 2 kao ostale galerije u ovom prekidu) — stil u #galerija #instagramGallery */
  #galerija #instagramGallery.gallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .logo {
    max-width: min(100%, 17.5rem);
  }

  .logo-img {
    height: clamp(2.05rem, 7.2vw, 2.55rem);
  }

  .topbar-inner {
    flex-direction: column;
    gap: 0.2rem;
  }

  .nav-toolbar {
    margin-left: auto;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.75rem;
    min-height: 2.75rem;
    border-radius: 10px;
    color: var(--text);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }

  .menu-toggle:active {
    background: #f0f4fc;
  }

  .menu {
    flex: 0 0 auto;
    justify-content: flex-start;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 30;
    background: #fff;
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 0.65rem 1rem 1rem;
    display: none;
    align-items: stretch;
    gap: 0.15rem;
    max-height: min(75vh, calc(100dvh - 5.5rem));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  }

  .menu li {
    width: 100%;
  }

  .menu.open {
    display: flex;
  }

  .menu a {
    min-height: 2.75rem;
    padding: 0.5rem 0.35rem;
    box-sizing: border-box;
    width: 100%;
    border-radius: 8px;
  }

  .menu a:active {
    background: #f0f4fc;
  }

  .auth-nav {
    width: auto;
    justify-content: flex-end;
    flex-wrap: nowrap;
    gap: 0.3rem;
  }

  .auth-nav-icon {
    display: inline-flex;
  }

  .auth-nav .auth-nav-btn .auth-nav-label {
    display: none;
  }

  .nav-toolbar .auth-nav .auth-nav-btn {
    width: 2.75rem;
    min-width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    box-sizing: border-box;
    border-radius: 12px;
  }

  .user-menu-icon {
    display: inline-flex;
  }

  .user-menu-trigger {
    max-width: none;
    width: 2.75rem;
    min-width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    justify-content: center;
    box-sizing: border-box;
  }

  .user-menu-trigger .user-greeting,
  .user-menu-trigger .user-menu-chevron {
    display: none;
  }

  .auth-name-row {
    grid-template-columns: 1fr;
  }

  .about,
  .cards,
  .steps,
  .gallery {
    grid-template-columns: 1fr;
    display: grid;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    display: grid;
    justify-items: center;
    text-align: center;
  }

  .hero-visual {
    min-height: clamp(24rem, 64vw, 36rem);
  }

  .hero-visual__stage {
    min-height: clamp(22rem, 55vh, 34rem);
  }

  .footer-brand,
  .footer-contact {
    align-items: center;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 22rem;
    text-align: center;
  }

  .footer-social {
    justify-content: center;
  }

  .footer-email {
    text-align: center;
  }

  .hero-highlights-row {
    flex-wrap: wrap;
    margin-top: 1.5rem;
    gap: 0.55rem;
  }

  .hero-highlight-box {
    flex: 1 1 calc(50% - 0.3rem);
    min-width: calc(50% - 0.3rem);
    padding: 0.85rem 0.55rem;
  }

  .hero-highlight-box:last-child:nth-child(odd) {
    flex: 1 1 100%;
    min-width: 100%;
  }

  .hero {
    padding: 1.65rem 0 2.25rem;
  }

  .hero--split h1 {
    font-size: clamp(1.55rem, 7.5vw + 0.2rem, 2.65rem);
    line-height: 1.12;
    word-break: break-word;
  }

  .hero-split__content .lead {
    font-size: clamp(0.95rem, 3.8vw, 1.05rem);
  }

  .cta-group {
    flex-direction: column;
    align-items: stretch;
    gap: 0.65rem;
    margin: 1.1rem 0 1rem;
  }

  .cta-group .btn {
    width: 100%;
    text-align: center;
    box-sizing: border-box;
  }

  .section {
    padding: 2.35rem 0;
  }

  .section-head {
    margin-bottom: 1.1rem;
  }

  h2 {
    font-size: clamp(1.35rem, 6vw + 0.2rem, 2.1rem);
  }

  .modal {
    padding: max(0.5rem, env(safe-area-inset-top, 0px)) max(0.65rem, env(safe-area-inset-right, 0px))
      max(0.85rem, env(safe-area-inset-bottom, 0px)) max(0.65rem, env(safe-area-inset-left, 0px));
    align-items: flex-end;
  }

  .modal.open {
    align-items: flex-end;
  }

  .modal-card,
  .modal-card.auth-card {
    width: 100%;
    max-width: 100%;
    max-height: min(90dvh, 100%);
    border-radius: 16px 16px 0 0;
    margin-top: auto;
  }

  .order-modal.open {
    align-items: flex-end;
  }

  .order-modal-card {
    width: 100%;
    max-width: 100%;
    max-height: min(88dvh, 100%);
    padding: 1.15rem 1rem 1.1rem;
    border-radius: 16px 16px 0 0;
    margin-top: auto;
  }

  .ki-card {
    padding: 1.5rem 1.15rem 1.85rem;
  }

  .footer {
    padding: 2rem 0 max(1rem, env(safe-area-inset-bottom, 0px));
  }

  /* Korpa + obavještenja: cijela širina; top + layer na mobitelu postavlja i script.js (premeštaj u body). */
  .nav-cart-wrap .cart-dropdown,
  .nav-notif-wrap .nav-notif-dropdown {
    position: fixed;
    z-index: 100;
    top: calc(env(safe-area-inset-top, 0px) + 2.1rem + 2.1rem + 2.1rem);
    left: max(0.5rem, env(safe-area-inset-left, 0px));
    right: max(0.5rem, env(safe-area-inset-right, 0px));
    width: auto;
    max-width: none;
    transform: none;
    margin: 0;
  }

  .cart-dropdown {
    max-height: min(72vh, 28rem);
  }

  .nav-notif-dropdown {
    max-height: min(70vh, 24rem);
  }

  .cart-list__item {
    gap: 0.45rem;
    padding: 0.55rem 0.7rem;
  }

  .cart-list__label {
    font-size: 0.84rem;
    line-height: 1.45;
    overflow-wrap: anywhere;
  }

  .cart-list__meta {
    font-size: 0.7rem;
    line-height: 1.5;
    overflow-wrap: anywhere;
  }

  .nav-notif-item-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.3rem;
  }

  .nav-notif-item time {
    white-space: normal;
  }

  .nav-notif-item strong {
    overflow-wrap: anywhere;
  }

  .cart-dropdown-foot {
    padding: 0.55rem 0.7rem 0.75rem;
  }

  .cart-dropdown-foot .cart-clear-btn {
    display: block;
    width: 100%;
    text-align: center;
    box-sizing: border-box;
    padding: 0.6rem 0.5rem;
    border-radius: 10px;
    background: #f0f4fc;
  }

  .nav-notif-head {
    padding: 0.6rem 0.7rem;
  }

  .nav-notif-item {
    padding: 0.55rem 0.7rem;
  }

  .cart-toast {
    bottom: max(1rem, env(safe-area-inset-bottom, 0px));
    max-width: min(calc(100vw - 1.5rem), 380px);
  }

  .nav-inner {
    padding-top: max(0, env(safe-area-inset-top, 0px));
  }

  /* iOS: izbjegni automatski zoom u poljima ispod 16px */
  .auth-input,
  .order-form input,
  .order-form select,
  .order-form textarea,
  .ki-input,
  .ki-textarea {
    font-size: max(16px, 1rem);
  }

  #galerija #instagramGallery.gallery {
    padding: 0.85rem 0.7rem;
    gap: 0.7rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) and (min-height: 540px) {
  .modal.open {
    align-items: center;
  }

  .modal-card,
  .modal-card.auth-card {
    border-radius: 18px;
    max-height: min(90dvh, 900px);
  }

  .order-modal.open {
    align-items: center;
  }

  .order-modal-card {
    border-radius: 18px;
    max-height: min(92vh, 880px);
  }
}

/* 681–900px: ista “mobilna” korpa (JS i na širim slikovnicama postavlja panel). */
@media (min-width: 681px) and (max-width: 900px) {
  .nav-cart-wrap .cart-dropdown,
  .nav-notif-wrap .nav-notif-dropdown {
    position: fixed !important;
    left: max(0.5rem, env(safe-area-inset-left, 0px)) !important;
    right: max(0.5rem, env(safe-area-inset-right, 0px)) !important;
    width: auto !important;
    max-width: none !important;
    transform: none !important;
    z-index: 100 !important;
  }
}

@media (max-width: 420px) {
  .profile-notif-item-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
  }

  .profile-notif-item time {
    white-space: normal;
  }

  #galerija #instagramGallery.gallery {
    border-radius: 16px;
    padding: 0.6rem 0.5rem;
    gap: 0.5rem;
  }
}
