/* DF Decals Customer Service Portal – front-end styles.
   Everything is scoped to .dfd-csp so nothing else on the site is affected. */

.dfd-csp {
  --dfd-accent: #00C1CF;
  --dfd-accent-dark: #00949f;
  --dfd-accent-soft: rgba(0, 193, 207, .12);
  --dfd-ink: #23262b;
  --dfd-text: #3d424a;
  --dfd-muted: #6b717a;
  --dfd-line: #e3e6ea;
  --dfd-field: #f7f8fa;
  --dfd-red: #c93636;
  max-width: 1120px;
  margin: 0 auto;
  padding: 56px 20px 72px;
  color: var(--dfd-text);
  font-size: 16px;
  line-height: 1.5;
  text-align: left;
}
.dfd-csp *, .dfd-csp *::before, .dfd-csp *::after { box-sizing: border-box; }
.dfd-csp svg { display: block; flex: none; }
.dfd-csp a { color: var(--dfd-accent-dark); }

/* ---------- Header ---------- */
.dfd-csp .dfd-hero { margin: 0 0 36px; text-align: center; }
.dfd-csp .dfd-eyebrow {
  display: inline-block;
  margin: 0 0 14px;
  padding: 5px 14px;
  border: 1px solid rgba(0, 193, 207, .55);
  border-radius: 999px;
  background: rgba(0, 193, 207, .18);
  color: #9ff3f9;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.dfd-csp .dfd-hero h2 {
  margin: 0 0 10px;
  color: #fff;
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -.01em;
}
.dfd-csp .dfd-lead {
  max-width: 620px;
  margin: 0 auto;
  color: rgba(255, 255, 255, .86);
  font-size: 17px;
}
.dfd-csp .dfd-jump {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 24px 0 0;
}
.dfd-csp .dfd-jump a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid rgba(255, 255, 255, .25);
  border-radius: 999px;
  background: rgba(255, 255, 255, .08);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: background-color .15s, border-color .15s;
}
.dfd-csp .dfd-jump a:hover { background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .45); color: #fff; }
.dfd-csp .dfd-jump svg { width: 18px; height: 18px; }

/* ---------- Layout & cards ---------- */
.dfd-csp .dfd-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 24px;
  align-items: start;
}
.dfd-csp .dfd-card {
  position: relative;
  overflow: hidden;
  padding: 30px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,.06), 0 12px 32px rgba(0,0,0,.18);
  scroll-margin-top: 24px;
}
.dfd-csp .dfd-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: var(--dfd-accent);
}
.dfd-csp .dfd-card-wide { margin-top: 24px; }

.dfd-csp .dfd-card-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin: 0 0 22px;
  padding: 0 0 20px;
  border-bottom: 1px solid var(--dfd-line);
}
.dfd-csp .dfd-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: 12px;
  background: var(--dfd-accent-soft);
  color: var(--dfd-accent-dark);
}
.dfd-csp .dfd-icon svg { width: 22px; height: 22px; }
.dfd-csp .dfd-card-head h3 {
  margin: 0 0 2px;
  color: var(--dfd-ink);
  font-size: 22px;
  font-weight: 750;
  line-height: 1.3;
}
.dfd-csp .dfd-card-head p { margin: 0; color: var(--dfd-muted); font-size: 15px; }

/* ---------- Forms ---------- */
.dfd-csp .dfd-field { margin: 0 0 18px; }
.dfd-csp .dfd-field label {
  display: block;
  margin: 0 0 7px;
  color: var(--dfd-ink);
  font-size: 14px;
  font-weight: 650;
}
.dfd-csp .dfd-req { color: var(--dfd-red); }
.dfd-csp .dfd-optional { color: var(--dfd-muted); font-weight: 400; }
.dfd-csp .dfd-hint { margin: 6px 0 0; color: var(--dfd-muted); font-size: 13.5px; }

.dfd-csp .dfd-field input,
.dfd-csp .dfd-field select,
.dfd-csp .dfd-field textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  margin: 0;
  padding: 12px 14px;
  border: 1.5px solid #d4d8de;
  border-radius: 10px;
  background-color: var(--dfd-field);
  color: var(--dfd-ink);
  font: inherit;
  font-size: 16px; /* 16px stops iPhones zooming in on tap */
  line-height: 1.4;
  box-shadow: none;
  transition: border-color .15s, box-shadow .15s, background-color .15s;
  -webkit-appearance: none;
  appearance: none;
}
.dfd-csp .dfd-field textarea { min-height: 150px; resize: vertical; }
.dfd-csp .dfd-field textarea.dfd-short { min-height: 96px; }
.dfd-csp .dfd-field select {
  padding-right: 44px;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b717a' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px;
}
.dfd-csp .dfd-field ::placeholder { color: #9aa0a8; opacity: 1; }
.dfd-csp .dfd-field input:hover,
.dfd-csp .dfd-field select:hover,
.dfd-csp .dfd-field textarea:hover { border-color: #b8bec6; }
.dfd-csp .dfd-field input:focus,
.dfd-csp .dfd-field select:focus,
.dfd-csp .dfd-field textarea:focus {
  outline: none;
  border-color: var(--dfd-accent);
  background-color: #fff;
  box-shadow: 0 0 0 4px rgba(0, 193, 207, .2);
}
.dfd-csp .dfd-field input:user-invalid:not(:focus),
.dfd-csp .dfd-field textarea:user-invalid:not(:focus) { border-color: var(--dfd-red); }

.dfd-csp .dfd-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }

/* ---------- Buttons ---------- */
.dfd-csp .dfd-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 50px;
  margin: 4px 0 0;
  padding: 13px 24px;
  border: 0;
  border-radius: 10px;
  background: var(--dfd-accent);
  box-shadow: 0 2px 0 var(--dfd-accent-dark);
  color: #06272a;
  font: inherit;
  font-size: 16px;
  font-weight: 750;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .15s, transform .05s, box-shadow .15s;
}
.dfd-csp .dfd-btn:hover { background: #12d3e0; color: #06272a; }
.dfd-csp .dfd-btn:active { transform: translateY(1px); box-shadow: 0 1px 0 var(--dfd-accent-dark); }
.dfd-csp .dfd-btn:focus-visible { outline: none; box-shadow: 0 0 0 4px rgba(0, 193, 207, .35); }
.dfd-csp .dfd-btn svg { width: 18px; height: 18px; }
.dfd-csp .dfd-btn-dark { background: #3a3f46; box-shadow: 0 2px 0 #1f2226; color: #fff; }
.dfd-csp .dfd-btn-dark:hover { background: #23272c; color: #fff; }
.dfd-csp .dfd-btn-auto { width: auto; }

.dfd-csp .dfd-inline-form {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 14px;
  align-items: start;
}
.dfd-csp .dfd-inline-form .dfd-field { margin: 0; }
.dfd-csp .dfd-inline-form .dfd-btn { margin-top: 28px; min-width: 170px; }

/* ---------- Notices ---------- */
.dfd-csp .dfd-notice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 0 0 20px;
  padding: 14px 16px;
  border: 1px solid;
  border-radius: 10px;
  font-weight: 600;
}
.dfd-csp .dfd-notice svg { width: 20px; height: 20px; margin-top: 1px; }
.dfd-csp .dfd-notice p { flex: 1; margin: 0; text-align: left; }
.dfd-csp .dfd-success { background: #ecf9e6; border-color: #b5e4a1; color: #24520f; }
.dfd-csp .dfd-error { background: #fdeeee; border-color: #f1bcbc; color: #8a1f1f; }
.dfd-csp .dfd-empty { margin: 0; color: var(--dfd-muted); font-size: 15px; }

/* ---------- Badges ---------- */
.dfd-csp .dfd-badge {
  display: inline-block;
  padding: 4px 11px;
  border-radius: 999px;
  background: #eef0f3;
  color: var(--dfd-ink);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .03em;
  text-transform: uppercase;
  white-space: nowrap;
}
.dfd-csp .dfd-badge-info    { background: #e2f8fa; color: #00666e; }
.dfd-csp .dfd-badge-success { background: #e6f6dd; color: #2a6311; }
.dfd-csp .dfd-badge-warn    { background: #fff3d6; color: #7a5300; }
.dfd-csp .dfd-badge-danger  { background: #fde8e8; color: #8a1f1f; }

/* ---------- Order tracker results ---------- */
.dfd-csp .dfd-order {
  margin: 24px 0 0;
  padding: 20px;
  border: 1px solid var(--dfd-line);
  border-radius: 12px;
  background: #fafbfc;
}
.dfd-csp .dfd-order-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin: 0 0 14px;
}
.dfd-csp .dfd-order-head strong { color: var(--dfd-ink); font-size: 18px; }
.dfd-csp .dfd-dl { margin: 0; }
.dfd-csp .dfd-dl > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 9px 0;
  border-top: 1px solid var(--dfd-line);
}
.dfd-csp .dfd-dl dt { margin: 0; color: var(--dfd-muted); font-weight: 500; }
.dfd-csp .dfd-dl dd { margin: 0; color: var(--dfd-ink); font-weight: 600; text-align: right; }
.dfd-csp .dfd-dl dd ul { margin: 0; padding: 0; list-style: none; }
.dfd-csp .dfd-order h4 {
  margin: 16px 0 8px;
  color: var(--dfd-ink);
  font-size: 15px;
  font-weight: 700;
}
.dfd-csp .dfd-items { margin: 0; padding: 0; list-style: none; }
.dfd-csp .dfd-items li {
  display: flex;
  gap: 10px;
  padding: 8px 0;
  border-top: 1px solid var(--dfd-line);
}
.dfd-csp .dfd-qty { min-width: 32px; color: var(--dfd-muted); font-weight: 700; }

/* ---------- Tickets ---------- */
.dfd-csp .dfd-ticket {
  margin: 0 0 14px;
  border: 1px solid var(--dfd-line);
  border-radius: 12px;
  background: #fff;
}
.dfd-csp .dfd-ticket > summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  cursor: pointer;
  list-style: none;
}
.dfd-csp .dfd-ticket > summary::-webkit-details-marker { display: none; }
.dfd-csp .dfd-ticket > summary::after {
  content: "";
  width: 10px;
  height: 10px;
  flex: none;
  border-right: 2px solid var(--dfd-muted);
  border-bottom: 2px solid var(--dfd-muted);
  transform: rotate(45deg) translate(-2px, -2px);
  transition: transform .15s;
}
.dfd-csp .dfd-ticket[open] > summary::after { transform: rotate(-135deg) translate(-2px, -2px); }
.dfd-csp .dfd-ticket-title { flex: 1; min-width: 0; }
.dfd-csp .dfd-ticket-title strong { display: block; color: var(--dfd-ink); font-size: 17px; }
.dfd-csp .dfd-meta { color: var(--dfd-muted); font-size: 14px; }
.dfd-csp .dfd-ticket-body { padding: 4px 18px 18px; border-top: 1px solid var(--dfd-line); }

.dfd-csp .dfd-thread { display: flex; flex-direction: column; gap: 10px; margin: 14px 0 20px; }
.dfd-csp .dfd-msg {
  max-width: 85%;
  padding: 12px 16px;
  border-radius: 14px 14px 14px 4px;
  background: #f1f3f5;
  color: var(--dfd-text);
}
.dfd-csp .dfd-msg.staff {
  align-self: flex-end;
  border: 1px solid #b9edf1;
  border-radius: 14px 14px 4px 14px;
  background: #e2f8fa;
}
.dfd-csp .dfd-msg-meta { margin: 0 0 4px; color: var(--dfd-muted); font-size: 13px; }
.dfd-csp .dfd-msg-meta strong { color: var(--dfd-ink); }
.dfd-csp .dfd-msg-body p { margin: 0 0 8px; }
.dfd-csp .dfd-msg-body p:last-child { margin: 0; }
.dfd-csp .dfd-reply { padding: 18px 0 0; border-top: 1px solid var(--dfd-line); }
.dfd-csp .dfd-switch { margin: 16px 0 0; font-size: 14px; }

/* ---------- My Account → My Group ---------- */
.dfd-csp.dfd-gp { max-width: none; padding: 0; }
.dfd-csp .dfd-gp-switch { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.dfd-csp .dfd-gp-switch a {
  padding: 8px 14px;
  border: 1px solid var(--dfd-line);
  border-radius: 999px;
  background: #fff;
  color: var(--dfd-ink);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
.dfd-csp .dfd-gp-switch a.is-current { border-color: var(--dfd-accent); background: var(--dfd-accent-soft); color: #00666e; }
.dfd-csp .dfd-gp-head,
.dfd-csp .dfd-gp-section {
  margin: 0 0 18px;
  padding: 22px 24px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,.06), 0 6px 18px rgba(0,0,0,.08);
}
.dfd-csp .dfd-gp-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-top: 4px solid var(--dfd-accent);
}
.dfd-csp .dfd-gp-head h2 { margin: 0 0 6px; color: var(--dfd-ink); font-size: 24px; font-weight: 800; }
.dfd-csp .dfd-gp-head .dfd-btn { margin: 0; }
.dfd-csp .dfd-gp-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 14px;
}
.dfd-csp .dfd-gp-section-head h3 { margin: 0; color: var(--dfd-ink); font-size: 19px; font-weight: 750; }
.dfd-csp .dfd-gp-section-head .dfd-btn { margin: 0; min-height: 42px; padding: 9px 18px; font-size: 15px; }
.dfd-csp .dfd-gp-filter select {
  min-height: 42px;
  padding: 8px 40px 8px 12px;
  border: 1.5px solid #d4d8de;
  border-radius: 10px;
  background: var(--dfd-field) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b717a' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center / 16px;
  color: var(--dfd-ink);
  font: inherit;
  font-size: 15px;
  -webkit-appearance: none;
  appearance: none;
}
.dfd-csp .dfd-gp-orders { display: grid; gap: 12px; }
.dfd-csp .dfd-gp-order { padding: 14px 16px; border: 1px solid var(--dfd-line); border-radius: 12px; background: #fafbfc; }
.dfd-csp .dfd-gp-order header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin: 0 0 8px;
}
.dfd-csp .dfd-gp-order header strong { display: block; color: var(--dfd-ink); }
.dfd-csp .dfd-item-meta { display: block; color: var(--dfd-muted); font-size: 13.5px; }
.dfd-csp .dfd-gp-pager { display: flex; justify-content: space-between; gap: 10px; margin: 16px 0 0; }
.dfd-csp .dfd-gp-pager .dfd-btn { margin: 0; }
.dfd-csp .dfd-gp-tickets { margin: 0; padding: 0; list-style: none; }
.dfd-csp .dfd-gp-tickets a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 4px;
  border-top: 1px solid var(--dfd-line);
  color: var(--dfd-text);
  text-decoration: none;
}
.dfd-csp .dfd-gp-tickets a:hover strong { color: var(--dfd-accent-dark); }
.dfd-csp .dfd-gp-tickets strong { display: block; color: var(--dfd-ink); }
.dfd-csp .dfd-gp-subhead { margin: 18px 0 8px; color: var(--dfd-ink); font-size: 15px; font-weight: 700; }
.dfd-csp .dfd-gp-req { padding: 12px 14px; border-radius: 10px; background: var(--dfd-field); white-space: normal; }
.dfd-csp .screen-reader-text {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- Tablet / phone ---------- */
@media (max-width: 860px) {
  .dfd-csp { padding: 36px 16px 56px; }
  .dfd-csp .dfd-grid { grid-template-columns: 1fr; gap: 18px; }
  .dfd-csp .dfd-card-wide { margin-top: 18px; }
  .dfd-csp .dfd-hero { margin-bottom: 28px; }
  .dfd-csp .dfd-lead { font-size: 16px; }
  .dfd-csp .dfd-inline-form { grid-template-columns: 1fr 1fr; }
  .dfd-csp .dfd-inline-form .dfd-btn { grid-column: 1 / -1; width: 100%; margin-top: 0; }
}
@media (max-width: 560px) {
  .dfd-csp .dfd-card { padding: 22px 18px; border-radius: 14px; }
  .dfd-csp .dfd-card-head h3 { font-size: 20px; }
  .dfd-csp .dfd-icon { width: 40px; height: 40px; }
  .dfd-csp .dfd-row,
  .dfd-csp .dfd-inline-form { grid-template-columns: 1fr; }
  .dfd-csp .dfd-jump a { flex: 1 1 100%; justify-content: center; }
  .dfd-csp .dfd-msg { max-width: 100%; }
  .dfd-csp .dfd-ticket > summary { padding: 14px; }
  .dfd-csp .dfd-ticket-body { padding: 4px 14px 14px; }
}
