* {
  box-sizing: border-box;
}

:root {
  --green: #69A333;
  --green-dark: #69A333;
  --text: #222;
  --muted: #777;
  --border: #d8ded4;
  --background: #ffffff;
  --white: #ffffff;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--background);
  color: var(--text);
}

/* BRANDING TOGGLE */

.branding-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 16px 18px;
    margin-bottom: 20px;
    background: #fff;
    border: 1px solid #d8ded4;
    border-radius: 8px;
}

.branding-toggle > div {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.branding-toggle strong {
    font-size: 14px;
}

.branding-toggle span {
    color: #777;
    font-size: 12px;
}

.toggle-switch {
    position: relative;
    width: 46px;
    height: 26px;
    padding: 0;
    border: 0;
    border-radius: 20px;
    background: #cfd5cb;
    cursor: pointer;
}

.toggle-switch span {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    transition: transform 0.2s ease;
}

.toggle-switch.on {
    background: #2563eb;
}

.toggle-switch.on span {
    transform: translateX(20px);
}

/* =========================================================
   MAIN
========================================================= */

main {
  width: 100%;
  max-width: 1100px;
  margin: 40px auto;
  padding: 0 24px;
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 32px;
  align-items: start;
}

.layout > section {
  min-width: 0;
}

/* =========================================================
   NORTHSTAR LOGO
========================================================= */

  .topbar {
    min-height: 72px;
    padding: 0 28px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.158);
    background: #ffffff;
    color: #fff;
        }

.brand {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.brand img {
    display: block;
    width: 150px;
    max-width: 150px;
    height: auto;
    max-height: 52px;
    object-fit: contain;
}

/* Keep old .logo markup working too */
.logo {
  width: 100%;
  margin: 0 0 28px;
}

.logo img {
  display: block;
  width: 150px;
  max-width: 150px;
  height: auto;
  max-height: 52px;
  object-fit: contain;
}

/* =========================================================
   HEADINGS
========================================================= */

h1 {
  margin: 0 0 22px;
  font-size: 30px;
  line-height: 1.2;
  font-weight: 600;
}

/* =========================================================
   CHECKOUT STEPS
========================================================= */

.checkout-step {
  width: 100%;
  margin-bottom: 12px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.checkout-step.active {
  border-color: var(--green);
}

.step-header {
  width: 100%;
  min-height: 68px;
  margin: 0;
  padding: 16px 18px;

  display: flex;
  align-items: center;
  gap: 13px;

  border: 0;
  border-radius: 0;

  background: var(--white);
  color: var(--text);

  font-family: inherit;
  font-size: 15px;
  font-weight: 600;

  text-align: left;
  cursor: pointer;
}

.step-header:hover {
  background: #fafbf9;
}

.step-header:active {
  transform: none;
}

.step-number {
  flex: 0 0 32px;

  width: 32px;
  height: 32px;

  border-radius: 50%;

  display: flex;
  align-items: center;
  justify-content: center;

  background: #e9ede7;
  color: #666;

  font-size: 14px;
  font-weight: 600;
}

.checkout-step.active .step-number,
.checkout-step.completed .step-number {
  background: var(--green);
  color: var(--white);
}

.step-heading {
  min-width: 0;
  flex: 1;

  font-size: 16px;
  font-weight: 600;
}

.step-summary {
  display: block;

  max-width: 220px;

  color: var(--muted);
  font-size: 13px;
  font-weight: 400;

  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.step-chevron {
  flex: 0 0 auto;

  color: #777;
  font-size: 20px;
  line-height: 1;

  transition: transform 0.2s ease;
}

.checkout-step.active .step-chevron {
  transform: rotate(180deg);
}

/* =========================================================
   STEP CONTENT
========================================================= */

.step-content {
  display: none;
  padding: 0 20px 20px;
}

.checkout-step.active .step-content {
  display: block;
}

/* =========================================================
   FORM FIELDS
========================================================= */

.field {
  margin-bottom: 18px;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

label {
  display: block;
  margin-bottom: 7px;

  font-size: 14px;
  font-weight: 600;
}

/* =========================================================
   INPUTS
========================================================= */

input,
select {
  width: 100%;
  height: 46px;

  padding: 0 13px;

  border: 1px solid #cfd5cb;
  border-radius: 5px;

  background: var(--white);
  color: var(--text);

  font-family: inherit;
  font-size: 15px;
}

input:focus,
select:focus {
  outline: none;

  border-color: var(--green);

  box-shadow: 0 0 0 2px rgba(73, 133, 10, 0.1);
}

/* =========================================================
   RADIO OPTIONS
========================================================= */

label.choice {
  display: flex;
  align-items: center;

  width: 100%;
  min-height: 66px;

  margin: 0 0 10px;
  padding: 13px 15px;

  border: 1px solid var(--border);
  border-radius: 6px;

  background: var(--white);

  cursor: pointer;
}

label.choice:hover {
  border-color: #b9c3b4;
}

label.choice input[type="radio"] {
  width: 18px;
  height: 18px;

  flex: 0 0 18px;

  margin: 0 12px 0 0;
  padding: 0;

  accent-color: var(--green);
}

label.choice > span {
  display: flex;
  flex-direction: column;
  gap: 3px;

  font-size: 14px;
  font-weight: 600;
}

/* =========================================================
   DEMO NOTICE
========================================================= */

.demo-notice {
  margin-bottom: 20px;
  padding: 14px 16px;

  border: 1px solid #d8ded4;
  border-radius: 6px;

  background: #f5f7f3;
}

.demo-notice strong {
  display: block;
  margin-bottom: 5px;

  color: var(--green-dark);

  font-size: 13px;
  font-weight: 700;
}

.demo-notice p {
  margin: 0;

  color: var(--muted);

  font-size: 13px;
  line-height: 1.5;
}

/* =========================================================
   STEP ACTIONS
========================================================= */

.step-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;

  gap: 12px;

  margin-top: 22px;
}

.cta,
.secondary {
  min-width: 105px;
  height: 44px;

  padding: 0 22px;

  border-radius: 15px;

  font-family: inherit;
  font-size: 14px;
  font-weight: 600;

  cursor: pointer;
}

.cta {
  border: 1px solid var(--green);
  background: var(--green);
  color: var(--white);
}

.cta:hover {
  border-color: var(--green-dark);
  background: var(--green-dark);
}

.cta:active,
.secondary:active {
  transform: translateY(1px);
}

.secondary {
  border: 1px solid #cfd5cb;
  background: var(--white);
  color: var(--text);
}

.secondary:hover {
  background: #f5f7f3;
  border-color: #b8c1b4;
}

/* =========================================================
   ORDER SUMMARY
========================================================= */

.summary {
  position: sticky;
  top: 24px;

  width: 100%;

  padding: 22px;

  background: var(--white);

  border: 1px solid var(--border);
  border-radius: 8px;
}

.summary h2 {
  margin: 0 0 20px;

  font-size: 20px;
  line-height: 1.3;
  font-weight: 600;
}

/* =========================================================
   PRODUCT
========================================================= */

.product {
  display: grid;

  grid-template-columns: minmax(0, 1fr) auto;

  gap: 12px;

  align-items: start;

  padding-bottom: 20px;

  border-bottom: 1px solid #e4e7e2;
}

.product strong {
  display: block;

  font-size: 14px;
  line-height: 1.35;
}

.product span {
  display: block;

  margin-top: 4px;

  color: var(--muted);

  font-size: 12px;
}

/* =========================================================
   PRICE ROWS
========================================================= */

.rows {
  padding: 16px 0;

  border-bottom: 1px solid #e4e7e2;
}

.rows > div {
  display: flex;
  align-items: center;
  justify-content: space-between;

  gap: 15px;

  margin-bottom: 10px;

  font-size: 14px;
}

.rows > div:last-child {
  margin-bottom: 0;
}

.rows > div span:first-child {
  color: var(--muted);
}

/* =========================================================
   TOTAL
========================================================= */

.total {
  display: flex;
  align-items: center;
  justify-content: space-between;

  gap: 15px;

  padding: 18px 0;

  font-size: 17px;
  font-weight: 600;
}

/* PRODUCT IMAGE */
.product-img {
    width: 68px;
    height: 68px;
    flex: 0 0 68px;
    border-radius: 6px;
    background: #f1f3ef;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;
}

/* Actual product image */
.product-img img {
    display: block;
    width: 100%;
    height: 100%;

    object-fit: contain;
    object-position: center;

    max-width: 100%;
    max-height: 100%;
}

/* Product text */
.product-name {
    font-size: 14px;
    line-height: 1.35;
    font-weight: 600;
}

.product-meta {
    margin-top: 4px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.35;
}

/* Keep the product row neat */
.product {
    display: flex;
    align-items: center;
    gap: 12px;

    width: 100%;
    padding-bottom: 20px;
    border-bottom: 1px solid #e4e7e2;
}

.product > div:nth-child(2) {
    min-width: 0;
    flex: 1;
}

.price {
    flex: 0 0 auto;
    white-space: nowrap;
    font-size: 14px;
    font-weight: 600;
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 800px) {

  main {
    margin: 25px auto;
    padding: 0 15px;
  }

  .layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .summary {
    position: static;
  }

  .brand,
  .logo {
    margin-bottom: 22px;
  }

  .brand img,
  .logo img {
    width: 140px;
    max-width: 140px;
    max-height: 46px;
  }

  h1 {
    font-size: 25px;
    margin-bottom: 18px;
  }

  .field-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .step-header {
    min-height: 62px;
    padding: 14px 15px;
  }

  .step-content {
    padding: 0 15px 18px;
  }

  .step-actions {
    margin-top: 18px;
  }

  .step-actions .cta,
  .step-actions .secondary {
    flex: 1;
  }

  .step-summary {
    max-width: 130px;
  }
}

/* =========================================================
   SMALL PHONES
========================================================= */

/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 800px) {

  .topbar {
    width: 100%;
    height: 72px;
    min-height: 72px;
    padding: 0 15px;

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
  }

  .topbar .brand {
    width: 100%;
    height: 100%;
    margin: 0;

    display: flex;
    align-items: center;
    justify-content: center;
  }

  .topbar .brand img {
    display: block;
    width: 150px;
    max-width: 150px;
    height: auto;
    max-height: 50px;
    margin: 0;
    object-fit: contain;
  }

  main {
    margin: 25px auto;
    padding: 0 15px;
  }

  .layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .summary {
    position: static;
  }

  .brand,
  .logo {
    margin-bottom: 22px;
  }

  .topbar .brand {
    margin-bottom: 0;
  }

  .brand img,
  .logo img {
    width: 140px;
    max-width: 140px;
    max-height: 46px;
  }

  .topbar .brand img {
    width: 150px;
    max-width: 150px;
    max-height: 50px;
  }

  h1 {
    font-size: 25px;
    margin-bottom: 18px;
  }

  .field-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .step-header {
    min-height: 62px;
    padding: 14px 15px;
  }

  .step-content {
    padding: 0 15px 18px;
  }

  .step-actions {
    margin-top: 18px;
  }

  .step-actions .cta,
  .step-actions .secondary {
    flex: 1;
  }

  .step-summary {
    max-width: 130px;
  }
}


/* =========================================================
   SMALL PHONES
========================================================= */

@media (max-width: 420px) {

  .topbar {
    height: 68px;
    min-height: 68px;
  }

  .topbar .brand img {
    width: 145px;
    max-width: 145px;
    max-height: 46px;
  }

  main {
    padding: 0 10px;
    margin-top: 18px;
  }

  .brand img,
  .logo img {
    width: 125px;
    max-width: 125px;
  }

  .topbar .brand img {
    width: 145px;
    max-width: 145px;
  }

  .step-header {
    padding: 13px;
  }

  .step-content {
    padding: 0 13px 16px;
  }

  .step-heading {
    font-size: 15px;
  }

  .step-summary {
    display: none;
  }

  .summary {
    padding: 18px;
  }
}
