/* =========================================================
   File: public_html/tools/assets/tools.css
   Purpose: Shared styling for Forgalis Trading Tools
   ========================================================= */


/* =========================================================
   1. Base
   ========================================================= */

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: #0f172a;
  background: #f3f6fb;
  line-height: 1.55;
}

a {
  color: #0878ff;
}


/* =========================================================
   2. Header
   ========================================================= */

.site-header {
  width: 100%;
  padding: 22px 12%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #061328;
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
}

.brand {
  display: inline-flex;
  align-items: center;
  color: #ffffff;
  text-decoration: none;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.brand-logo {
  height: 38px;
  width: auto;
  display: block;
}

/* Fallback if logo image is not used */
.brand-mark {
  width: 36px;
  height: 28px;
  margin-right: 10px;
  position: relative;
  display: inline-block;
}

.brand-mark::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0;
  width: 0;
  height: 0;
  border-left: 16px solid transparent;
  border-right: 16px solid transparent;
  border-top: 28px solid #0878ff;
  transform: rotate(180deg);
}

.brand span:last-child {
  font-size: 20px;
}

.nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.nav a {
  color: #ffffff;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
  margin-left: 28px;
  opacity: 0.90;
  text-transform: uppercase;
}

.nav a:hover {
  color: #4da3ff;
  opacity: 1;
}


/* =========================================================
   3. Page Layout
   ========================================================= */

.page {
  max-width: 1080px;
  margin: 0 auto;
  padding: 42px 20px 60px;
}

.section {
  margin-top: 34px;
}


/* =========================================================
   4. Hero
   ========================================================= */

.hero {
  margin-bottom: 34px;
  padding: 58px 44px;
  background: #0b1d42;
  background-image: linear-gradient(135deg, #12367a, #07142f 68%, #020817);
  border: 1px solid rgba(8, 120, 255, 0.22);
  border-radius: 28px;
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.18);
}

.hero-inner {
  max-width: 820px;
}

.eyebrow {
  display: inline-block;
  margin: 0 0 14px;
  color: #4da3ff;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.10em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 9px;
  border-radius: 999px;
  background: #4da3ff;
}

h1 {
  margin: 0 0 18px;
  max-width: 850px;
  color: #ffffff;
  font-size: 50px;
  line-height: 1.04;
  letter-spacing: -0.04em;
}

h2 {
  margin: 0 0 12px;
  color: #07142f;
  font-size: 26px;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

h3 {
  margin: 0 0 8px;
  color: #07142f;
  font-size: 18px;
}

p {
  margin: 0 0 14px;
}

.lead {
  max-width: 780px;
  color: #d7e5ff;
  font-size: 18px;
}

.small {
  color: #5b6472;
  font-size: 14px;
}


/* =========================================================
   5. Cards
   ========================================================= */

.tool-grid {
  display: flex;
  flex-wrap: wrap;
  margin: 30px -9px;
}

.tool-card,
.calculator,
.info-box,
.cta {
  background: #ffffff;
  border: 1px solid #dfe5ee;
  border-radius: 18px;
  padding: 26px;
  box-shadow: 0 14px 40px rgba(15, 23, 42, 0.08);
}

.tool-grid .tool-card {
  flex: 1 1 260px;
  min-width: 260px;
  margin: 9px;
}

.tool-card {
  display: block;
  color: inherit;
  text-decoration: none;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.tool-card:hover {
  transform: translateY(-2px);
  border-color: #0878ff;
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.13);
}

.tool-card p {
  color: #4b5563;
}

.info-box {
  box-shadow: none;
  background: #f9fbff;
}

.cta {
  border-left: 4px solid #0878ff;
  background: #ffffff;
}


/* =========================================================
   6. Calculator Forms
   ========================================================= */

.form-grid {
  display: flex;
  flex-wrap: wrap;
  margin: -8px;
}

.form-grid > div {
  flex: 1 1 165px;
  min-width: 165px;
  margin: 8px;
}

label {
  display: block;
  margin-bottom: 7px;
  color: #263244;
  font-size: 14px;
  font-weight: 800;
}

input,
select {
  width: 100%;
  min-height: 46px;
  padding: 11px 12px;
  color: #111827;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  font-size: 16px;
  outline: none;
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

input:focus,
select:focus {
  border-color: #0878ff;
  box-shadow: 0 0 0 4px rgba(8, 120, 255, 0.14);
}

.result {
  margin-top: 22px;
  padding: 20px;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  background: #eaf3ff;
  color: #172554;
}

.result strong {
  display: block;
  margin: 4px 0 12px;
  color: #07142f;
  font-size: 30px;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.result strong:last-child {
  margin-bottom: 0;
}


/* =========================================================
   7. Buttons and Utility Links
   ========================================================= */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  margin-top: 10px;
  padding: 12px 18px;
  border-radius: 12px;
  background: #0878ff;
  color: #ffffff;
  text-decoration: none;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(8, 120, 255, 0.28);
  transition: background 140ms ease, transform 140ms ease;
}

.button:hover {
  background: #0065dc;
  transform: translateY(-1px);
}

.secondary-link {
  display: inline-block;
  margin-top: 12px;
  color: #5b6472;
  font-weight: 700;
  text-decoration: none;
}

.secondary-link:hover {
  color: #0878ff;
}


/* =========================================================
   8. Textarea for Embed Code
   ========================================================= */

.embed-code {
  width: 100%;
  min-height: 150px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  color: #0f172a;
  font-size: 14px;
  font-family: Consolas, Monaco, monospace;
}


/* =========================================================
   9. Footer
   ========================================================= */

.site-footer {
  max-width: 1080px;
  margin: 20px auto 0;
  padding: 26px 20px 36px;
  border-top: 1px solid #dfe5ee;
  color: #5b6472;
  font-size: 14px;
}

.site-footer a {
  color: #5b6472;
  text-decoration: none;
  margin-right: 16px;
}

.site-footer a:hover {
  color: #0878ff;
}


/* =========================================================
   10. Embed Pages
   ========================================================= */

.embed-page {
  background: #ffffff;
}

.embed-page .page {
  max-width: none;
  width: 100%;
  padding: 14px;
}

.embed-page .calculator {
  box-shadow: none;
  border-radius: 14px;
  border-top: 3px solid #0878ff;
}

.embed-page h1 {
  color: #07142f;
  font-size: 24px;
  letter-spacing: -0.02em;
}

.powered-by {
  margin-top: 18px;
  color: #5b6472;
  font-size: 13px;
}


/* =========================================================
   11. Responsive
   ========================================================= */

@media (max-width: 820px) {
  .site-header {
    padding: 18px 20px;
    align-items: flex-start;
    flex-direction: column;
  }

  .brand {
    max-width: 180px;
    overflow: hidden;
  }

  .brand-logo {
    width: 165px;
    max-width: 165px;
    height: auto;
    display: block;
  }

  .nav {
    margin-top: 12px;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .nav a {
    margin-left: 0;
    margin-right: 18px;
    margin-top: 8px;
    font-size: 12px;
  }

  .page {
    padding: 26px 14px 46px;
  }

  .hero {
    padding: 42px 24px;
    border-radius: 0 0 22px 22px;
  }

  h1 {
    font-size: 36px;
  }

  h2 {
    font-size: 23px;
  }

  .tool-card,
  .calculator,
  .info-box,
  .cta {
    padding: 20px;
    border-radius: 15px;
  }
}