:root {
    font-family: Inter, system-ui, sans-serif;
    color: #192f28;
    background: #f0f5f2;
    --muted: #49655a;
    --line: #dce8df;
    --dark: #102d25;
    --green: #166142;
    --mint: #d9f2e1;
}
* { box-sizing: border-box }
body { margin: 0 }
a { color: var(--green) }
.layout { min-height: 100vh; display: grid; grid-template-columns: 228px minmax(0, 1fr) }
.sidebar { background: var(--dark); color: #f7faf8; display: flex; flex-direction: column; padding: 32px 20px 24px; gap: 5px }
.brand { text-decoration: none; font-size: 27px; font-weight: 900; color: white; letter-spacing: -.07em }
.brand span { color: #9de1b4; font-size: 13px; margin-left: 8px; vertical-align: 4px }
.brandline, .sidefooter small { color: #b9d1c4; margin: 0; font-size: 13px }
nav { display: grid; gap: 7px; margin-top: 40px }
nav a { display: flex; gap: 12px; align-items: center; font-weight: 650; padding: 12px; border-radius: 10px; text-decoration: none; color: #d7e9df }
nav a span { width: 18px; text-align: center }
nav a:hover, nav a[aria-current] { color: var(--dark); background: var(--mint) }
.sidefooter { margin-top: auto; padding-top: 28px; display: grid; gap: 6px }
.sidefooter a { color: #c8e4d4; font-size: 13px; margin-top: 10px }
main { width: 100%; max-width: 1600px; padding: 0 clamp(16px, 3vw, 48px) 48px; margin: 0 auto }
.top, header, .sectionhead { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px }
.top { min-height: 66px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 14px }
.account { display: flex; gap: 10px; align-items: center }
header { padding: 27px 0 23px }
h1, h2, h3, p { margin: 0 }
h1 { font-size: clamp(31px, 4vw, 54px); line-height: 1.05; letter-spacing: -.055em }
h2 { font-size: 21px; letter-spacing: -.035em }
h3 { font-size: 15px; margin-top: 18px }
p { line-height: 1.52 }
header p, .muted { color: var(--muted); margin-top: 5px }
.card { background: white; border: 1px solid var(--line); border-radius: 15px; padding: clamp(14px, 2vw, 25px); min-width: 0 }
main > .card + .card, main > .card + section { margin-top: 17px }
.narrow { max-width: 760px }
.metrics, .tiles { display: grid; gap: 14px; margin-bottom: 16px }
.metrics { grid-template-columns: repeat(4, minmax(0, 1fr)) }
.tiles { grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)) }
.metric { display: grid; gap: 8px }
.metric span, small { font-size: 13px; color: var(--muted) }
.metric strong, .marketnumbers strong { font-size: clamp(22px, 2.4vw, 35px); letter-spacing: -.055em }
.highlight { background: #e0f3e6 }
.hometile h2 { margin: 12px 0 5px }
.hometile p { color: var(--muted) }
.dashboard, .market { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(265px, 1fr); gap: 16px; align-items: start }
.market { margin-bottom: 16px }
.scroll { overflow-x: auto }
table { border-collapse: collapse; width: 100%; margin: 12px 0 0; font-size: 14px }
th, td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--line); white-space: nowrap }
th { font-size: 12px; color: var(--muted) }
tr:last-child td { border-bottom: none }
.activity { display: flex; gap: 11px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 14px }
.activity:last-child { border: 0; padding-bottom: 0 }
.activity p { margin: 4px 0; color: var(--muted) }
.signal { flex: 0 0 33px; min-width: 33px; height: 33px; display: inline-grid; place-items: center; border-radius: 9px; font-size: 20px; font-weight: 700; background: var(--mint); color: var(--green) }
.signal.cancel { background: #fbe5e0; color: #922d26 }
.signal.clean { background: #dcebf7; color: #28547b }
button, .button { display: inline-flex; align-items: center; justify-content: center; gap: 12px; border: 1px solid transparent; border-radius: 9px; padding: 10px 15px; color: white; background: var(--green); font: inherit; font-weight: 700; cursor: pointer; text-decoration: none }
button:hover, .button:hover { background: #0e4b34 }
button.quiet, button.secondary { background: white; color: var(--green); border-color: var(--line) }
button.quiet { padding: 5px 11px }
button.textbutton { background: none; color: #922d26; padding: 2px 0; font-size: 13px; font-weight: 550 }
button.info { width: 22px; height: 22px; padding: 0; border-radius: 50%; background: var(--mint); color: var(--green); font-size: 13px; margin-left: 3px }
:focus-visible { outline: 3px solid #237853; outline-offset: 3px }
dialog { border-radius: 16px; border: 1px solid var(--line); padding: 24px; width: min(450px, 94vw); color: inherit }
dialog::backdrop { background: #102d2594 }
dialog p { margin-top: 5px; color: var(--muted) }
dl { margin: 13px 0 18px; font-size: 14px }
dl div { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line) }
dd { margin: 0; font-weight: 650; text-align: right; white-space: nowrap }
.fields, .simfields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; margin: 16px 0 }
.simfields { grid-template-columns: repeat(auto-fit, minmax(min(165px, 100%), 1fr)) }
.wide { grid-column: 1 / -1 }
label { display: grid; gap: 5px; font-size: 14px; font-weight: 650 }
input, select { color: inherit; font: inherit; font-weight: 480; width: 100%; padding: 10px; border: 1px solid #bbcdc1; border-radius: 8px; background: #fbfdfb }
input[type=checkbox] { width: auto; accent-color: var(--green) }
.check { display: flex; align-items: flex-start; gap: 8px; margin: 10px 0; font-size: 13px }
.privacy { font-size: 13px; color: var(--muted) }
summary { cursor: pointer; font-weight: 650 }
.privacy p { margin-top: 6px }
form > button:not(.quiet):not(.textbutton), .invoice > button { margin-top: 8px }
.message { border-radius: 9px; padding: 12px; background: var(--mint); margin-top: 14px }
.message.error { background: #fbe5e0; color: #922d26 }
.welcome { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(330px, 1fr); gap: 16px; margin-top: 30px; align-items: stretch }
.hero { background: radial-gradient(ellipse at 105% 110%, #347055 0, #1c493a 34%, var(--dark) 72%); color: #f3faf4; border-radius: 15px; padding: clamp(23px, 4vw, 62px); display: flex; flex-direction: column; justify-content: center; gap: 18px }
.hero p { color: #c8e2d5; max-width: 42ch }
.hero p:first-child { font-size: 13px; font-weight: 700; letter-spacing: .08em }
.hero h1 { max-width: 13ch; font-size: clamp(40px, 5vw, 71px) }
.access { padding: clamp(18px, 2.6vw, 38px) }
.badge, .marker { display: inline-block; padding: 4px 8px; border-radius: 500px; font-size: 12px; font-weight: 750; white-space: nowrap }
.high { background: #d8f0dd; color: #174b2f }
.medium { background: #fff0c4; color: #684a04 }
.low { background: #fbe0dc; color: #8a3029 }
.invoice { max-width: 790px }
.invoice p { margin-top: 18px }
.documents { margin-bottom: 0 }
.documents li { margin: 7px 0 }
.map { position: relative; margin-top: 15px; overflow: hidden; border-radius: 12px }
.map img { width: 100%; height: auto; display: block }
.marker { position: absolute; transform: translate(-50%, -50%); text-decoration: none; border: 1px solid currentColor; box-shadow: 0 2px 5px #102d2530 }
.marker:hover, .marker[aria-current] { z-index: 2; outline: 2px solid var(--dark); outline-offset: 2px }
.legend { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 10px }
.zone-picker { display: flex; align-items: end; flex-wrap: wrap; gap: 9px; margin: 12px 0 }
.marketnumbers { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px }
.marketnumbers div { display: grid; align-content: space-between; background: #edf7f0; padding: 11px; border-radius: 8px }
#simulador > p { margin-top: 10px; font-size: 13px }
@media(max-width: 1080px) {
    .layout { grid-template-columns: 175px minmax(0, 1fr) }
    .sidebar { padding-inline: 13px }
    .dashboard, .market { grid-template-columns: minmax(0, 1fr) }
    .welcome { grid-template-columns: minmax(0, 1fr) }
    .hero h1 { max-width: 22ch }
}
@media(max-width: 680px) {
    .layout { display: block }
    .sidebar { padding: 12px 16px; gap: 4px }
    .sidefooter { padding: 0; margin: 0 }
    .sidefooter strong, .sidefooter small, .brandline { display: none }
    .sidefooter a { margin: 0 }
    nav { display: flex; gap: 4px; margin: 4px 0; overflow-x: auto }
    nav a { font-size: 13px; padding: 7px }
    nav a span { display: none }
    .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)) }
    .fields { grid-template-columns: minmax(0, 1fr) }
    .marker { font-size: 10px; padding: 2px 4px }
}
@media print {
    :root { background: white }
    .layout { display: block }
    main { padding: 0 }
    .sidebar, .top, header, .screenonly, .message { display: none !important }
    .invoice { border: none }
    .invoice th, .invoice td { white-space: normal }
}
