/* ==========================================================================
   PTS-Tech / Peruvian Trust Systems Inc.
   Power Transducers and Meters — Modern site stylesheet
   ========================================================================== */

:root {
  --color-primary: #0d3b66;
  --color-primary-dark: #092a4a;
  --color-accent: #1f8a70;
  --color-accent-dark: #166b57;
  --color-gold: #e8a33d;
  --color-bg: #f4f6f9;
  --color-surface: #ffffff;
  --color-text: #2c3e50;
  --color-text-light: #5d6d7e;
  --color-border: #e2e8f0;
  --color-danger: #c0392b;
  --shadow-sm: 0 1px 3px rgba(13, 59, 102, 0.08);
  --shadow-md: 0 4px 14px rgba(13, 59, 102, 0.12);
  --shadow-lg: 0 10px 30px rgba(13, 59, 102, 0.16);
  --radius: 10px;
  --radius-sm: 6px;
  --container: 1200px;
  --font-sans: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: Georgia, "Times New Roman", serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--color-text);
  background: var(--color-bg);
}

img {
  max-width: 100%;
  height: auto;
  border: 0;
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--color-accent-dark);
  text-decoration: underline;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--color-primary);
  line-height: 1.25;
  margin: 0 0 0.6em;
  font-weight: 700;
}

h1 { font-size: 2.1rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }

p { margin: 0 0 1em; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  background: var(--color-primary);
  color: #fff;
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 12px 20px;
  max-width: var(--container);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
}

.brand img {
  height: 44px;
  width: auto;
}

.brand-name {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.15;
  color: #fff;
}

.brand-name small {
  display: block;
  font-size: 0.72rem;
  font-weight: 400;
  color: #bcd0e4;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.main-nav a {
  display: block;
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  color: #dbe7f3;
  font-weight: 500;
  font-size: 0.95rem;
}

.main-nav a:hover,
.main-nav a.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  text-decoration: none;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: #bcd0e4;
}

.lang-switch a {
  color: #fff;
  font-weight: 600;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #fff;
  font-size: 1.4rem;
  line-height: 1;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 60%, #0a2f52 100%);
  color: #fff;
  padding: 56px 0 60px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
}

.hero h1 {
  color: #fff;
  font-size: 2.4rem;
  margin-bottom: 0.4em;
}

.hero p.lead {
  font-size: 1.15rem;
  color: #dbe7f3;
  margin-bottom: 1.4em;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}

.hero-badges span {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 6px 14px;
  border-radius: 30px;
  font-size: 0.85rem;
  color: #eaf2fb;
}

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

.hero-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  max-height: 300px;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-block;
  padding: 11px 22px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-primary {
  background: var(--color-accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--color-accent-dark);
  color: #fff;
  text-decoration: none;
}

.btn-outline {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.6);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  text-decoration: none;
}

.btn-gold {
  background: var(--color-gold);
  color: #fff;
}

.btn-gold:hover {
  background: #d18f2a;
  color: #fff;
  text-decoration: none;
}

/* ==========================================================================
   Sections & cards
   ========================================================================== */
.section {
  padding: 48px 0;
}

.section-alt {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.section-head {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 36px;
}

.section-head h2 {
  margin-bottom: 0.3em;
}

.section-head p {
  color: var(--color-text-light);
  font-size: 1.05rem;
}

.grid {
  display: grid;
  gap: 24px;
}

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

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

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

.card h3 {
  margin-bottom: 0.4em;
}

.card p {
  color: var(--color-text-light);
  font-size: 0.95rem;
}

.card-icon {
  font-size: 2rem;
  margin-bottom: 10px;
}

.card-link {
  font-weight: 600;
  font-size: 0.9rem;
}

/* ==========================================================================
   Product cards
   ========================================================================== */
.product-card {
  display: flex;
  flex-direction: column;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

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

.product-card .thumb {
  background: #eef2f7;
  text-align: center;
  padding: 18px;
  min-height: 150px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-card .thumb img {
  max-height: 120px;
  object-fit: contain;
}

.product-card .body {
  padding: 16px 18px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.3em;
}

.product-card .model {
  color: var(--color-accent);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.03em;
  margin-bottom: 0.4em;
}

.product-card p {
  font-size: 0.9rem;
  color: var(--color-text-light);
  flex: 1;
}

/* ==========================================================================
   Feature list / checkmarks
   ========================================================================== */
.feature-list {
  list-style: none;
  margin: 0 0 1em;
  padding: 0;
}

.feature-list li {
  padding: 6px 0 6px 30px;
  position: relative;
  color: var(--color-text);
}

.feature-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 6px;
  color: var(--color-accent);
  font-weight: 700;
}

/* ==========================================================================
   Call to action band
   ========================================================================== */
.cta-band {
  background: var(--color-accent);
  color: #fff;
  padding: 40px 0;
  text-align: center;
}

.cta-band h2 {
  color: #fff;
  margin-bottom: 0.3em;
}

.cta-band p {
  color: #e6f5f0;
  max-width: 640px;
  margin: 0 auto 1.2em;
}

/* ==========================================================================
   Tables (product catalog)
   ========================================================================== */
.table-wrap {
  overflow-x: auto;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

table.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

table.data th,
table.data td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--color-border);
  text-align: left;
  vertical-align: top;
}

table.data thead th {
  background: var(--color-primary);
  color: #fff;
  font-weight: 600;
  position: sticky;
  top: 0;
}

table.data tbody tr:nth-child(even) {
  background: #f8fafc;
}

table.data tbody tr:hover {
  background: #eef4fb;
}

/* ==========================================================================
   Breadcrumb
   ========================================================================== */
.breadcrumb {
  font-size: 0.85rem;
  color: var(--color-text-light);
  margin: 18px 0 0;
  padding: 0 20px;
  max-width: var(--container);
  margin-left: auto;
  margin-right: auto;
}

.breadcrumb ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.breadcrumb li + li::before {
  content: "›";
  margin-right: 6px;
  color: #aab7c4;
}

/* ==========================================================================
   Page hero (inner pages)
   ========================================================================== */
.page-hero {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: #fff;
  padding: 40px 0;
}

.page-hero h1 {
  color: #fff;
  margin-bottom: 0.2em;
}

.page-hero p {
  color: #dbe7f3;
  max-width: 760px;
  margin: 0;
}

/* ==========================================================================
   Content prose
   ========================================================================== */
.prose {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-sm);
}

.prose h2 {
  margin-top: 1.4em;
  border-bottom: 2px solid var(--color-border);
  padding-bottom: 0.3em;
}

.prose h2:first-child {
  margin-top: 0;
}

.prose ul,
.prose ol {
  padding-left: 1.4em;
  margin-bottom: 1em;
}

.prose li {
  margin-bottom: 0.4em;
}

/* ==========================================================================
   FAQ
   ========================================================================== */
.faq-item {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
}

.faq-item h3 {
  margin-bottom: 0.3em;
  font-size: 1.1rem;
}

.faq-item p {
  margin: 0;
  color: var(--color-text-light);
}

/* ==========================================================================
   Bench Notes strip (home + resources)
   ========================================================================== */
.bench-note {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-left: 4px solid var(--color-gold);
  border-radius: var(--radius);
  padding: 22px 26px;
  max-width: 720px;
  box-shadow: var(--shadow-sm);
}

.bench-note-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #b47b1e;
  margin-bottom: 8px;
}

.bench-note p {
  color: var(--color-text-light);
  font-size: 0.95rem;
  margin-bottom: 10px;
}

/* ==========================================================================
   Contact
   ========================================================================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.contact-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.contact-card h3 {
  margin-bottom: 0.4em;
}

.contact-card address {
  font-style: normal;
  color: var(--color-text-light);
  line-height: 1.7;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--color-primary-dark);
  color: #c9d8e8;
  padding: 44px 0 0;
  margin-top: 48px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  padding-bottom: 28px;
}

.site-footer h4 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 0.8em;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-footer li {
  margin-bottom: 0.5em;
}

.site-footer a {
  color: #c9d8e8;
}

.site-footer a:hover {
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 18px 0;
  font-size: 0.85rem;
  color: #9fb3c8;
}

.footer-bottom .container {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

/* ==========================================================================
   Utility
   ========================================================================== */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mt-2 { margin-top: 20px; }
.mb-2 { margin-bottom: 20px; }
.muted { color: var(--color-text-light); }
.small { font-size: 0.85rem; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-accent);
  color: #fff;
  padding: 8px 16px;
  z-index: 200;
}

.skip-link:focus {
  left: 0;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 992px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-media { order: -1; }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .main-nav {
    display: none;
    width: 100%;
    order: 3;
  }
  .main-nav.open { display: block; }
  .main-nav ul {
    flex-direction: column;
    gap: 0;
  }
  .main-nav a {
    padding: 12px 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }
  .header-inner { flex-wrap: wrap; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  h1 { font-size: 1.7rem; }
  .hero h1 { font-size: 1.9rem; }
  .prose { padding: 20px; }
}
