/*
 * Global styles. Colours live in theme.css — reference the tokens, never raw hex.
 */

/* Fonts */
@font-face {
  font-family: 'Inter-Variable';
  src: url("/assets/Inter-Variable-c6876acd.ttf") format('truetype');
  font-display: swap;
}

@font-face {
  font-family: 'Delius-Regular';
  src: url("/assets/Delius-Regular-8d9c8bad.ttf") format('truetype');
  font-display: swap;
}

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

/* Body */
body {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 100vh;
  font-family: 'Inter-Variable';
  font-size: 1rem;
  line-height: 1.5;
  background: var(--bg);
  color: var(--text);
  transition: background 0.4s ease, color 0.4s ease;
  padding-bottom: 6rem; /* space for floating footer */
}

/* Headings */
h1, h2, h3, h4 {
  font-family: 'Delius-Regular';
  color: var(--heading);
  line-height: 1.25;
}
h1 {
  font-size: 2.4rem;
  margin: 0.2rem;
}
h2 {
  font-size: 2rem;
  margin: 1.5rem;
}
h3 {
  font-size: 1.5rem;
}
h4 {
  font-size: 1.2rem;
}

/* ============================================================
   The brand button. One definition, many hooks.
   `all: unset` is needed so <button> and <input type=submit>
   shed their user-agent styling before we restyle them.
   ============================================================ */
.btn,
.base-link,
.table-row-action,
.action-row a,
.action-row button,
.action-row form input[type="submit"],
form input[type="submit"],
form button[type="submit"],
form input[type="file"]::file-selector-button {
  all: unset;
  box-sizing: border-box;
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  text-decoration: none;
  padding: 0.6rem 0.9rem;
  background: var(--btn-bg);
  border-radius: 0.4rem;
  width: auto;
  color: var(--btn-text);
  font-family: 'Inter-Variable';
  font-size: 0.95rem;
  font-weight: 600;
  box-shadow: var(--shadow-btn);
  transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease, transform 0.2s ease;
}

.btn:hover,
.base-link:hover,
.table-row-action:hover,
.action-row a:hover,
.action-row button:hover,
.action-row form input[type="submit"]:hover,
form input[type="submit"]:hover,
form button[type="submit"]:hover,
form input[type="file"]::file-selector-button:hover {
  background: var(--btn-bg-hover);
  color: var(--btn-text-hover);
  box-shadow: none;
  transform: scale(0.97);
}

.btn:focus-visible,
.base-link:focus-visible,
.action-row a:focus-visible,
.action-row button:focus-visible,
form input[type="submit"]:focus-visible,
form button[type="submit"]:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

.base-link {
  margin: 0.4rem;
}

/* Icon inside the link */
.base-icon {
  width: 1.5rem;
  height: 1.5rem;
  margin-right: 0.4rem;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.base-link:hover .base-icon {
  opacity: 0.7;
  transform: scale(1.5);
}

/* ============================================================
   Flash messages
   ============================================================ */
.flash {
  position: fixed;
  top: 4.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1200;
  min-width: 16rem;
  max-width: min(90vw, 32rem);
  padding: 0.9rem 1.2rem;
  border-radius: 0.6rem;
  font-weight: 600;
  text-align: center;
  background: var(--surface);
  color: var(--text);
  border-left: 4px solid var(--green);
  box-shadow: var(--shadow-lifted);
  animation: flashIn 0.35s ease forwards;
}

.flash.flash-alert {
  border-left-color: var(--danger);
}

.flash[hidden] {
  display: none;
}

.flash-dismissing {
  opacity: 0;
  transform: translate(-50%, -0.6rem);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

@keyframes flashIn {
  from { opacity: 0; transform: translate(-50%, -0.8rem); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

/* Utility Rows & Columns */
.start-row {
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
}
.end-row {
  display: flex;
  flex-direction: row;
  justify-content: flex-end;
}
.round-row {
  display: flex;
  flex-direction: row;
  justify-content: space-around;
  flex-wrap: wrap;
}
.end-column {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}
.start-column {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  align-content: center;
}
.start-column-0 {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.sparce-row{
  display:flex;
  flex-direction: row;
  justify-content: space-between;
}
.vertical-stretch-row{
  display: flex;
  flex-direction: row;
  justify-content:space-around;
}
.margin-bottom-3{
  margin-bottom: 4rem;
}
.margin-top-3{
  margin-bottom: 4rem;
}
.margin-right-1{
  margin-right: 1rem;
}
.muted {
  color: var(--text-muted);
}

.empty-state {
  text-align: center;
  color: var(--text-muted);
  padding: 2.5rem 0;
}

.product-name{
  font-family: 'Delius-Regular';
  color: var(--gold);
  font-size: 2rem;
  font-weight: bold;
  margin-bottom: 0.8rem;
  margin-top: 0.8rem;
}
.product-category{
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}
.category-sitemap ul {
  list-style: none;
  padding-left: 20px;
  margin: 8px 0;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
}

.map{
  width: 95%;
  height: 80vh;
  margin: auto;
  margin-bottom: 5rem;
  border-radius: 0.5rem;
  background: var(--bg);
}
.mapboxgl-canvas {
  background: transparent ;
}
.category-sitemap li {
  margin: 6px 0;
  padding: 0.4rem;
}
.category-sitemap a {
  color: var(--text);
  font-size: 1.2rem;
  text-decoration: none;
  border-radius: 0.4rem;
  padding: 0.6rem 0.8rem;
  transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}
.category-sitemap a:hover {
  background: var(--btn-bg);
  color: var(--btn-text);
  font-weight: 600;
  box-shadow: var(--shadow-btn);
}

/* Make deeper levels slightly smaller/lighter */
.category-sitemap ul ul a {
  font-size: 1rem;
  opacity: 0.9;
}

.category-sitemap ul ul ul a {
  font-size: 0.85rem;
  opacity: 0.8;
}
.product-price span strong{
  font-size: 2rem;
}
.max-width{
  width: 100%;
}
.mid-width{
  width: 50%;
}
.intro-content {
  padding: 0.3rem;
  max-width: 60ch;
  color: var(--text);
  animation: fadeUpGlass 1.4s ease forwards;
  transition: all 1s ease;
  border-radius: 2rem;
}
.intro-content ul li{
  font-size: 1rem;
  line-height: 1.6;
}

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

.glassmorphic {
  background: rgba(242, 242, 242, 0.15);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 1rem;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
  padding: 1rem;
}

/* Image */
.base-image {
  width: 14rem;
  height: 10rem;
  margin: 0.4rem;
  box-shadow: 0 6px 16px rgba(0,0,0,0.25);
}

/* Order Total */
.order-total {
  font-size: 1.2rem;
  font-weight: bold;
  margin-top: 4px;
}

/* Site-wide content column: keeps pages readable on wide monitors instead of
   letting sections drift to the viewport edges. */
.site-main {
  width: 100%;
  max-width: 78rem;
  margin: 0 auto;
  padding: 0 1.2rem;
}

/* Page Container */
.page-container {
  width: 95%;
  max-width: 900px;
  margin: 1rem auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Card Styling */
.card {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 0.6rem;
  padding: 1rem 0.7rem;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lifted);
}
.card h3 {
  margin-bottom: 0.6rem;
  font-size: 1.6rem;
  color: var(--heading);
}
.card p {
  margin: 0.3rem 0;
  font-size: 0.95rem;
  line-height: 1.5;
}
.grey-gradient{
  border-radius: 1rem;
  background: linear-gradient(
    135deg,
    rgba(15, 15, 30, 0.5) 0%,
    rgba(40, 40, 60, 0.95) 100%
  );
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 20px rgba(0,0,0,0.4);
  padding: 0.5rem;
  margin: 0.8rem;
}
.table-row{
  margin: 0.4rem;
  padding: 0.6rem 0.8rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.4rem;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 400;
  text-align:center;
}
.table-row-action{
  margin: 0.1rem;
  padding: 0.25rem 0.4rem;
  font-size: 0.9rem;
  font-weight: 400;
}

.table-column{
  margin: 0.5rem;
}

/* Card structure */
.order-card {
  display: flex;
  flex-direction: column;
}

/* Header */
.order-card-header {
  padding: 1rem 1.4rem;
  border-bottom: 1px solid var(--glass-border);
}

.order-card-header h3 {
  margin: 0;
  color: var(--gold);
  font-size: 2rem;
  letter-spacing: 0.5px;
}

/* Body */
.order-card-body {
  padding: 1.4rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
  border-bottom: 1px solid var(--glass-border);
}

/* Each row */
.detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 0.95rem;
}

.label {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--gold);
}

.dark-label {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
}

.value {
  font-size: 1.05rem;
  font-weight: 500;
  text-align: right;
  color: var(--text);
}

/* Inside the dark glass cards the value sits on a dark gradient regardless of theme */
.flat-bg .value,
.sub-card .value {
  color: var(--text-on-dark);
}

.step{
  background: var(--flat-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 20px rgba(0,0,0,0.4);
  border-radius: 1rem;
  padding: 0.5rem;
  margin: 0.8rem;
  display:flex;
  flex-direction: column;
  align-content: center;
  align-items: center;
}

.step-icon {
  width: 4rem;
  margin-right: 0.4rem;
  margin-top: 1rem;
}
.step-icon:hover {
  opacity: 0.7;
}
.step-arrow{
  height: 2.5rem;
}
.step-arrow:hover{
  opacity: 0.7;
}
.step-description{
  font-family: 'Delius-Regular';
  font-size: 1rem;
  line-height: 1.5rem;
  font-weight: bold;
  width: 15ch;
  margin-top: 1rem;
  color:var(--text);
}
.step-description-2{
  font-family: 'Delius-Regular';
  font-size: 1rem;
  line-height: 1.5rem;
  font-weight: bold;
  width: 20ch;
  margin-top: 1rem;
  color: var(--text);
  text-align: center;
}
.step-row{
  display:flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
}
.step-number{
  font-family: 'Delius-Regular';
  font-size: 2rem;
  margin-top: 3rem;
  color: var(--text);
}
.step-slash{
  font-family: 'Delius-Regular';
  font-size: 2rem;
  margin: -0.8rem;
  color: var(--heading);
}
.step-slash-2{
  font-family: 'Delius-Regular';
  font-size: 3rem;
  margin-top: 3rem;
  color: var(--heading);
}
.step-insert{
  margin-top: -1rem;
}
/* Grouped Row */
.card-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Sub Card (glassmorphic) */
.sub-card {
  flex: 1 1 calc(50% - 1rem);
  border-radius: 0.5rem;
  padding: 0.8rem 1rem;
  box-shadow: 0 6px 16px rgba(0,0,0,0.25);

  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.15) 0%,
    rgba(15, 34, 64, 0.95) 100%
  );
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);

  color: var(--text-on-dark);
}
.sub-card h4 {
  color: var(--gold);
  margin-bottom: 0.4rem;
}
.sub-card p {
  margin: 0.35rem 0;
  font-size: 1rem;
  line-height: 1.5rem;
  font-weight: 600;
  color: var(--text-on-dark);
}
.sub-card strong {
  font-size: 0.8rem;
  color: var(--green);
  font-weight: 400;
}
.sub-card .label {
  color: var(--gold);
}

/* Action Row */
.action-row {
  display: flex;
  gap: 0.6rem;
  margin-top: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

/* Footer */
.footer {
  position: fixed;
  width: 100vw;
  bottom: 1vh;
  display: flex;
  flex-direction: row;
  justify-content: space-around;
}
.glass-border{
  border-radius: 1rem;
  border: 2px solid rgba(255, 255, 255, 0.3);
  padding: 0.4rem 0.2rem;
  margin-top: 0.5rem;
}
.glassy {
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  background-image: var(--glass-bg);
  border-radius: 1rem;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-glass);
  padding: 1rem;
  margin: 1rem;
}

/* Flat Card (Dark glass) */
.flat-bg {
  border-radius: 1rem;
  padding: 0.5rem;
  margin: 1rem 0;

  background: var(--flat-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 20px rgba(0,0,0,0.4);
}
.card.flat-bg h3 {
  margin-bottom: 1rem;
  font-size: 1.7rem;
  font-weight: 700;
}
.card.flat-bg p {
  margin: 0.4rem 0;
  font-size: 0.95rem;
  line-height: 1.5rem;
  font-weight: 500;
  color: var(--text-on-dark);
}
.card.flat-bg strong {
  font-weight: 600;
  color: var(--green);
}
.card.flat-bg .action-row {
  margin-top: 1.2rem;
  display: flex;
  gap: 1rem;
}

/* Scaffold form error block */
.form-errors {
  border: 1px solid var(--danger);
  border-radius: 0.5rem;
  padding: 0.8rem 1rem;
  color: var(--danger);
}
.form-errors h2 {
  font-size: 1.1rem;
  margin: 0 0 0.5rem;
  color: var(--danger);
}
