/* ELLIPAL — checkout page styles (extends ../css/styles.css tokens) */

[hidden] { display: none !important; }

body { min-height: 100vh; }

.co-header {
  border-bottom: 1px solid var(--border);
  background: color-mix(in oklab, var(--background) 85%, transparent);
  backdrop-filter: blur(16px);
  position: sticky;
  top: 0;
  z-index: 20;
}
.co-header-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  height: 72px;
}
.co-secure {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .8rem;
  color: var(--muted);
  font-weight: 600;
}
.co-secure svg { color: var(--neon); }
.co-lang { display: none; }
@media (min-width: 640px) {
  .co-lang {
    display: flex;
    align-items: center;
    gap: .4rem;
    border: 1px solid var(--border);
    border-radius: .75rem;
    padding: .45rem .8rem;
    background: var(--surface);
  }
  .co-lang select {
    appearance: none;
    background: transparent;
    border: none;
    color: var(--foreground);
    font: inherit;
    font-weight: 700;
    font-size: .8rem;
    cursor: pointer;
    outline: none;
  }
}

.co-main { padding: 40px 20px 80px; max-width: 1080px; }
.co-title { font-size: 1.8rem; margin-bottom: 1.75rem; }
@media (min-width: 768px) { .co-title { font-size: 2.4rem; } }

.co-empty {
  text-align: center;
  padding: 4rem 1rem;
  border: 1px dashed var(--border);
  border-radius: 1.5rem;
  display: grid;
  gap: 1.25rem;
  justify-items: center;
}
.co-empty p { color: var(--muted); font-size: 1.05rem; }

.co-grid { display: grid; gap: 2rem; }
@media (min-width: 900px) {
  .co-grid { grid-template-columns: 1fr 1.15fr; align-items: start; }
  .co-review { order: 2; position: sticky; top: 96px; }
  .co-form-wrap { order: 1; }
}

.co-review h2, .co-form-wrap h2 {
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
}

#co-items { display: grid; gap: .9rem; margin-bottom: 1.5rem; }

.co-item {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: .9rem;
  align-items: center;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 1rem;
  padding: .75rem;
}
.co-item img { width: 64px; height: 64px; border-radius: .75rem; object-fit: cover; border: 1px solid var(--border); }
.co-item-name { font-weight: 700; font-size: .9rem; line-height: 1.3; }
.co-item-variant { font-size: .75rem; color: var(--muted); margin-top: .2rem; }
.co-item-price { font-size: .8rem; color: var(--muted); margin-top: .35rem; }
.co-item-controls { display: flex; flex-direction: column; align-items: flex-end; gap: .5rem; }
.co-qty {
  display: flex;
  align-items: center;
  gap: .5rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: .2rem .5rem;
}
.co-qty button {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: none;
  background: var(--surface-2);
  color: var(--foreground);
  cursor: pointer;
  font-weight: 700;
  line-height: 1;
}
.co-qty span { font-size: .85rem; font-weight: 700; min-width: 14px; text-align: center; }
.co-remove {
  border: none;
  background: none;
  color: var(--muted);
  font-size: .72rem;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
}
.co-remove:hover { color: var(--destructive); }

.co-totals { border-top: 1px solid var(--border); padding-top: 1.25rem; display: grid; gap: .65rem; }
.co-totals-row { display: flex; align-items: center; justify-content: space-between; font-size: .9rem; }
.co-totals-row.muted { color: var(--muted); }
.co-totals-row.total { font-size: 1.2rem; font-weight: 800; border-top: 1px solid var(--border); padding-top: .65rem; margin-top: .15rem; }

.co-field { display: grid; gap: .4rem; margin-bottom: 1.1rem; }
.co-field label { font-size: .8rem; font-weight: 700; color: var(--muted); }
.co-field input,
.co-field select {
  height: 46px;
  border-radius: .8rem;
  border: 1px solid var(--input);
  background: var(--surface);
  color: var(--foreground);
  padding: 0 1rem;
  font: inherit;
  font-size: .9rem;
  outline: none;
}
.co-field input:focus,
.co-field select:focus { border-color: var(--neon); }
.co-field select { appearance: none; }
.co-field-row { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 560px) { .co-field-row { grid-template-columns: 1fr 1fr; } }

.co-error {
  font-size: .74rem;
  color: var(--destructive);
  min-height: 1em;
  display: block;
}
.co-field.has-error input,
.co-field.has-error select { border-color: var(--destructive); }

.co-required-note { font-size: .78rem; color: var(--muted); margin: .5rem 0 1.25rem; }
.co-no-charge-note {
  font-size: .82rem;
  color: var(--neon);
  background: color-mix(in oklab, var(--neon) 10%, transparent);
  border: 1px solid color-mix(in oklab, var(--neon) 30%, transparent);
  border-radius: .75rem;
  padding: .75rem 1rem;
  margin: 0 0 1.25rem;
}
.co-phone-group { display: grid; grid-template-columns: auto 1fr; gap: .6rem; }
.co-phone-group select {
  width: auto;
  min-width: 92px;
  padding: 0 .5rem;
}
.co-submit { padding: 1.1rem; font-size: .95rem; }
.co-submit[disabled] { opacity: .7; cursor: default; }

.co-success {
  text-align: center;
  max-width: 460px;
  margin: 3rem auto;
  padding: 3rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: 1.5rem;
  background: var(--surface);
  display: grid;
  gap: 1rem;
  justify-items: center;
}
.co-success-icon {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  background: color-mix(in oklab, var(--neon) 18%, transparent);
  color: var(--neon);
  display: grid;
  place-items: center;
}
.co-success p { color: var(--muted); font-size: .9rem; line-height: 1.6; }
.co-order-ref { font-size: .85rem; color: var(--foreground); }
