/* Meridian Shipping Services — site stylesheet
   Layout: one document column; hairline rules divide sections the way a chart
   panel divides its blocks. Accent taken from the logo's marine blue. */
/* ------------------------------------------------------------------- base
   These three came from the drafting host's own page skeleton. These files are
   served raw, so they belong in the stylesheet now. */
html { color-scheme: light; }
body { margin: 0; }
img { max-width: 100%; }

:root {
  --paper:   #F2F3F1;
  --panel:   #E7E9E6;
  --ink:     #0E1C1F;
  --sea:     #3B5B60;
  --sounding:#6B7A77;
  --rule:    #CBD1CE;
  --accent:  #1A5FB4;
  --accent-deep: #14315F;
  --accent-soft: rgba(26, 95, 180, 0.10);
  --flag:    #B5175F;
  --flag-soft: rgba(181, 23, 95, 0.10);

  --display: "IBM Plex Sans Condensed", "Helvetica Neue", Arial, sans-serif;
  --body:    "IBM Plex Serif", Georgia, "Times New Roman", serif;
  --data:    "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper:   #0B1416;
    --panel:   #121F22;
    --ink:     #E4E9E7;
    --sea:     #9FB6B3;
    --sounding:#78908C;
    --rule:    #22363B;
    --accent:  #6BA8F5;
    --accent-deep: #9CC5FA;
    --accent-soft: rgba(107, 168, 245, 0.13);
    --flag:    #FF69A8;
    --flag-soft: rgba(255, 105, 168, 0.12);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper:   #0B1416;
  --panel:   #121F22;
  --ink:     #E4E9E7;
  --sea:     #9FB6B3;
  --sounding:#78908C;
  --rule:    #22363B;
  --accent:  #6BA8F5;
  --accent-deep: #9CC5FA;
  --accent-soft: rgba(107, 168, 245, 0.13);
  --flag:    #FF69A8;
  --flag-soft: rgba(255, 105, 168, 0.12);
  color-scheme: dark;
}

* { box-sizing: border-box; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: 68rem;
  margin: 0 auto;
  padding-inline: 16px;
  padding-block: 0;
}

/* ---------------------------------------------------------------- masthead */

.masthead { border-bottom: 1px solid var(--rule); }
.masthead .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem 1.5rem;
  align-items: center;
  justify-content: space-between;
  padding-block: 0.9rem;
}
.wordmark {
  display: flex; align-items: center; gap: 0.7rem; min-width: 0;
  text-decoration: none; color: inherit;
}
.wordmark:hover .mark { color: var(--accent); }
.wordmark img { width: 2.7rem; height: auto; flex: none; }
.wordmark .names { display: flex; flex-direction: column; min-width: 0; }
.wordmark .mark {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.12rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.1;
}
.wordmark .sub {
  font-family: var(--data);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sounding);
}
.masthead nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.15rem;
  font-family: var(--display);
  font-size: 0.84rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.masthead nav a {
  color: var(--sea);
  text-decoration: none;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
}
.masthead nav a:hover, .masthead nav a:focus-visible {
  color: var(--ink);
  border-bottom-color: var(--accent);
}

/* ------------------------------------------------------------------- hero */

.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--rule); }
.hero .wrap {
  padding-block: clamp(2.5rem, 6vw, 4.25rem);
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2rem;
  align-items: center;
}
@media (min-width: 54rem) {
  .hero .wrap { grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.9fr); gap: 3rem; }
}
.hero-art { justify-self: center; max-width: 16rem; width: 100%; }
.hero-art img { width: 100%; height: auto; display: block; }

.soundings {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  font-family: var(--data); font-size: 0.66rem;
  color: var(--sounding); opacity: 0.24; overflow: hidden;
}
.soundings span { position: absolute; }

.eyebrow {
  font-family: var(--data);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1rem;
}
h1 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.95rem, 5.6vw, 3.2rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
  text-wrap: balance;
  margin: 0 0 1.1rem;
  max-width: 20ch;
}
.lede {
  font-size: clamp(1rem, 2vw, 1.14rem);
  line-height: 1.62;
  max-width: 52ch;
  margin: 0 0 1.6rem;
  color: var(--sea);
}
.lede strong { color: var(--ink); font-weight: 500; }

.hero-meta {
  display: flex; flex-wrap: wrap; gap: 0.5rem 1.75rem;
  font-family: var(--data); font-size: 0.72rem;
  letter-spacing: 0.04em; color: var(--sounding);
  border-top: 1px solid var(--rule); padding-top: 1rem;
  max-width: 52ch;
}

/* ---------------------------------------------------------------- sections */

section { border-bottom: 1px solid var(--rule); }
section .wrap { padding-block: clamp(2.25rem, 5vw, 3.5rem); }

.label {
  font-family: var(--data);
  font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--sounding); margin: 0 0 1.4rem;
  display: flex; align-items: center; gap: 0.75rem;
}
.label::after { content: ""; flex: 1; height: 1px; background: var(--rule); }

h2 {
  font-family: var(--display); font-weight: 600;
  font-size: clamp(1.38rem, 3.2vw, 1.85rem);
  line-height: 1.2; letter-spacing: -0.01em;
  text-wrap: balance; margin: 0 0 0.9rem; max-width: 28ch;
}
h3.sub {
  font-family: var(--display); font-weight: 600;
  font-size: 1.05rem; margin: 2rem 0 0.7rem;
}
section p { max-width: 62ch; margin: 0 0 1rem; }
section p:last-child { margin-bottom: 0; }

/* ---------------------------------------------------------------- services */

.services {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1px; background: var(--paper);
  border: 1px solid var(--rule); margin-top: 1.6rem;
}
.service { background: var(--paper); box-shadow: 0 0 0 1px var(--rule); padding: 1.3rem 1.25rem 1.4rem; min-width: 0; }
.service h3 {
  font-family: var(--display); font-weight: 600;
  font-size: 1rem; margin: 0 0 0.45rem;
}
.service p {
  font-size: 0.9rem; line-height: 1.55;
  color: var(--sea); margin: 0; max-width: none;
}

/* ---------------------------------------------------------------- diagrams */

figure { margin: 1.8rem 0 0; }
figure svg { display: block; width: 100%; height: auto; }
figcaption {
  font-family: var(--data); font-size: 0.7rem; line-height: 1.6;
  color: var(--sounding); margin-top: 0.7rem; max-width: 62ch;
}
.diagram-frame {
  border: 1px solid var(--rule);
  background: var(--panel);
  padding: 1.1rem 1rem;
  overflow-x: auto;
}
.diagram-frame > svg { min-width: 20rem; }

/* -------------------------------------------------------------- particulars */

.particulars-wrap { overflow-x: auto; margin-top: 1.6rem; }
table {
  border-collapse: collapse; width: 100%; min-width: 27rem;
  font-family: var(--data); font-size: 0.82rem;
  font-variant-numeric: tabular-nums;
}
caption {
  text-align: left; font-family: var(--data);
  font-size: 0.68rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--sounding); padding-bottom: 0.6rem;
}
th, td {
  text-align: left; padding: 0.55rem 0.9rem 0.55rem 0;
  border-bottom: 1px solid var(--rule); vertical-align: baseline;
}
th { font-weight: 500; color: var(--sea); width: 46%; }
td { color: var(--ink); }

/* On a narrow phone the particulars table would be the one thing on the site
   you had to push sideways to read. Below 34rem each row becomes a stacked
   label and value instead, and the scroller is switched off. */
@media (max-width: 33.99rem) {
  .particulars-wrap { overflow-x: visible; }
  .particulars-wrap table { min-width: 0; }
  .particulars-wrap tbody tr {
    display: grid; gap: 0.1rem;
    padding: 0.6rem 0; border-bottom: 1px solid var(--rule);
  }
  .particulars-wrap th, .particulars-wrap td {
    display: block; width: auto; padding: 0; border-bottom: none;
  }
  .particulars-wrap th {
    font-size: 0.68rem; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--sounding);
  }
}

/* -------------------------------------------------------------------- team */

.people {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 1px; background: var(--paper);
  border: 1px solid var(--rule); margin-top: 1.6rem;
}
.person { background: var(--paper); box-shadow: 0 0 0 1px var(--rule); padding: 1.3rem 1.25rem 1.4rem; min-width: 0; }
.person .role {
  font-family: var(--data); font-size: 0.64rem;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--sounding); margin: 0 0 0.35rem;
}
.person h3 {
  font-family: var(--display); font-weight: 600;
  font-size: 1.08rem; margin: 0 0 0.5rem;
}
.person p { font-size: 0.92rem; line-height: 1.55; color: var(--sea); margin: 0 0 0.8rem; max-width: none; }

/* ----------------------------------------------------------------- contact */

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 1.75rem 2.5rem; margin-top: 1.5rem;
}
.contact-block { min-width: 0; }
.contact-block h3 {
  font-family: var(--data); font-size: 0.66rem;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--sounding); font-weight: 400; margin: 0 0 0.6rem;
}
.addr { font-style: normal; line-height: 1.65; font-size: 0.95rem; }
.copyline {
  display: flex; align-items: center; gap: 0.6rem;
  flex-wrap: wrap; margin-bottom: 0.5rem;
}
.copyline code {
  font-family: var(--data); font-size: 0.86rem;
  color: var(--ink); word-break: break-all;
}
button.copy {
  font-family: var(--data); font-size: 0.62rem;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--sea); background: transparent;
  border: 1px solid var(--rule); border-radius: 2px;
  padding: 0.22rem 0.5rem; cursor: pointer; flex: none;
}
button.copy:hover { border-color: var(--accent); color: var(--accent); }
button.copy:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ------------------------------------------------------------------ footer */

footer { background: var(--panel); }
footer .wrap {
  padding-block: 2rem 2.5rem;
  display: grid; gap: 1.5rem;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}
@media (min-width: 42rem) {
  footer .wrap { grid-template-columns: auto minmax(0, 1fr); gap: 2.5rem; }
}
footer img.flogo { width: 9rem; height: auto; }
.legal {
  font-family: var(--data); font-size: 0.72rem; line-height: 1.75;
  color: var(--sounding); display: grid; gap: 0.35rem; min-width: 0;
}
.legal strong { color: var(--sea); font-weight: 500; }

/* -------------------------------------------------------------- placeholder */

.todo {
  background: var(--flag-soft); border-bottom: 1px dashed var(--flag);
  color: var(--flag); padding: 0 0.18em; font-style: normal;
}
.todo::before { content: "▸ "; font-family: var(--data); font-size: 0.8em; }

.note {
  border-left: 2px solid var(--flag); background: var(--flag-soft);
  padding: 0.85rem 1rem; margin: 1.6rem 0 0;
  font-size: 0.88rem; line-height: 1.55; max-width: 62ch;
}
.note b {
  font-family: var(--data); font-size: 0.66rem;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--flag); display: block; margin-bottom: 0.3rem;
}

a { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* subpage additions */
.doc .wrap { max-width: 50rem; }
.doc h2 { margin-top: 2.2rem; }
.doc h2:first-of-type { margin-top: 0; }
.doc ul { max-width: 62ch; padding-left: 1.1rem; margin: 0 0 1rem; }
.doc li { margin-bottom: 0.45rem; }
.stamp {
  font-family: var(--data); font-size: 0.72rem; letter-spacing: 0.05em;
  color: var(--sounding); border-top: 1px solid var(--rule);
  padding-top: 0.9rem; margin-top: 2.2rem;
}
.back {
  font-family: var(--data); font-size: 0.7rem; letter-spacing: 0.1em;
  text-transform: uppercase; text-decoration: none; color: var(--sea);
}
.back:hover { color: var(--accent); }
.keypoints {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: 1px; background: var(--paper); border: 1px solid var(--rule); margin: 1.6rem 0 0;
}
.keypoint { background: var(--paper); box-shadow: 0 0 0 1px var(--rule); padding: 1.1rem 1.1rem 1.2rem; min-width: 0; }
.keypoint h3 { font-family: var(--display); font-weight: 600; font-size: 0.98rem; margin: 0 0 0.4rem; }
.keypoint p { font-size: 0.88rem; line-height: 1.55; color: var(--sea); margin: 0; max-width: none; }
.flag-line {
  border-left: 2px solid var(--accent); background: var(--accent-soft);
  padding: 0.9rem 1rem; margin: 1.6rem 0 0; font-size: 0.92rem;
  line-height: 1.55; max-width: 62ch;
}
