/* ============================================
   Truesail — Estilos públicos (dark mode)
   Brand Guidelines v1.0
   ============================================ */

/* CSS Variables */
:root {
  --bg: #0B1015;
  --surface: #0E1318;
  --surface2: #121820;
  --border: #1C2228;
  --border2: #2A3038;
  --text: #EDEDEF;
  --muted: #9A9A9E;
  --dim: #666669;
  --teal: #00D4AA;
  --teal-hover: #00E8BA;
  --signal: #FF6B35;
  --ocean: #1E3A5F;
  --canvas: #F5F5F7;
}

/* Reset base */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
.mono { font-family: 'Space Mono', monospace; }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--dim); }

/* ---- NAVBAR ---- */
.nav-public {
  position: fixed; top: 0; width: 100%; z-index: 100;
  background: rgba(11,16,21,.92);
  backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  padding: 0 2rem;
  transition: all .3s;
}
.nav-public .inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  height: 60px;
}
.nav-public .logo {
  display: flex; align-items: center; gap: .6rem;
  text-decoration: none; color: var(--text);
}
.nav-public .logo span { font-weight: 700; font-size: 1rem; letter-spacing: -.02em; }
.nav-public .links { display: flex; align-items: center; gap: 2rem; }
.nav-public .links a {
  font-size: .82rem; color: var(--muted);
  text-decoration: none; transition: color .2s;
}
.nav-public .links a:hover { color: var(--teal); }
.nav-public .login-nav { font-weight: 600; color: var(--text); }
.nav-public .cta-nav {
  background: var(--teal); color: #0A0A0B;
  padding: 8px 20px; border-radius: 8px;
  font-weight: 600; font-size: .82rem;
  text-decoration: none; transition: all .2s;
}
.nav-public .cta-nav:hover { background: var(--teal-hover); transform: translateY(-1px); }
.nav-public .mobile-toggle {
  display: none; background: none; border: none;
  color: var(--text); font-size: 1.5rem; cursor: pointer;
}
@media(max-width:768px) {
  .nav-public .links { display: none; }
  .nav-public .links.open {
    display: flex; flex-direction: column;
    position: absolute; top: 60px; left: 0; right: 0;
    background: var(--surface); border-bottom: 1px solid var(--border);
    padding: 1.5rem 2rem; gap: 1rem;
  }
  .nav-public .mobile-toggle { display: block; }
}

/* ---- BUTTONS ---- */
.btn-primary {
  background: #E76F51; color: #FFFFFF;
  padding: 14px 32px; border-radius: 8px;
  font-weight: 700; font-size: .95rem;
  text-decoration: none; transition: all .2s;
  display: inline-block; border: none; cursor: pointer;
}
.btn-primary:hover { background: #C95A3F; transform: translateY(-2px); box-shadow: 0 8px 32px rgba(231,111,81,.25); }
.btn-secondary {
  border: 1px solid var(--border2); color: var(--text);
  padding: 14px 32px; border-radius: 10px;
  font-weight: 600; font-size: .95rem;
  text-decoration: none; transition: all .2s;
  display: inline-block; background: transparent; cursor: pointer;
}
.btn-secondary:hover { border-color: var(--muted); background: var(--surface); }
.btn-sm { padding: 10px 24px; font-size: .88rem; }

/* ---- SECTIONS ---- */
.section {
  max-width: 1200px; margin: 0 auto; padding: 6rem 2rem;
}
.section-label {
  font-family: 'Space Mono', monospace;
  font-size: .6rem; letter-spacing: .2em;
  text-transform: uppercase; color: var(--teal);
  margin-bottom: 1rem;
}
.section h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700; letter-spacing: -.03em;
  margin-bottom: 1rem; max-width: 600px;
}
.section .desc {
  font-size: 1rem; color: var(--muted);
  max-width: 540px; line-height: 1.7; margin-bottom: 3rem;
}
.section h2 em { font-style: normal; color: var(--teal); }

/* ---- HERO ---- */
.hero {
  max-width: 1200px; margin: 0 auto;
  padding: 10rem 2rem 6rem; text-align: center;
  position: relative;
}
.hero::before {
  content: ''; position: absolute; top: 0; left: 50%;
  transform: translateX(-50%); width: 800px; height: 600px;
  background: radial-gradient(ellipse, rgba(0,212,170,.04) 0%, transparent 70%);
  pointer-events: none;
}
.hero .tag {
  display: inline-flex; align-items: center; gap: .5rem;
  font-size: .7rem; letter-spacing: .15em; text-transform: uppercase;
  color: var(--teal); padding: 8px 18px;
  border: 1px solid var(--teal); border-radius: 100px;
  margin-bottom: 2.5rem;
}
.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4.2rem);
  font-weight: 800; letter-spacing: -.04em;
  line-height: 1.05; margin-bottom: 1.5rem;
  max-width: 800px; margin-left: auto; margin-right: auto;
}
.hero h1 em { font-style: normal; color: var(--teal); }
.hero .sub {
  font-size: 1.1rem; color: var(--muted);
  max-width: 560px; margin: 0 auto 2.5rem; line-height: 1.7;
}
.hero .ctas { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
@media(max-width:600px) { .hero { padding: 8rem 1.5rem 4rem; } }

/* ---- PROBLEM SECTION ---- */
.problem { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.problem-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.problem-points { display: flex; flex-direction: column; gap: 1.5rem; }
.problem-point { display: flex; gap: 1rem; align-items: flex-start; }
.problem-point .icon {
  width: 36px; height: 36px; border-radius: 10px;
  background: var(--surface2); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; color: var(--signal); font-size: 1rem;
}
.problem-point p { font-size: .88rem; color: var(--muted); line-height: 1.6; }
.problem-point p strong { color: var(--text); }
.problem-quote {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 2.5rem; position: relative;
}
.problem-quote::before {
  content: '\201C'; position: absolute; top: 1rem; left: 1.5rem;
  font-size: 4rem; color: var(--teal); line-height: 1; font-family: Georgia, serif;
}
.problem-quote p { font-size: 1.1rem; font-weight: 500; line-height: 1.6; padding-top: 2rem; }
.problem-quote .attr { font-size: .75rem; color: var(--dim); margin-top: 1rem; }
@media(max-width:900px) { .problem-grid { grid-template-columns: 1fr; gap: 2rem; } }

/* ---- LAYERS GRID ---- */
.layers-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1.25rem; }
.layer {
  border: 1px solid var(--border); border-radius: 14px;
  padding: 2rem; background: var(--surface); transition: all .3s;
}
.layer:hover { border-color: var(--teal); transform: translateY(-4px); }
.layer .num {
  font-family: 'Space Mono', monospace; font-size: .6rem;
  color: var(--teal); letter-spacing: .1em; margin-bottom: .75rem;
}
.layer h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: .5rem; }
.layer p { font-size: .82rem; color: var(--muted); line-height: 1.6; }
@media(max-width:900px) { .layers-grid { grid-template-columns: 1fr; } }

/* ---- HOW IT WORKS (STEPS) ---- */
.how { border-top: 1px solid var(--border); }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.step { text-align: center; padding: 2rem 1rem; }
.step .snum {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--surface2); border: 2px solid var(--teal);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1.2rem;
  font-family: 'Space Mono', monospace;
  font-size: .8rem; font-weight: 700; color: var(--teal);
}
.step h3 { font-size: .95rem; font-weight: 700; margin-bottom: .4rem; }
.step p { font-size: .78rem; color: var(--muted); line-height: 1.5; }
@media(max-width:900px) { .steps { grid-template-columns: 1fr 1fr; gap: 1rem; } }
@media(max-width:600px) { .steps { grid-template-columns: 1fr; } }

/* ---- FEATURES DETAIL ---- */
.features-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1.25rem; }
.feature-card {
  border: 1px solid var(--border); border-radius: 14px;
  padding: 2rem; background: var(--surface); transition: all .3s;
}
.feature-card:hover { border-color: var(--teal); }
.feature-card .feat-icon {
  width: 40px; height: 40px; border-radius: 10px;
  background: rgba(0,212,170,.1); border: 1px solid rgba(0,212,170,.2);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem; color: var(--teal); font-size: 1.1rem;
}
.feature-card h3 { font-size: .95rem; font-weight: 700; margin-bottom: .5rem; }
.feature-card p { font-size: .82rem; color: var(--muted); line-height: 1.6; }
.feature-card ul {
  list-style: none; margin-top: .75rem; padding: 0;
  display: flex; flex-direction: column; gap: .35rem;
}
.feature-card ul li {
  font-size: .78rem; color: var(--muted); line-height: 1.5;
  padding-left: 1rem; position: relative;
}
.feature-card ul li::before {
  content: '\2713'; color: var(--teal); position: absolute;
  left: 0; font-weight: 700; font-size: .7rem;
}
@media(max-width:900px) { .features-grid { grid-template-columns: 1fr; } }

/* ---- PRICING ---- */
.pricing { border-top: 1px solid var(--border); }
.pricing-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1.5rem; margin-bottom: 2rem; }
.plan {
  border: 1px solid var(--border); border-radius: 16px;
  padding: 2.5rem; background: var(--surface);
  display: flex; flex-direction: column; transition: all .3s;
}
.plan.featured { border-color: var(--teal); position: relative; }
.plan.featured::before {
  content: 'Popular'; position: absolute; top: -12px; left: 50%;
  transform: translateX(-50%); background: var(--teal); color: #0A0A0B;
  font-size: .6rem; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; padding: 4px 14px; border-radius: 100px;
}
.plan .plan-name {
  font-size: .75rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--teal); margin-bottom: .5rem;
  font-family: 'Space Mono', monospace;
}
.plan .plan-price { font-size: 2.5rem; font-weight: 800; letter-spacing: -.03em; margin-bottom: .25rem; }
.plan .plan-price span { font-size: .9rem; font-weight: 400; color: var(--muted); }
.plan .plan-desc { font-size: .82rem; color: var(--muted); margin-bottom: 1.5rem; line-height: 1.5; }
.plan .plan-features {
  list-style: none; display: flex; flex-direction: column;
  gap: .6rem; margin-bottom: 2rem; flex: 1; padding: 0;
}
.plan .plan-features li {
  font-size: .82rem; color: var(--muted);
  display: flex; align-items: flex-start; gap: .5rem; line-height: 1.4;
}
.plan .plan-features li::before { content: '\2713'; color: var(--teal); font-weight: 700; flex-shrink: 0; }
.plan .plan-cta { text-align: center; margin-top: auto; }
.plan .plan-cta a {
  display: block; padding: 12px; border-radius: 10px;
  font-weight: 600; font-size: .88rem;
  text-decoration: none; transition: all .2s;
}
.plan .plan-cta a.primary { background: var(--teal); color: #0A0A0B; }
.plan .plan-cta a.primary:hover { background: var(--teal-hover); }
.plan .plan-cta a.outline { border: 1px solid var(--border2); color: var(--text); }
.plan .plan-cta a.outline:hover { border-color: var(--muted); }
@media(max-width:900px) { .pricing-grid { grid-template-columns: 1fr; } }

.extras { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 2rem; }
.extra {
  border: 1px solid var(--border); border-radius: 14px;
  padding: 1.5rem; background: var(--surface);
}
.extra .el {
  font-size: .6rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--teal); margin-bottom: .4rem;
  font-family: 'Space Mono', monospace;
}
.extra h3 { font-size: .95rem; font-weight: 700; margin-bottom: .3rem; }
.extra p { font-size: .82rem; color: var(--muted); line-height: 1.5; }
@media(max-width:600px) { .extras { grid-template-columns: 1fr; } }

/* ---- TOGGLE MENSAL/ANUAL ---- */
.billing-toggle {
  display: flex; align-items: center; justify-content: center;
  gap: 1rem; margin-bottom: 3rem;
}
.billing-toggle span { font-size: .88rem; color: var(--muted); }
.billing-toggle span.active { color: var(--text); font-weight: 600; }
.toggle-switch {
  width: 48px; height: 26px; border-radius: 13px;
  background: var(--border2); cursor: pointer;
  position: relative; transition: background .2s;
  border: none;
}
.toggle-switch.active { background: var(--teal); }
.toggle-switch::after {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 20px; height: 20px; border-radius: 50%;
  background: white; transition: transform .2s;
}
.toggle-switch.active::after { transform: translateX(22px); }
.save-badge {
  font-size: .7rem; background: rgba(0,212,170,.15);
  color: var(--teal); padding: 2px 8px; border-radius: 100px;
  font-weight: 600;
}

/* ---- COMPARISON TABLE ---- */
.comparison-table {
  width: 100%; border-collapse: collapse; margin-top: 3rem;
}
.comparison-table th, .comparison-table td {
  padding: .75rem 1rem; text-align: left; font-size: .82rem;
  border-bottom: 1px solid var(--border);
}
.comparison-table th { color: var(--teal); font-weight: 600; font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; }
.comparison-table td { color: var(--muted); }
.comparison-table td:first-child { color: var(--text); font-weight: 500; }
.comparison-table .check { color: var(--teal); font-weight: 700; }
.comparison-table .dash { color: var(--dim); }
.comparison-table .cat-row td {
  color: var(--teal); font-weight: 600; font-size: .75rem;
  text-transform: uppercase; letter-spacing: .05em;
  padding-top: 1.5rem; border-bottom: 1px solid var(--border2);
}

/* ---- FAQ ---- */
.faq-list { max-width: 700px; }
.faq-item {
  border-bottom: 1px solid var(--border);
  padding: 1.5rem 0;
}
.faq-q {
  display: flex; justify-content: space-between; align-items: center;
  cursor: pointer; width: 100%; background: none; border: none;
  color: var(--text); font-size: .95rem; font-weight: 600;
  text-align: left; padding: 0; font-family: 'DM Sans', sans-serif;
}
.faq-q .arrow {
  color: var(--teal); font-size: 1.2rem; transition: transform .2s;
  flex-shrink: 0; margin-left: 1rem;
}
.faq-item.open .faq-q .arrow { transform: rotate(45deg); }
.faq-a {
  max-height: 0; overflow: hidden; transition: max-height .3s ease;
}
.faq-item.open .faq-a { max-height: 300px; }
.faq-a p {
  font-size: .88rem; color: var(--muted); line-height: 1.7;
  padding-top: 1rem;
}

/* ---- CTA SECTION ---- */
.cta-section { border-top: 1px solid var(--border); text-align: center; }
.cta-section h2 { max-width: 500px; margin: 0 auto 1rem; }
.cta-section .desc { margin: 0 auto 2rem; }

/* ---- FOOTER ---- */
.footer-public {
  max-width: 1200px; margin: 0 auto; padding: 3rem 2rem;
  border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
}
.footer-public .fl { display: flex; align-items: center; gap: .6rem; }
.footer-public .fl span { font-weight: 700; font-size: .9rem; }
.footer-public .fc { display: flex; gap: 2rem; }
.footer-public .fc a { font-size: .75rem; color: var(--dim); text-decoration: none; transition: color .2s; }
.footer-public .fc a:hover { color: var(--teal); }
.footer-public .fr { font-size: .65rem; color: var(--dim); }
@media(max-width:600px) {
  .footer-public { flex-direction: column; gap: 1.5rem; text-align: center; }
  .footer-public .fc { flex-wrap: wrap; justify-content: center; }
}

/* ---- ABOUT PAGE ---- */
.about-hero {
  max-width: 800px; margin: 0 auto;
  padding: 10rem 2rem 4rem; text-align: center;
}
.about-hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800; letter-spacing: -.04em;
  line-height: 1.1; margin-bottom: 1.5rem;
}
.about-hero h1 em { font-style: normal; color: var(--teal); }
.about-hero p { font-size: 1.1rem; color: var(--muted); line-height: 1.7; max-width: 600px; margin: 0 auto; }

.principles-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.principle {
  border: 1px solid var(--border); border-radius: 14px;
  padding: 2rem; background: var(--surface);
}
.principle h3 { font-size: .95rem; font-weight: 700; margin-bottom: .5rem; color: var(--teal); }
.principle p { font-size: .82rem; color: var(--muted); line-height: 1.6; }
@media(max-width:600px) { .principles-grid { grid-template-columns: 1fr; } }

/* ---- SIGNUP PAGE ---- */
.signup-container {
  max-width: 460px; margin: 0 auto;
  padding: 8rem 2rem 4rem;
}
.signup-container h1 {
  font-size: 1.8rem; font-weight: 800;
  letter-spacing: -.03em; margin-bottom: .5rem; text-align: center;
}
.signup-container .sub {
  font-size: .95rem; color: var(--muted);
  text-align: center; margin-bottom: 2rem;
}
.signup-form { display: flex; flex-direction: column; gap: 1.25rem; }
.form-group label {
  display: block; font-size: .82rem; font-weight: 500;
  color: var(--muted); margin-bottom: .4rem;
}
.form-group input {
  width: 100%; padding: 12px 14px; border-radius: 10px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text); font-size: .88rem; font-family: 'DM Sans', sans-serif;
  transition: border-color .2s;
}
.form-group input:focus { outline: none; border-color: var(--teal); }
.form-group input::placeholder { color: var(--dim); }
.form-error {
  font-size: .78rem; color: var(--signal); margin-top: .3rem;
  display: none;
}
.signup-error {
  background: rgba(255,107,53,.1); border: 1px solid rgba(255,107,53,.3);
  border-radius: 10px; padding: .75rem 1rem;
  font-size: .82rem; color: var(--signal);
  display: none;
}
.signup-note {
  font-size: .75rem; color: var(--dim); text-align: center;
  margin-top: 1rem; line-height: 1.5;
}
.signup-note a { color: var(--teal); text-decoration: none; }
.signup-note a:hover { text-decoration: underline; }

/* ---- LOGIN PAGE (dark mode) ---- */
.login-container {
  max-width: 400px; margin: 0 auto;
  padding: 10rem 2rem 4rem; text-align: center;
}
.login-container .logo-area { margin-bottom: 2rem; }
.login-container h1 {
  font-size: 1.5rem; font-weight: 700;
  letter-spacing: -.02em; margin-bottom: .25rem;
}
.login-container .login-sub {
  font-size: .82rem; color: var(--muted);
}
.login-form {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; padding: 2rem;
  margin-top: 1.5rem;
  display: flex; flex-direction: column; gap: 1rem;
  text-align: left;
}
.login-form label {
  display: block; font-size: .82rem; font-weight: 500;
  color: var(--muted); margin-bottom: .4rem;
}
.login-form input {
  width: 100%; padding: 10px 14px; border-radius: 10px;
  border: 1px solid var(--border); background: var(--surface2);
  color: var(--text); font-size: .88rem; font-family: 'DM Sans', sans-serif;
}
.login-form input:focus { outline: none; border-color: #E76F51; box-shadow: 0 0 0 2px rgba(231,111,81,.15); }
.login-form input::placeholder { color: var(--dim); }
.login-error {
  background: rgba(255,107,53,.1); border: 1px solid rgba(255,107,53,.3);
  border-radius: 10px; padding: .75rem 1rem;
  font-size: .82rem; color: var(--signal);
  display: none;
}
.login-footer {
  font-size: .75rem; color: var(--dim);
  margin-top: 2rem;
}

/* ---- ANIMATIONS ---- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
.hero .tag, .hero h1, .hero .sub, .hero .ctas { animation: fadeUp .6s ease both; }
.hero h1 { animation-delay: .1s; }
.hero .sub { animation-delay: .2s; }
.hero .ctas { animation-delay: .3s; }
