/* ==========================================================================
   Discord Timestamp Generator — Global Stylesheet
   Design language inspired by Linear / Stripe / Discord
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Design Tokens
   -------------------------------------------------------------------------- */
:root {
  /* Brand */
  --blurple: #5865f2;
  --blurple-dark: #4752c4;
  --blurple-darker: #3c45a5;
  --blurple-soft: #eef0ff;
  --blurple-ring: rgba(88, 101, 242, 0.35);

  /* Neutrals */
  --white: #ffffff;
  --bg: #ffffff;
  --bg-subtle: #f7f8fa;
  --card: #ffffff;
  --card-alt: #f4f5f7;
  --border: #e6e8ec;
  --border-strong: #d5d8de;

  /* Text */
  --text: #000000;
  --text-muted: #20242c;
  --text-soft: #545a68;

  /* Feedback */
  --success: #22a06b;
  --success-soft: #e7f7ef;
  --danger: #d92d20;
  --danger-soft: #fdeceb;

  /* Radius */
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --radius-pill: 999px;

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(16, 24, 40, 0.05);
  --shadow-sm: 0 2px 8px rgba(16, 24, 40, 0.06);
  --shadow-md: 0 8px 24px rgba(16, 24, 40, 0.08);
  --shadow-lg: 0 20px 48px rgba(16, 24, 40, 0.12);
  --shadow-blurple: 0 10px 30px rgba(88, 101, 242, 0.30);

  /* Layout */
  --container: 1120px;
  --container-narrow: 780px;
  --nav-height: 68px;

  /* Typography */
  --font-sans: "Poppins", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  --font-mono: "SFMono-Regular", ui-monospace, "Cascadia Code", "Fira Code",
    Consolas, "Liberation Mono", Menlo, monospace;

  /* Motion */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --transition: 180ms var(--ease);
}

/* --------------------------------------------------------------------------
   2. Reset & Base
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--nav-height) + 20px);
}

body {
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img,
picture,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--blurple);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--blurple-dark);
}

h1,
h2,
h3,
h4 {
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text);
  font-weight: 700;
}

/* Poppins renders heavier: 600 keeps subheads and card titles crisp */
h3,
h4 {
  font-weight: 600;
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
}

h2 {
  font-size: clamp(1.7rem, 3.5vw, 2.4rem);
}

h3 {
  font-size: 1.25rem;
}

p {
  color: var(--text-muted);
}

ul,
ol {
  color: var(--text-muted);
}

:focus-visible {
  outline: 3px solid var(--blurple-ring);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Accessibility helper */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 200;
  background: var(--blurple);
  color: #fff;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: top var(--transition);
}

.skip-link:focus {
  top: 12px;
  color: #fff;
}

/* --------------------------------------------------------------------------
   3. Layout Helpers
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 24px;
}

.section {
  padding-block: clamp(28px, 4.2vw, 48px);
}

.section--tight {
  padding-block: clamp(20px, 3vw, 34px);
}

.section--subtle {
  background: var(--bg-subtle);
}

.section-head {
  max-width: 680px;
  margin: 0 auto clamp(20px, 3vw, 32px);
  text-align: center;
}

.section-head p {
  margin-top: 14px;
  font-size: 1.08rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--blurple);
  background: var(--blurple-soft);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  margin-bottom: 18px;
}

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

/* --------------------------------------------------------------------------
   4. Buttons
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  padding: 14px 24px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: transform var(--transition), box-shadow var(--transition),
    background var(--transition), border-color var(--transition),
    color var(--transition);
  text-decoration: none;
}

.btn:active {
  transform: translateY(1px);
}

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

.btn--primary:hover {
  background: var(--blurple-dark);
  color: #fff;
  box-shadow: 0 12px 34px rgba(88, 101, 242, 0.38);
  transform: translateY(-1px);
}

.btn--secondary {
  background: var(--card-alt);
  color: var(--text);
  border-color: var(--border);
}

.btn--secondary:hover {
  background: #ececf1;
  color: var(--text);
  border-color: var(--border-strong);
}

.btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.btn--ghost:hover {
  background: var(--card-alt);
  color: var(--text);
}

.btn--block {
  width: 100%;
}

.btn--lg {
  padding: 16px 30px;
  font-size: 1.05rem;
}

.btn__icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   5. Navigation
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
}

.nav {
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.12rem;
  letter-spacing: -0.02em;
  color: var(--text);
}

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

.brand__mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--blurple);
  box-shadow: var(--shadow-blurple);
}

.brand__mark svg {
  width: 22px;
  height: 22px;
}

.nav__menu {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  padding: 0;
}

.nav__link {
  display: inline-block;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.97rem;
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
}

.nav__link:hover {
  color: var(--text);
  background: var(--card-alt);
}

.nav__link[aria-current="page"] {
  color: var(--blurple);
  background: var(--blurple-soft);
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav__toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 0;
  place-items: center;
}

.nav__toggle svg {
  width: 22px;
  height: 22px;
  color: var(--text);
}

.nav__toggle .icon-close {
  display: none;
}

.nav__toggle[aria-expanded="true"] .icon-open {
  display: none;
}

.nav__toggle[aria-expanded="true"] .icon-close {
  display: block;
}

@media (max-width: 860px) {
  .nav__toggle {
    display: grid;
  }

  .nav__cta {
    display: none;
  }

  .nav__menu {
    position: fixed;
    inset: var(--nav-height) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    padding: 16px 24px 24px;
    box-shadow: var(--shadow-md);
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition), transform var(--transition),
      visibility var(--transition);
  }

  .nav__menu.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .nav__link {
    padding: 13px 14px;
    font-size: 1.05rem;
  }
}

/* --------------------------------------------------------------------------
   6. Hero
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  padding-block: clamp(32px, 5vw, 52px) clamp(24px, 3.5vw, 36px);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -280px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 620px;
  background: radial-gradient(
    ellipse at center,
    rgba(88, 101, 242, 0.14),
    rgba(88, 101, 242, 0) 68%
  );
  z-index: -1;
  pointer-events: none;
}

.hero__inner {
  max-width: 800px;
  margin-inline: auto;
  text-align: center;
}

.hero h1 {
  margin-bottom: 20px;
}

.hero__lead {
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto 30px;
}

.hero__actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero__meta {
  margin-top: 26px;
  display: flex;
  gap: 22px;
  justify-content: center;
  flex-wrap: wrap;
  font-size: 0.9rem;
  color: var(--text-soft);
}

.hero__meta span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.hero__meta svg {
  width: 16px;
  height: 16px;
  color: var(--success);
}

.gradient-text {
  background: linear-gradient(100deg, var(--blurple), #8b95ff 60%, #c084fc);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* --------------------------------------------------------------------------
   7. Tool / Generator
   -------------------------------------------------------------------------- */
.tool {
  scroll-margin-top: calc(var(--nav-height) + 24px);
}

.tool__card {
  max-width: 940px;
  margin-inline: auto;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.tool__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.tool__panel {
  padding: clamp(24px, 4vw, 40px);
}

.tool__panel--form {
  border-right: 1px solid var(--border);
}

.tool__panel--output {
  background: var(--bg-subtle);
}

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

  .tool__panel--form {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
}

.tool__panel-title {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-soft);
  margin-bottom: 22px;
}

.field {
  margin-bottom: 20px;
}

.field__label {
  display: block;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.field__hint {
  font-size: 0.82rem;
  color: var(--text-soft);
  margin-top: 6px;
}

.field__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.input,
.select {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text);
  background: var(--white);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  transition: border-color var(--transition), box-shadow var(--transition);
  appearance: none;
}

.input:focus,
.select:focus {
  outline: none;
  border-color: var(--blurple);
  box-shadow: 0 0 0 4px var(--blurple-ring);
}

.select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%235a6072' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 42px;
}

.tool__actions {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}

/* Output */
.output {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.output__label {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.output__code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 1.05rem;
  color: var(--blurple-darker);
  background: var(--white);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  word-break: break-all;
  min-height: 58px;
}

.output__code code {
  font-family: var(--font-mono);
}

.output__preview {
  margin-top: 20px;
}

.output__preview-label {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-soft);
  margin-bottom: 10px;
}

/* Discord-style rendered chip */
.discord-chip {
  display: inline-block;
  background: rgba(88, 101, 242, 0.12);
  color: var(--blurple-darker);
  font-weight: 500;
  padding: 3px 6px;
  border-radius: 5px;
  transition: background var(--transition);
}

.discord-message {
  display: flex;
  gap: 14px;
  background: #313338;
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-top: 14px;
}

.discord-message__avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--blurple);
  flex-shrink: 0;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 700;
}

.discord-message__body {
  min-width: 0;
}

.discord-message__meta {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 3px;
}

.discord-message__name {
  color: #f2f3f5;
  font-weight: 600;
  font-size: 0.98rem;
}

.discord-message__time {
  color: #949ba4;
  font-size: 0.72rem;
}

.discord-message__text {
  color: #dbdee1;
  font-size: 0.98rem;
  line-height: 1.5;
}

.discord-message__text .discord-chip {
  background: rgba(88, 101, 242, 0.28);
  color: #c9cdfb;
}

.output__actions {
  display: flex;
  gap: 12px;
  margin-top: auto;
  padding-top: 22px;
}

/* Toast / feedback */
.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translate(-50%, 20px);
  background: var(--text);
  color: #fff;
  padding: 13px 20px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  font-weight: 500;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition), transform var(--transition),
    visibility var(--transition);
  z-index: 300;
}

.toast.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.toast svg {
  width: 18px;
  height: 18px;
  color: #6ee7b7;
}

.toast--error svg {
  color: #fca5a5;
}

.field-error {
  color: var(--danger);
  font-size: 0.82rem;
  margin-top: 6px;
  min-height: 1px;
}

.input.is-invalid,
.select.is-invalid {
  border-color: var(--danger);
  box-shadow: 0 0 0 4px var(--danger-soft);
}

/* --------------------------------------------------------------------------
   8. Cards / Features / Benefits
   -------------------------------------------------------------------------- */
.grid {
  display: grid;
  gap: 22px;
}

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

.grid--2 {
  grid-template-columns: repeat(2, 1fr);
}

@media (max-width: 900px) {
  .grid--3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 620px) {
  .grid--3,
  .grid--2 {
    grid-template-columns: 1fr;
  }
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow-xs);
  transition: transform var(--transition), box-shadow var(--transition),
    border-color var(--transition);
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.card__icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--blurple-soft);
  color: var(--blurple);
  margin-bottom: 18px;
}

.card__icon svg {
  width: 24px;
  height: 24px;
}

.card h3 {
  margin-bottom: 10px;
}

.card p {
  font-size: 0.97rem;
  margin: 0;
}

/* Benefit list (2-col with checks) */
.benefits {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}

@media (max-width: 820px) {
  .benefits {
    grid-template-columns: 1fr;
  }
}

.benefits h2 {
  margin-bottom: 16px;
}

.benefit-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 16px;
}

.benefit-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.benefit-list .check {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--success-soft);
  color: var(--success);
  margin-top: 2px;
}

.benefit-list .check svg {
  width: 15px;
  height: 15px;
}

.benefit-list strong {
  color: var(--text);
  display: block;
  margin-bottom: 2px;
}

.benefit-list span {
  color: var(--text-muted);
  font-size: 0.96rem;
}

.panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: clamp(24px, 4vw, 34px);
}

/* --------------------------------------------------------------------------
   9. Formats table
   -------------------------------------------------------------------------- */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-xs);
  background: var(--card);
}

table.formats {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
}

.formats th,
.formats td {
  text-align: left;
  padding: 15px 20px;
  border-bottom: 1px solid var(--border);
  font-size: 0.96rem;
}

.formats thead th {
  background: var(--card-alt);
  color: var(--text);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.formats tbody tr:last-child td {
  border-bottom: none;
}

.formats tbody tr:hover {
  background: var(--bg-subtle);
}

.formats code {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  background: var(--blurple-soft);
  color: var(--blurple-darker);
  padding: 3px 8px;
  border-radius: 6px;
  white-space: nowrap;
}

.formats .example {
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   10. FAQ
   -------------------------------------------------------------------------- */
.faq {
  max-width: var(--container-narrow);
  margin-inline: auto;
  display: grid;
  gap: 14px;
}

.faq-item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-xs);
  overflow: hidden;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.faq-item[open] {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  cursor: pointer;
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--text);
  list-style: none;
}

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

.faq-item summary .plus {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  color: var(--blurple);
  transition: transform var(--transition);
}

.faq-item[open] summary .plus {
  transform: rotate(45deg);
}

.faq-item .faq-body {
  padding: 0 24px 22px;
}

.faq-item .faq-body p {
  margin: 0;
  font-size: 0.98rem;
}

/* --------------------------------------------------------------------------
   11. CTA band
   -------------------------------------------------------------------------- */
.cta-band {
  position: relative;
  background: linear-gradient(135deg, var(--blurple), var(--blurple-darker));
  border-radius: var(--radius-lg);
  padding: clamp(40px, 6vw, 68px);
  text-align: center;
  color: #fff;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.cta-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
      circle at 20% 20%,
      rgba(255, 255, 255, 0.16),
      transparent 40%
    ),
    radial-gradient(circle at 85% 80%, rgba(255, 255, 255, 0.12), transparent 45%);
  pointer-events: none;
}

.cta-band h2 {
  color: #fff;
  position: relative;
}

.cta-band p {
  color: rgba(255, 255, 255, 0.88);
  max-width: 560px;
  margin: 14px auto 28px;
  position: relative;
}

.cta-band .btn--primary {
  background: #fff;
  color: var(--blurple-dark);
  box-shadow: var(--shadow-md);
  position: relative;
}

.cta-band .btn--primary:hover {
  background: #f4f4ff;
  color: var(--blurple-darker);
}

/* --------------------------------------------------------------------------
   12. Article / Legal / Content pages
   -------------------------------------------------------------------------- */
.page-hero {
  padding-block: clamp(28px, 4vw, 44px) clamp(16px, 2.5vw, 26px);
  text-align: center;
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border);
}

.page-hero .container {
  max-width: 760px;
}

.page-hero h1 {
  margin-bottom: 14px;
}

.page-hero p {
  font-size: 1.1rem;
}

.prose {
  max-width: var(--container-narrow);
  margin-inline: auto;
}

.prose h2 {
  font-size: 1.6rem;
  margin-top: 40px;
  margin-bottom: 14px;
}

.prose h3 {
  font-size: 1.2rem;
  margin-top: 28px;
  margin-bottom: 10px;
}

.prose p {
  margin-bottom: 16px;
  color: var(--text-muted);
}

.prose ul,
.prose ol {
  margin: 0 0 18px;
  padding-left: 22px;
}

.prose li {
  margin-bottom: 8px;
  color: var(--text-muted);
}

.prose a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

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

.prose .meta-updated {
  font-size: 0.9rem;
  color: var(--text-soft);
  margin-bottom: 28px;
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(28px, 4vw, 48px);
  align-items: start;
}

@media (max-width: 820px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }
}

.contact-cards {
  display: grid;
  gap: 16px;
}

.contact-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-xs);
}

.contact-card .card__icon {
  margin-bottom: 0;
  width: 42px;
  height: 42px;
}

.contact-card h3 {
  font-size: 1.05rem;
  margin-bottom: 3px;
}

.contact-card p {
  margin: 0;
  font-size: 0.94rem;
}

textarea.input {
  resize: vertical;
  min-height: 140px;
  line-height: 1.55;
}

/* --------------------------------------------------------------------------
   13. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  margin-top: auto;
  background: #0f1117;
  color: #b7bcc8;
  padding-block: clamp(48px, 6vw, 72px) 32px;
}

.footer__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
}

@media (max-width: 820px) {
  .footer__top {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}

@media (max-width: 480px) {
  .footer__top {
    grid-template-columns: 1fr;
  }
}

.footer__brand .brand {
  color: #fff;
}

.footer__brand p {
  margin-top: 14px;
  color: #8b92a3;
  font-size: 0.94rem;
  max-width: 300px;
}

.footer__col h3 {
  color: #fff;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.footer__col ul {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 11px;
}

.footer__col a {
  color: #b7bcc8;
  font-size: 0.95rem;
}

.footer__col a:hover {
  color: #fff;
}

.footer__bottom {
  margin-top: 44px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.9rem;
  color: #8b92a3;
}

.footer__bottom a {
  color: #b7bcc8;
}

.footer__bottom a:hover {
  color: #fff;
}

/* --------------------------------------------------------------------------
   14. Utilities & motion preferences
   -------------------------------------------------------------------------- */
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

/* --------------------------------------------------------------------------
   15. Blog article
   -------------------------------------------------------------------------- */
.breadcrumb {
  font-size: 0.88rem;
  color: var(--text-soft);
  margin-bottom: 20px;
}

.breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 0;
  margin: 0;
}

.breadcrumb li {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-soft);
}

.breadcrumb li + li::before {
  content: "/";
  color: var(--border-strong);
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  align-items: center;
  font-size: 0.9rem;
  color: var(--text-soft);
  margin: 14px 0 28px;
}

.article-meta .dot {
  color: var(--border-strong);
}

.callout {
  background: var(--blurple-soft);
  border: 1px solid #dfe3ff;
  border-radius: var(--radius);
  padding: 22px 24px;
  margin: 0 0 30px;
}

.callout h2 {
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--blurple);
  margin: 0 0 10px;
}

.callout ul {
  margin: 0;
  padding-left: 20px;
}

.callout li {
  margin-bottom: 6px;
}

.toc {
  margin: 0 0 36px;
}

.toc h2 {
  font-size: 1rem !important;
  margin: 0 0 12px !important;
}

.toc ol {
  margin: 0;
  padding-left: 20px;
}

.toc a {
  text-decoration: none;
}

.toc a:hover {
  text-decoration: underline;
}

.prose code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--blurple-soft);
  color: var(--blurple-darker);
  padding: 2px 7px;
  border-radius: 6px;
  word-break: break-word;
}

.prose pre {
  background: #0f1117;
  color: #e6e8ec;
  padding: 18px 20px;
  border-radius: var(--radius);
  overflow-x: auto;
  margin: 0 0 20px;
  box-shadow: var(--shadow-sm);
}

.prose pre code {
  background: none;
  color: inherit;
  padding: 0;
  font-size: 0.92rem;
}

.prose figure {
  margin: 0 0 22px;
}

.prose figcaption {
  font-size: 0.85rem;
  color: var(--text-soft);
  margin-top: 8px;
}

.related-grid {
  margin-top: 24px;
}

.related-grid .card h3 {
  font-size: 1.08rem;
}

/* --------------------------------------------------------------------------
   15b. Homepage content components (format cards, steps, testimonials, posts)
   -------------------------------------------------------------------------- */
/* Format reference cards */
.format-card p {
  font-size: 0.95rem;
  margin: 0 0 6px;
}

.format-card code {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  background: var(--card-alt);
  border: 1px solid var(--border);
  padding: 2px 7px;
  border-radius: var(--radius-sm);
  color: var(--text);
}

/* Numbered step cards */
.step-card {
  position: relative;
}

.step-card__num {
  position: absolute;
  top: 18px;
  right: 20px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--blurple);
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  box-shadow: var(--shadow-blurple);
}

/* Testimonials */
.testimonial {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.testimonial__stars {
  display: inline-flex;
  gap: 3px;
  color: #f5b53f;
}

.testimonial__stars svg {
  width: 18px;
  height: 18px;
}

.testimonial blockquote {
  margin: 0;
}

.testimonial blockquote p {
  color: var(--text);
  font-size: 1rem;
  line-height: 1.6;
  margin: 0;
}

.testimonial__by {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 600;
}

/* Recommended blog posts (4-column row) */
.grid--4 {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 980px) {
  .grid--4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .grid--4 {
    grid-template-columns: 1fr;
  }
}

.post-card {
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
}

.post-card__media {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, var(--blurple) 0%, var(--blurple-darker) 100%);
  color: #fff;
  overflow: hidden;
}

.post-card__media svg {
  width: 40px;
  height: 40px;
}

.post-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition);
}

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

/* Blog listing card featured image */
.blog-card__media {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius) var(--radius) 0 0;
  background: linear-gradient(135deg, var(--blurple) 0%, var(--blurple-darker) 100%);
  margin: -26px -26px 18px;
}

.blog-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition);
}

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

/* Article featured image (below H1) */
.article-figure {
  margin: 0 0 28px;
}

.article-figure img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.article-figure figcaption {
  margin-top: 10px;
  font-size: 0.88rem;
  color: var(--text-soft);
  text-align: center;
}

/* Homepage feature image (in About section) */
.about-figure {
  margin: 0 0 8px;
}

.about-figure img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}

/* Related blog posts block at the end of each article */
.related-posts {
  margin-top: clamp(32px, 5vw, 48px);
  padding-top: clamp(28px, 4vw, 40px);
  border-top: 1px solid var(--border);
}

.related-posts > h2 {
  text-align: center;
  margin-bottom: clamp(20px, 3vw, 28px);
}

.post-card h3 {
  font-size: 1.05rem;
  margin: 20px 22px 8px;
}

.post-card p {
  font-size: 0.92rem;
  margin: 0 22px 16px;
}

.post-card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: auto 22px 22px;
  color: var(--blurple);
  font-weight: 600;
  font-size: 0.92rem;
}

.post-card__link svg {
  width: 16px;
  height: 16px;
  transition: transform var(--transition);
}

.post-card:hover .post-card__link svg {
  transform: translateX(3px);
}

/* --------------------------------------------------------------------------
   16. Enhanced Timestamp Generator
   -------------------------------------------------------------------------- */
.field__opt {
  font-weight: 400;
  color: var(--text-soft);
}

.tool__settings {
  padding: clamp(24px, 4vw, 40px);
}

.tool__settings-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.tool__quick {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.chip-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--card-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 7px 14px;
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition),
    color var(--transition), transform var(--transition);
}

.chip-btn:hover {
  color: var(--blurple);
  border-color: var(--blurple-ring);
  background: var(--blurple-soft);
}

.chip-btn:active {
  transform: translateY(1px);
}

.chip-btn svg {
  width: 15px;
  height: 15px;
}

.tool__fields {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px 22px;
}

@media (max-width: 620px) {
  .tool__fields {
    grid-template-columns: 1fr;
  }
}

/* Generate button + loading spinner */
#generate-btn {
  position: relative;
}

.btn__spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 50%;
  animation: btn-spin 0.6s linear infinite;
}

.btn.is-loading .btn__spinner {
  display: inline-block;
}

.btn.is-loading .btn__label {
  display: none;
}

@keyframes btn-spin {
  to {
    transform: rotate(360deg);
  }
}

/* Results area */
.tool__results {
  padding: clamp(24px, 4vw, 40px);
  border-top: 1px solid var(--border);
  background: var(--bg-subtle);
}

.results-empty {
  text-align: center;
  padding: 30px 20px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  color: var(--text-muted);
}

.results-empty__icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  margin: 0 auto 14px;
  border-radius: 14px;
  background: var(--blurple-soft);
  color: var(--blurple);
}

.results-empty__icon svg {
  width: 28px;
  height: 28px;
}

.results-empty p {
  font-weight: 600;
  color: var(--text);
  margin: 0 0 4px;
}

.results-empty span {
  font-size: 0.9rem;
  color: var(--text-soft);
}

.results-empty kbd {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  background: var(--card-alt);
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: 5px;
  padding: 1px 6px;
}

.results-body {
  animation: results-in 0.28s var(--ease);
}

@keyframes results-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Unix row */
.unix-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  box-shadow: var(--shadow-xs);
  margin-bottom: 22px;
}

.results-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-soft);
  margin: 0 0 4px;
}

.unix-value {
  font-family: var(--font-mono);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--blurple-darker);
  letter-spacing: 0.01em;
}

/* Results table */
.results-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
  background: var(--card);
}

.results-table th,
.results-table td {
  text-align: left;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.results-table thead th {
  background: var(--card-alt);
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.results-table tbody tr:last-child td {
  border-bottom: none;
}

.results-table tbody tr:hover {
  background: var(--bg-subtle);
}

.results-table .fmt-name {
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

.results-table .fmt-name small {
  display: block;
  font-weight: 500;
  color: var(--text-soft);
  font-size: 0.8rem;
}

.results-table .fmt-syntax code {
  font-family: var(--font-mono);
  font-size: 0.88rem;
  background: var(--blurple-soft);
  color: var(--blurple-darker);
  padding: 4px 9px;
  border-radius: 6px;
  white-space: nowrap;
}

.results-table .fmt-preview {
  color: var(--text);
}

.results-table .fmt-copy {
  text-align: right;
  white-space: nowrap;
}

/* Copy button + copied state */
.copy-btn {
  cursor: pointer;
}

.copy-btn.is-copied {
  background: var(--success-soft);
  border-color: var(--success);
  color: var(--success);
}

.copy-all-btn.is-copied {
  background: var(--success);
  border-color: var(--success);
  color: #fff;
  box-shadow: none;
}

.btn--sm {
  padding: 8px 14px;
  font-size: 0.88rem;
}

.results-actions {
  display: flex;
  gap: 12px;
  margin-top: 22px;
  flex-wrap: wrap;
}

@media (max-width: 480px) {
  .results-actions .btn {
    flex: 1 1 auto;
  }
}

/* --------------------------------------------------------------------------
   17. Dark mode (scoped so the tool stays legible on dark OS themes)
   -------------------------------------------------------------------------- */
@media (prefers-color-scheme: dark) {
  .tool__results {
    background: #1a1c22;
    border-top-color: #2a2d36;
  }

  .tool .unix-row,
  .tool .results-table,
  .tool .results-empty {
    background: #232630;
    border-color: #2f3340;
  }

  .tool .results-table thead th {
    background: #2a2d38;
    color: #e6e8ec;
  }

  .tool .results-table th,
  .tool .results-table td {
    border-bottom-color: #2f3340;
  }

  .tool .results-table tbody tr:hover {
    background: #2a2d38;
  }

  .tool .results-table .fmt-name,
  .tool .results-table .fmt-preview,
  .tool .results-empty p {
    color: #e6e8ec;
  }

  .tool .results-table .fmt-name small,
  .tool .results-label,
  .tool .results-empty span {
    color: #9aa0b0;
  }

  .tool .fmt-syntax code,
  .tool .unix-value {
    background: rgba(88, 101, 242, 0.22);
    color: #c9cdfb;
  }

  .tool .chip-btn {
    background: #2a2d38;
    border-color: #363a47;
    color: #c3c8d4;
  }

  .tool .chip-btn:hover {
    background: rgba(88, 101, 242, 0.2);
    color: #c9cdfb;
  }

  .tool .results-empty {
    border-style: dashed;
    border-color: #363a47;
  }

  .tool .results-empty kbd {
    background: #2a2d38;
    border-color: #363a47;
    color: #c3c8d4;
  }

  .tool .btn--secondary {
    background: #2a2d38;
    border-color: #363a47;
    color: #e6e8ec;
  }

  .tool .btn--secondary:hover {
    background: #333743;
  }

  .tool .copy-btn.is-copied {
    background: rgba(34, 160, 107, 0.2);
    border-color: var(--success);
    color: #6ee7b7;
  }
}

/* --------------------------------------------------------------------------
   18. Primary CTA — "Generate all formats" (scoped to #generate-btn only)
   -------------------------------------------------------------------------- */
#generate-btn {
  /* Rounder corners to sit in the same family as the input fields */
  border-radius: 12px;
  padding: 16px 28px;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  color: #fff;
  border: 1px solid rgba(60, 69, 165, 0.55);
  /* Subtle brand gradient for depth */
  background: linear-gradient(180deg, #6c77f6 0%, var(--blurple) 48%, var(--blurple-dark) 100%);
  /* Soft, layered shadow with a faint inner highlight on top */
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 8px 20px rgba(88, 101, 242, 0.35),
    0 2px 6px rgba(88, 101, 242, 0.22);
  transition:
    transform 200ms var(--ease),
    box-shadow 200ms var(--ease),
    background 200ms var(--ease),
    filter 200ms var(--ease);
}

/* Perfectly align the icon with the label text */
#generate-btn .btn__label {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

#generate-btn .btn__icon {
  width: 19px;
  height: 19px;
}

/* Hover: gentle lift + brighter gradient + deeper shadow */
#generate-btn:hover {
  transform: translateY(-2px);
  background: linear-gradient(180deg, #7b85f8 0%, #5f6bf4 48%, var(--blurple) 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 14px 30px rgba(88, 101, 242, 0.42),
    0 4px 10px rgba(88, 101, 242, 0.30);
}

/* Active: settles down so it feels genuinely pressable */
#generate-btn:active {
  transform: translateY(0);
  filter: saturate(1.03);
  box-shadow:
    inset 0 1px 2px rgba(60, 69, 165, 0.35),
    0 3px 10px rgba(88, 101, 242, 0.28);
}

/* Focus: modern accessibility ring (keyboard users) */
#generate-btn:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 4px var(--blurple-ring),
    0 8px 20px rgba(88, 101, 242, 0.35);
}

/* Disabled: elegant and clearly inert, no lift */
#generate-btn:disabled,
#generate-btn[disabled] {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
  filter: grayscale(0.15);
  box-shadow: 0 2px 6px rgba(88, 101, 242, 0.18);
}

/* Comfortable on small screens (already full-width via .btn--block) */
@media (max-width: 480px) {
  #generate-btn {
    padding: 15px 22px;
    font-size: 1rem;
  }
}
