/* ==========================================================================
   BTECHNO · SYNERGIA v1.0
   UI/UX GLOBAL ÚNICO · Editorial Vanguard Sobrio
   Login + aplicación completa.
   ========================================================================== */

:root{
  --paper:#f4f2ed;
  --ink:#101010;
  --soft:#d9d6cf;
  --muted:#77746f;
  --accent:#8c8983;
  --white:#ffffff;
  --danger:#a84942;
  --charcoal:#161616;
  --graphite:#2b2b2b;
  --stone:#c9c5bd;
  --line:#d7d2ca;
  --grid:rgba(16,16,16,.055);
}

*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family:Arial,Helvetica,sans-serif;
  background:
    linear-gradient(var(--grid) 1px,transparent 1px),
    linear-gradient(90deg,var(--grid) 1px,transparent 1px),
    var(--paper);
  background-size:42px 42px;
  color:var(--ink);
  font-size:15px
}
button,input,select,textarea{font:inherit}
button{cursor:pointer}
a{color:inherit}
.hidden{display:none!important}
::selection{background:#2a2a2a;color:#fff}

.sr-only{
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  padding:0!important;
  margin:-1px!important;
  overflow:hidden!important;
  clip:rect(0,0,0,0)!important;
  white-space:nowrap!important;
  border:0!important
}

/* ==========================================================================
   LOGIN
   ========================================================================== */

.login{
  min-height:100vh;
  display:grid;
  grid-template-columns:1.12fr .88fr;
  border-top:14px solid var(--ink);
  background:var(--paper)
}

.login-editorial{
  padding:26px 38px 38px;
  display:grid;
  grid-template-rows:auto 1fr auto;
  border-right:1px solid #2b2b2b;
  background:
    linear-gradient(rgba(255,255,255,.018) 1px,transparent 1px),
    linear-gradient(90deg,rgba(255,255,255,.018) 1px,transparent 1px),
    radial-gradient(circle at 78% 52%,rgba(255,255,255,.07),transparent 38%),
    #0b0b0b;
  background-size:72px 72px,72px 72px,auto,auto;
  color:#f3f1ec
}

.masthead{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:24px;
  text-transform:uppercase;
  font-size:11px;
  font-weight:800;
  letter-spacing:.08em
}

.wordmark{
  font-size:clamp(24px,3vw,46px);
  line-height:.92;
  letter-spacing:-.07em;
  font-weight:900
}

.hero{align-self:center;max-width:1050px;padding:8vh 0}
.hero .code{font-size:11px;text-transform:uppercase;letter-spacing:.18em;margin-bottom:18px}
.hero h1{
  font-size:clamp(58px,9vw,138px);
  line-height:.78;
  letter-spacing:-.085em;
  margin:0;
  text-transform:uppercase;
  font-weight:900
}
.hero h1 em{font-style:normal;display:inline-block;color:#8f8f8f}
.hero p{
  max-width:680px;
  font-size:clamp(17px,1.7vw,26px);
  line-height:1.15;
  margin:42px 0 0;
  letter-spacing:-.025em
}

.login-foot{
  display:grid;
  grid-template-columns:1fr 1fr 1fr;
  gap:16px;
  border-top:1px solid #bdb9b2;
  padding-top:14px;
  font-size:11px;
  text-transform:uppercase;
  letter-spacing:.07em
}

.login-form-wrap{
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  padding:28px 40px 34px;
  background:
    linear-gradient(var(--grid) 1px,transparent 1px),
    linear-gradient(90deg,var(--grid) 1px,transparent 1px),
    var(--paper);
  background-size:38px 38px;
  color:var(--ink)
}

.login-form-wrap .top-note{
  display:flex;
  justify-content:space-between;
  font-size:11px;
  text-transform:uppercase;
  letter-spacing:.08em
}

.login-card{margin:auto 0}
.login-card .num{font-size:12px;opacity:.62;margin-bottom:16px}
.login-card h2{
  font-size:clamp(34px,4vw,68px);
  line-height:.9;
  letter-spacing:-.06em;
  margin:0 0 28px;
  text-transform:uppercase
}

.field{margin:16px 0}
.field label{
  display:block;
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.12em;
  margin-bottom:8px;
  font-weight:700
}

.input{
  width:100%;
  border:0;
  border-bottom:1px solid currentColor;
  background:transparent;
  color:inherit;
  border-radius:0;
  padding:13px 0;
  outline:none
}
.input:focus{border-bottom:2px solid var(--ink)}

.login-btn{
  margin-top:28px;
  width:100%;
  border:1px solid var(--ink);
  background:var(--ink);
  color:#fff;
  padding:18px 16px;
  font-weight:900;
  text-transform:uppercase;
  display:flex;
  justify-content:space-between;
  letter-spacing:.08em
}

.login-security-note{
  margin:14px 0 0;
  color:var(--muted);
  font-size:9px;
  line-height:1.45;
  text-transform:uppercase;
  letter-spacing:.06em
}

.login-message{
  border:1px solid var(--ink);
  padding:10px 12px;
  margin:0 0 18px;
  display:flex;
  gap:10px;
  font-size:10px;
  line-height:1.4;
  text-transform:uppercase;
  letter-spacing:.05em
}
.login-message--error{border-color:var(--danger);color:var(--danger)}
.login-message__mark{font-weight:900}
.login-form-wrap footer{
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.06em;
  opacity:.7
}

/* ==========================================================================
   APP / SIDEBAR / TOPBAR
   ========================================================================== */

.synergia-app{min-height:100vh}
.nav-toggle{position:fixed;left:-9999px}

.app{
  min-height:100vh;
  display:grid;
  grid-template-columns:216px minmax(0,1fr)
}

.sidebar{
  background:var(--ink);
  color:var(--paper);
  min-height:100vh;
  position:sticky;
  top:0;
  height:100vh;
  padding:18px 14px;
  display:flex;
  flex-direction:column;
  border-right:1px solid #2d2d2d;
  z-index:40
}

.side-brand{
  font-size:29px;
  line-height:.84;
  letter-spacing:-.07em;
  font-weight:900;
  text-transform:uppercase;
  padding:8px 8px 28px
}

.side-code{
  font-size:9px;
  letter-spacing:.15em;
  text-transform:uppercase;
  opacity:.5;
  padding:0 8px 10px
}

.nav{display:grid}

.nav-link{
  border:0;
  border-top:1px solid rgba(255,255,255,.18);
  background:transparent;
  color:inherit;
  text-decoration:none;
  text-align:left;
  padding:12px 8px;
  display:flex;
  justify-content:space-between;
  text-transform:uppercase;
  font-size:11px;
  letter-spacing:.06em;
  min-height:41px;
  align-items:center
}

.nav-link:hover,.nav-link.active{
  background:#f2f0eb;
  color:#111
}

.nav-link--pending{
  opacity:.78;
  cursor:default
}
.nav-link--pending:hover{
  background:transparent;
  color:inherit
}

.side-user{
  margin-top:auto;
  border-top:1px solid rgba(255,255,255,.22);
  padding:14px 8px 0;
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.08em;
  line-height:1.6;
  overflow-wrap:anywhere
}
.side-user strong{font-size:11px;color:#fff}

.sidebar-overlay{display:none}

.main{min-width:0}

.topbar{
  height:66px;
  border-bottom:1px solid #bdb9b2;
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:0 24px;
  position:sticky;
  top:0;
  background:rgba(244,242,237,.94);
  backdrop-filter:blur(16px);
  z-index:30
}

.topbar-left{
  display:flex;
  align-items:center;
  gap:10px;
  min-width:0
}

.route{
  display:flex;
  align-items:center;
  gap:9px;
  font-size:11px;
  text-transform:uppercase;
  letter-spacing:.12em;
  font-weight:800;
  white-space:nowrap
}

.access-badge{
  display:inline-flex;
  align-items:center;
  gap:7px;
  border:1px solid currentColor;
  padding:5px 8px;
  font-size:9px;
  text-transform:uppercase;
  letter-spacing:.08em;
  font-weight:700
}
.access-badge:before{
  content:"";
  width:6px;
  height:6px;
  border-radius:50%;
  background:currentColor;
  opacity:.65
}

.top-actions{
  display:flex;
  align-items:center;
  gap:8px
}

.icon{
  width:38px;
  height:38px;
  border:1px solid var(--ink);
  background:transparent;
  color:var(--ink);
  display:inline-grid;
  place-items:center;
  padding:0
}
.icon:disabled{opacity:.55;cursor:not-allowed}

.cta{
  border:1px solid var(--ink);
  background:var(--ink);
  color:var(--paper);
  padding:11px 15px;
  text-transform:uppercase;
  font-size:10px;
  font-weight:900;
  letter-spacing:.08em
}
.cta.acid{background:#ece9e3;color:#111}
.cta:disabled{opacity:.62;cursor:not-allowed}

.logout-form{margin:0}
.icon--logout{font-weight:900}
.mobile{display:none}

/* ==========================================================================
   CONTENT / DASHBOARD
   ========================================================================== */

.content{padding:24px}

.app-message{
  margin:0 0 18px;
  padding:12px 14px;
  border:1px solid var(--ink);
  background:rgba(244,242,237,.96);
  font-size:11px;
  line-height:1.4;
  text-transform:uppercase;
  letter-spacing:.055em
}
.app-message--error{border-color:var(--danger);color:var(--danger)}

.page{display:block}

.page-header{
  display:grid;
  grid-template-columns:1.25fr .75fr;
  gap:28px;
  border-bottom:1px solid #bdb9b2;
  padding:16px 0 28px;
  margin-bottom:22px
}

.page-header .kicker{
  font-size:10px;
  letter-spacing:.16em;
  text-transform:uppercase;
  margin-bottom:18px
}

.page-header h1{
  font-size:clamp(48px,7vw,108px);
  line-height:.78;
  letter-spacing:-.08em;
  text-transform:uppercase;
  margin:0;
  max-width:1000px
}

.page-header .intro{
  align-self:end;
  font-size:16px;
  line-height:1.35;
  max-width:470px
}

.page-header .intro b{
  display:block;
  font-size:11px;
  text-transform:uppercase;
  letter-spacing:.12em;
  margin-bottom:12px
}

.metric-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  border-top:1px solid #bdb9b2;
  border-left:1px solid #bdb9b2;
  margin-bottom:28px
}

.metric-grid--three{grid-template-columns:repeat(3,minmax(0,1fr))}

.metric{
  min-height:190px;
  border-right:1px solid #bdb9b2;
  border-bottom:1px solid #bdb9b2;
  padding:16px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  min-width:0
}

.metric small{
  text-transform:uppercase;
  font-size:10px;
  letter-spacing:.11em
}

.metric strong{
  font-size:clamp(42px,5vw,76px);
  letter-spacing:-.07em;
  line-height:.9;
  overflow-wrap:anywhere
}

.metric.acid{background:#dedad2}

.metric .delta{
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.07em
}

.editorial-grid{
  display:grid;
  grid-template-columns:1.35fr .65fr;
  gap:28px
}

.dashboard-panel{min-width:0}

.section-title{
  display:flex;
  justify-content:space-between;
  gap:18px;
  border-top:1px solid #bdb9b2;
  padding-top:10px;
  margin-bottom:14px
}

.section-title h3{
  margin:0;
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:.1em
}

.section-title span{
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.08em;
  color:var(--muted);
  text-align:right
}

.chart{
  height:300px;
  display:flex;
  align-items:flex-end;
  gap:3px;
  border-bottom:1px solid #bdb9b2;
  padding-top:30px
}

.bar{
  flex:1;
  background:var(--ink);
  position:relative;
  min-width:20px;
  min-height:5px
}

.bar:nth-child(4),.bar:nth-child(6){
  background:#8f8d88;
  border:1px solid var(--ink)
}

.bar span{
  position:absolute;
  left:6px;
  bottom:6px;
  color:var(--paper);
  font-size:9px;
  text-transform:uppercase;
  writing-mode:vertical-rl;
  transform:rotate(180deg)
}

.bar:nth-child(4) span,.bar:nth-child(6) span{color:#fff}

.bar-value{
  position:absolute;
  top:-22px;
  right:5px;
  font-size:10px;
  letter-spacing:.04em
}

.chart-caption{
  display:flex;
  justify-content:space-between;
  gap:16px;
  padding-top:9px;
  font-size:9px;
  text-transform:uppercase;
  letter-spacing:.08em;
  color:var(--muted)
}
.chart-caption strong{color:var(--ink)}

.feed{border-top:1px solid #bdb9b2}

.feed article{
  display:grid;
  grid-template-columns:42px 1fr auto;
  gap:12px;
  border-bottom:1px solid #bdb9b2;
  padding:13px 0;
  align-items:start
}

.feed .n{font-size:10px;letter-spacing:.1em}

.feed h4{
  margin:0 0 4px;
  font-size:13px;
  text-transform:uppercase
}

.feed p{
  margin:0;
  color:var(--muted);
  font-size:12px;
  line-height:1.35
}

.feed time{
  font-size:9px;
  text-transform:uppercase;
  white-space:nowrap
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media(max-width:1050px){
  .metric-grid,.metric-grid--three{grid-template-columns:1fr 1fr}
  .editorial-grid{grid-template-columns:1fr}
}

@media(max-width:820px){
  .login{grid-template-columns:1fr}
  .login-editorial{
    min-height:55vh;
    border-right:0;
    border-bottom:1px solid #bdb9b2
  }
  .login-form-wrap{min-height:45vh}

  .app{grid-template-columns:1fr}

  .sidebar{
    position:fixed;
    left:-230px;
    width:216px;
    transition:left .22s ease
  }

  .nav-toggle:checked + .app .sidebar{left:0}

  .sidebar-overlay{
    position:fixed;
    inset:0;
    background:rgba(0,0,0,.45);
    z-index:35
  }

  .nav-toggle:checked + .app .sidebar-overlay{display:block}

  .mobile{display:inline-grid}
  .page-header{grid-template-columns:1fr}
  .topbar{padding:0 12px}
  .top-actions .cta{display:none}
}

@media(max-width:560px){
  .login-editorial{padding:18px}
  .hero{padding:5vh 0}
  .hero h1{font-size:56px}
  .login-foot{grid-template-columns:1fr}
  .login-form-wrap{padding:22px 20px}

  .content{padding:14px}
  .page-header h1{font-size:52px}
  .metric-grid,.metric-grid--three{grid-template-columns:1fr 1fr}
  .metric{min-height:145px;padding:12px}
  .metric strong{font-size:36px}
  .route{font-size:9px;letter-spacing:.08em}
  .access-badge{display:none}
  .feed article{grid-template-columns:32px 1fr}
  .feed time{grid-column:2}
}

@media(max-width:420px){
  .metric-grid,.metric-grid--three{grid-template-columns:1fr}
}

@media(prefers-reduced-motion:reduce){
  *{scroll-behavior:auto!important;transition:none!important}
}

/* ==========================================================================
   DIRECTORIO · SynErgia v1.2
   UI/UX alineado al Mockup Editorial Vanguard Sobrio
   ========================================================================== */

.directory-toolbar{
  display:grid;
  grid-template-columns:minmax(340px,1fr) 230px auto;
  gap:10px;
  align-items:stretch;
  margin-bottom:16px
}

.directory-search-wrap{
  position:relative;
  min-width:0
}

.directory-control{
  width:100%;
  height:44px;
  border:1px solid var(--ink);
  border-radius:0;
  background:transparent;
  color:var(--ink);
  padding:0 13px;
  outline:none;
  font-size:12px
}

.directory-search{
  padding-right:48px;
  text-transform:uppercase
}

.directory-control::placeholder{
  color:#8a8781;
  opacity:1
}

.directory-control:focus{
  box-shadow:inset 0 -2px 0 var(--ink)
}

.directory-search-button{
  position:absolute;
  top:0;
  right:0;
  width:44px;
  height:44px;
  border:0;
  border-left:1px solid var(--ink);
  background:var(--ink);
  color:var(--paper);
  font-weight:900;
  font-size:16px
}

.directory-new{
  display:grid;
  place-items:center;
  min-height:44px;
  text-decoration:none;
  white-space:nowrap
}

.directory-filter-state{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  border-top:1px solid #bdb9b2;
  padding:8px 0 10px;
  margin-top:-4px;
  font-size:9px;
  text-transform:uppercase;
  letter-spacing:.09em;
  color:var(--muted)
}

.directory-filter-state a{
  color:var(--ink);
  text-decoration:none;
  border-bottom:1px solid var(--ink)
}

.table-wrap{
  overflow:auto;
  border-top:1px solid #bdb9b2
}

.directory-table{
  width:100%;
  border-collapse:collapse;
  table-layout:fixed;
  min-width:1080px
}

.directory-table thead{
  background:rgba(244,242,237,.92)
}

.directory-table th{
  padding:12px 10px;
  border-bottom:1px solid #bdb9b2;
  text-align:left;
  vertical-align:bottom;
  font-size:9px;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:.12em;
  color:var(--muted)
}

.directory-table td{
  padding:14px 10px;
  border-bottom:1px solid #bdb9b2;
  text-align:left;
  vertical-align:top;
  font-size:12px;
  line-height:1.35
}

.directory-table tbody tr{
  background:rgba(244,242,237,.42);
  transition:background .14s ease
}

.directory-table tbody tr:hover{
  background:#ebe8e1
}

.directory-table th:nth-child(1),
.directory-table td:nth-child(1){width:46px}

.directory-table th:nth-child(2),
.directory-table td:nth-child(2){width:25%}

.directory-table th:nth-child(3),
.directory-table td:nth-child(3){width:16%}

.directory-table th:nth-child(4),
.directory-table td:nth-child(4){width:18%}

.directory-table th:nth-child(5),
.directory-table td:nth-child(5){width:auto}

.directory-table th:nth-child(6),
.directory-table td:nth-child(6){width:54px}

.directory-index-cell{
  color:var(--muted)
}

.index{
  font-size:10px;
  color:var(--muted)
}

.directory-company-cell strong{
  display:block;
  margin:0 0 5px;
  font-size:13px;
  line-height:1.15;
  text-transform:uppercase;
  letter-spacing:.01em
}

.directory-company-cell small{
  display:block;
  color:var(--muted);
  font-size:10px;
  line-height:1.25;
  margin-top:4px
}

.directory-sector-cell{
  padding-top:13px!important
}

.sector{
  display:inline-block;
  border:1px solid var(--ink);
  padding:5px 7px;
  max-width:100%;
  font-size:9px;
  line-height:1.15;
  text-transform:uppercase;
  letter-spacing:.06em;
  overflow-wrap:anywhere
}

.sector--muted{opacity:.48}

.directory-contact-cell{
  min-width:0
}

.directory-contact-name{
  display:block;
  font-size:12px;
  font-weight:700;
  line-height:1.2;
  color:var(--ink)
}

.directory-contact-cell small{
  display:block;
  margin-top:4px;
  color:var(--muted);
  font-size:10px;
  line-height:1.25;
  overflow-wrap:anywhere
}

.directory-offer-cell{
  color:#272727;
  overflow-wrap:anywhere
}

.directory-muted{
  color:var(--muted)
}

.directory-actions-cell{
  text-align:right!important;
  padding-right:0!important
}

.arrow-btn{
  width:34px;
  height:34px;
  border:1px solid var(--ink);
  background:transparent;
  color:var(--ink);
  display:inline-grid;
  place-items:center;
  text-decoration:none;
  font-weight:900
}

.arrow-btn:hover{
  background:var(--ink);
  color:var(--paper)
}

.directory-empty{
  padding:48px 20px!important;
  text-align:center!important
}

.directory-empty strong{
  display:block;
  margin-bottom:8px;
  font-size:22px;
  text-transform:uppercase
}

.directory-empty span{
  display:block;
  color:var(--muted)
}

/* Ficha / Show */

.directory-company-title{
  overflow-wrap:anywhere
}

.directory-detail-grid{
  display:grid;
  grid-template-columns:1.2fr .8fr;
  gap:28px;
  margin-bottom:30px
}

.directory-detail-block{min-width:0}

.directory-data-list{
  margin:0;
  border-top:1px solid #bdb9b2
}

.directory-data-list div{
  display:grid;
  grid-template-columns:160px 1fr;
  gap:20px;
  padding:12px 0;
  border-bottom:1px solid #bdb9b2
}

.directory-data-list dt{
  font-size:9px;
  text-transform:uppercase;
  letter-spacing:.1em;
  color:var(--muted)
}

.directory-data-list dd{
  margin:0;
  font-size:13px;
  overflow-wrap:anywhere
}

.directory-contact-card{
  min-height:220px;
  border:1px solid var(--ink);
  padding:20px;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  background:rgba(244,242,237,.75)
}

.directory-contact-card strong{
  font-size:clamp(28px,3.4vw,52px);
  line-height:.9;
  letter-spacing:-.06em;
  text-transform:uppercase
}

.directory-contact-card span{
  margin-top:12px;
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.1em
}

.directory-contact-card p{
  margin:18px 0 0;
  color:var(--muted);
  line-height:1.45
}

.directory-offer-section{
  margin-top:10px
}

.directory-offer-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  border-left:1px solid #bdb9b2;
  border-top:1px solid #bdb9b2
}

.directory-offer-card{
  min-height:190px;
  padding:16px;
  border-right:1px solid #bdb9b2;
  border-bottom:1px solid #bdb9b2;
  display:flex;
  flex-direction:column
}

.directory-offer-card small{
  font-size:9px;
  text-transform:uppercase;
  letter-spacing:.1em;
  color:var(--muted)
}

.directory-offer-card strong{
  margin:32px 0 10px;
  font-size:22px;
  line-height:1;
  text-transform:uppercase
}

.directory-offer-card p{
  margin:0;
  color:var(--muted);
  line-height:1.4
}

.directory-offer-card span{
  margin-top:auto;
  padding-top:14px;
  font-size:9px;
  text-transform:uppercase;
  letter-spacing:.07em
}

/* Formularios */

.directory-page-actions{
  display:flex;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:8px;
  margin-top:26px
}

.directory-page-actions .cta{
  text-decoration:none;
  display:inline-grid;
  place-items:center
}

.directory-inline-form{margin:0}

.directory-danger{
  border-color:var(--danger);
  background:transparent;
  color:var(--danger)
}

.directory-form{
  border-top:1px solid #bdb9b2;
  padding-top:4px
}

.directory-form-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:0 24px
}

.directory-form-grid .full{
  grid-column:1/-1
}

.directory-form .field{
  padding:7px 0;
  margin:7px 0
}

.directory-form .input{
  border-bottom:1px solid #9e9a93
}

.directory-textarea{
  resize:vertical;
  line-height:1.45
}

.directory-form-section{
  margin-top:28px
}

@media(max-width:1100px){
  .directory-toolbar{
    grid-template-columns:1fr 220px
  }

  .directory-new{
    grid-column:1/-1
  }

  .directory-detail-grid{
    grid-template-columns:1fr
  }

  .directory-offer-grid{
    grid-template-columns:1fr 1fr
  }
}

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

  .directory-new{
    grid-column:auto
  }

  .directory-table{
    min-width:980px
  }
}

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

  .directory-form-grid .full{
    grid-column:auto
  }

  .directory-data-list div{
    grid-template-columns:1fr;
    gap:5px
  }

  .directory-offer-grid{
    grid-template-columns:1fr
  }

  .directory-page-actions{
    justify-content:stretch
  }

  .directory-page-actions .cta,
  .directory-page-actions form,
  .directory-page-actions form .cta{
    width:100%
  }
}


/* ==========================================================================
   SYNERGIA · DIRECTORIO · UI/UX MOCKUP — OVERRIDE FINAL v1.3
   Este bloque es intencionalmente el último del archivo para garantizar que
   Directorio conserve exactamente la jerarquía visual del mockup.
   ========================================================================== */

.directory-page .page-header{
  display:grid;
  grid-template-columns:1.25fr .75fr;
  gap:28px;
  border-bottom:1px solid #bdb9b2;
  padding:16px 0 28px;
  margin-bottom:22px
}

.directory-page .page-header .kicker{
  font-size:10px;
  letter-spacing:.16em;
  text-transform:uppercase;
  margin-bottom:18px;
  font-weight:400
}

.directory-page .page-header h1{
  font-family:Arial,Helvetica,sans-serif;
  font-size:clamp(48px,7vw,108px);
  font-weight:700;
  line-height:.78;
  letter-spacing:-.08em;
  text-transform:uppercase;
  margin:0;
  max-width:1000px
}

.directory-page .page-header .intro{
  align-self:end;
  font-family:Arial,Helvetica,sans-serif;
  font-size:16px;
  font-weight:400;
  line-height:1.35;
  max-width:470px
}

.directory-page .page-header .intro b{
  display:block;
  font-size:11px;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:.12em;
  margin-bottom:12px
}

/* Toolbar idéntica al mockup: búsqueda + giro + alta */
.directory-page .toolbar{
  display:grid;
  grid-template-columns:minmax(0,1fr) 210px auto;
  gap:10px;
  margin:0 0 16px;
  align-items:stretch
}

.directory-page .toolbar input,
.directory-page .toolbar select{
  width:100%;
  height:44px;
  min-height:44px;
  border:1px solid var(--ink);
  border-radius:0;
  background:transparent;
  color:var(--ink);
  padding:0 13px;
  font-family:Arial,Helvetica,sans-serif;
  font-size:12px;
  font-weight:400;
  line-height:44px;
  outline:none;
  appearance:auto
}

.directory-page .toolbar input::placeholder{
  color:#77746f;
  opacity:1
}

.directory-page .toolbar input:focus,
.directory-page .toolbar select:focus{
  outline:0;
  box-shadow:inset 0 -2px 0 var(--ink)
}

.directory-page .directory-new-company{
  min-height:44px;
  padding:0 15px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:1px solid var(--ink);
  background:#ece9e3;
  color:#111;
  text-decoration:none;
  white-space:nowrap;
  font-family:Arial,Helvetica,sans-serif;
  font-size:10px;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.08em
}

/* Tabla: mismas proporciones, líneas y tipografía del mockup */
.directory-page .table-wrap{
  overflow:auto;
  border-top:1px solid #bdb9b2
}

.directory-page table{
  width:100%;
  min-width:1120px;
  border-collapse:collapse;
  table-layout:auto;
  font-family:Arial,Helvetica,sans-serif
}

.directory-page th{
  padding:14px 10px;
  border-bottom:1px solid #bdb9b2;
  text-align:left;
  vertical-align:top;
  color:var(--muted);
  font-size:9px;
  line-height:1.2;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:.12em
}

.directory-page td{
  padding:14px 10px;
  border-bottom:1px solid #bdb9b2;
  text-align:left;
  vertical-align:top;
  color:var(--ink);
  font-size:12px;
  line-height:1.35;
  font-weight:400
}

.directory-page tbody tr{
  background:transparent
}

.directory-page tbody tr:hover{
  background:rgba(16,16,16,.035)
}

.directory-page th:nth-child(1),
.directory-page td:nth-child(1){
  width:46px
}

.directory-page th:nth-child(2),
.directory-page td:nth-child(2){
  width:27%
}

.directory-page th:nth-child(3),
.directory-page td:nth-child(3){
  width:16%
}

.directory-page th:nth-child(4),
.directory-page td:nth-child(4){
  width:18%
}

.directory-page th:nth-child(5),
.directory-page td:nth-child(5){
  width:auto
}

.directory-page th:nth-child(6),
.directory-page td:nth-child(6){
  width:44px;
  padding-right:0
}

.directory-page td strong{
  display:block;
  margin:0;
  font-size:13px;
  line-height:1.15;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:0
}

.directory-page td small{
  display:block;
  margin-top:4px;
  color:var(--muted);
  font-size:10px;
  line-height:1.25;
  font-weight:400
}

.directory-page .index{
  color:var(--muted);
  font-size:10px;
  font-weight:400
}

.directory-page .sector{
  display:inline-block;
  max-width:100%;
  border:1px solid var(--ink);
  padding:5px 7px;
  color:var(--ink);
  background:transparent;
  font-size:9px;
  line-height:1.15;
  font-weight:400;
  text-transform:uppercase;
  letter-spacing:.06em;
  overflow-wrap:anywhere
}

.directory-page .directory-contact-primary{
  display:block;
  color:var(--ink);
  font-size:12px;
  line-height:1.2;
  font-weight:400;
  text-transform:none;
  letter-spacing:0
}

.directory-page .directory-contact small{
  display:block;
  margin-top:4px;
  color:var(--muted);
  font-size:10px;
  line-height:1.25
}

.directory-page .directory-muted{
  color:var(--muted);
  font-size:12px
}

.directory-page .arrow-btn{
  width:34px;
  height:34px;
  border:1px solid var(--ink);
  border-radius:0;
  background:transparent;
  color:var(--ink);
  display:inline-grid;
  place-items:center;
  padding:0;
  text-decoration:none;
  font-size:12px;
  font-weight:400
}

.directory-page .arrow-btn:hover{
  background:#e0ddd6;
  color:var(--ink)
}

.directory-page .directory-no-results{
  padding:34px 10px!important;
  text-align:left!important
}

.directory-page .directory-no-results strong{
  font-size:13px;
  text-transform:uppercase
}

@media(max-width:1050px){
  .directory-page .page-header{
    grid-template-columns:1fr
  }

  .directory-page .toolbar{
    grid-template-columns:1fr 210px auto
  }
}

@media(max-width:820px){
  .directory-page .toolbar{
    grid-template-columns:1fr
  }

  .directory-page .directory-new-company{
    width:100%
  }
}

/* ==========================================================================
   SYNERGIA · OPORTUNIDADES
   Extensión mínima sobre el UI/UX GLOBAL ÚNICO.
   El Pipeline usa directamente .pipeline / .stage / .deal del mockup global.
   ========================================================================== */

.opportunities-page .deal-link{
  display:block;
  color:inherit;
  text-decoration:none
}

.opportunities-page .deal-link:hover .deal{
  background:rgba(16,16,16,.035)
}

.opportunities-page .stage--closing{
  background:#dedad2
}

.opportunities-page .pipeline-empty{
  border-top:1px solid #bdb9b2;
  padding:14px 0;
  color:var(--muted);
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.07em
}

.opportunity-title{
  overflow-wrap:anywhere
}

.opportunity-detail-grid{
  display:grid;
  grid-template-columns:1.2fr .8fr;
  gap:28px;
  margin-bottom:30px
}

.opportunity-detail{
  min-width:0
}

.opportunity-data{
  margin:0;
  border-top:1px solid #bdb9b2
}

.opportunity-data div{
  display:grid;
  grid-template-columns:180px minmax(0,1fr);
  gap:20px;
  padding:12px 0;
  border-bottom:1px solid #bdb9b2
}

.opportunity-data dt{
  font-size:9px;
  text-transform:uppercase;
  letter-spacing:.1em;
  color:var(--muted)
}

.opportunity-data dd{
  margin:0;
  font-size:13px;
  overflow-wrap:anywhere
}

.opportunity-prospect{
  min-height:250px;
  border:1px solid var(--ink);
  padding:20px;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  background:rgba(244,242,237,.75)
}

.opportunity-prospect strong{
  font-size:clamp(28px,3.4vw,52px);
  line-height:.9;
  letter-spacing:-.06em;
  text-transform:uppercase
}

.opportunity-prospect span{
  margin-top:12px;
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.1em
}

.opportunity-prospect p{
  margin:18px 0 0;
  color:var(--muted);
  line-height:1.45
}

.opportunity-history{
  margin-top:20px
}

/* Formularios compartidos para CRUDs de SynErgia */
.entity-form{
  border-top:1px solid #bdb9b2;
  padding-top:4px
}

.entity-form .field{
  padding:7px 0;
  margin:7px 0
}

.entity-form .input{
  border-bottom:1px solid #9e9a93
}

.entity-textarea{
  resize:vertical;
  line-height:1.45
}

.entity-form-section{
  margin-top:28px
}

.entity-actions{
  display:flex;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:8px;
  margin-top:26px
}

.entity-actions .cta{
  text-decoration:none;
  display:inline-grid;
  place-items:center
}

.entity-inline-form{
  margin:0
}

.entity-danger{
  border-color:var(--danger);
  background:transparent;
  color:var(--danger)
}

@media(max-width:1050px){
  .opportunity-detail-grid{
    grid-template-columns:1fr
  }
}

@media(max-width:820px){
  .opportunities-page .pipeline{
    grid-template-columns:repeat(4,260px)
  }
}

@media(max-width:560px){
  .opportunity-data div{
    grid-template-columns:1fr;
    gap:5px
  }

  .entity-actions{
    justify-content:stretch
  }

  .entity-actions .cta,
  .entity-actions form,
  .entity-actions form .cta{
    width:100%
  }
}
