:root {
    --vino: #6b1731;
    --vino-oscuro: #4a1023;
    --verde: #0f5b4f;
    --verde-oscuro: #0a433a;
    --arena: #efe4cf;
    --arena-fuerte: #dcc9a2;
    --tinta: #1f2933;
    --tinta-suave: #52606d;
    --linea: rgba(31, 41, 51, 0.12);
    --fondo: #f3efe6;
    --blanco: #ffffff;
    --sombra: 0 18px 40px rgba(18, 28, 45, 0.12);
    --radio: 18px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Montserrat', Arial, sans-serif;
    color: var(--tinta);
    background:
        radial-gradient(circle at top left, rgba(107, 23, 49, 0.12), transparent 28%),
        radial-gradient(circle at top right, rgba(15, 91, 79, 0.16), transparent 24%),
        linear-gradient(180deg, #f8f5ef 0%, var(--fondo) 42%, #f4efe4 100%);
    min-height: 100vh;
}

a {
    color: var(--vino);
    font-weight: 700;
    text-decoration: none;
}

a:hover {
    color: var(--verde);
}

.page-shell {
    min-height: 100vh;
}

.services-panel {
    padding: 22px 24px 8px;
}

.services-wrap {
    max-width: 1180px;
    margin: 0 auto;
}

.services-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 18px;
}

.services-title-group {
    display: flex;
    align-items: center;
    gap: 16px;
}

.services-logo {
    width: 320px;
    max-width: 100%;
    height: auto;
    display: block;
}

.services-title-badge {
    display: inline-flex;
    align-items: center;
    min-height: 54px;
    padding: 10px 24px;
    border-radius: 14px 14px 0 0;
    background: linear-gradient(135deg, #c39a55, #b98b42);
    color: #fff;
    font-size: 19px;
    font-weight: 800;
    letter-spacing: 0.03em;
}

.services-intro {
    margin-bottom: 0;
    background:
        radial-gradient(circle at top left, rgba(195, 154, 85, 0.12), transparent 34%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(250, 246, 239, 0.96));
}

.services-intro h1 {
    margin: 0 0 12px;
    color: var(--verde);
    font-size: clamp(28px, 4vw, 44px);
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    padding: 26px 0 0;
}

.usage-section {
    margin-top: 28px;
    padding: 28px;
    background:
        radial-gradient(circle at top right, rgba(15, 91, 79, 0.12), transparent 30%),
        radial-gradient(circle at bottom left, rgba(107, 23, 49, 0.08), transparent 28%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(248, 243, 234, 0.98));
}

.usage-header {
    max-width: 760px;
}

.usage-kicker {
    margin: 0 0 8px;
    color: var(--vino);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.usage-header h2 {
    margin: 0;
    color: var(--verde);
    font-size: clamp(24px, 3vw, 34px);
}

.usage-summary {
    margin: 10px 0 0;
    color: var(--tinta-suave);
    font-size: 17px;
    line-height: 1.6;
}

.usage-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-top: 24px;
}

.usage-card,
.usage-flow-card {
    position: relative;
    overflow: hidden;
    padding: 22px;
    border-radius: 22px;
    border: 1px solid rgba(15, 91, 79, 0.1);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 18px 36px rgba(18, 28, 45, 0.08);
}

.usage-card::after,
.usage-flow-card::after {
    content: "";
    position: absolute;
    inset: auto -40px -54px auto;
    width: 128px;
    height: 128px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(15, 91, 79, 0.12), transparent 68%);
}

.usage-step {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    margin-bottom: 16px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--vino), var(--verde));
    color: #fff;
    font-size: 20px;
    font-weight: 800;
}

.usage-card h3,
.usage-flow-card h3 {
    margin: 0 0 10px;
    color: var(--tinta);
    font-size: 20px;
}

.usage-card p {
    margin: 0;
    color: var(--tinta-suave);
    line-height: 1.6;
}

.usage-flow {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 18px;
    margin-top: 18px;
}

.usage-flow-highlight {
    background: linear-gradient(180deg, rgba(15, 91, 79, 0.09), rgba(255, 255, 255, 0.9));
}

.usage-list {
    margin: 0;
    padding-left: 20px;
    color: var(--tinta-suave);
    line-height: 1.7;
}

.usage-list li + li {
    margin-top: 8px;
}

.service-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 32px 28px;
    border-radius: 24px;
    background:
        radial-gradient(circle at top, rgba(255, 255, 255, 0.55), transparent 40%),
        linear-gradient(180deg, rgba(243, 235, 216, 0.94), rgba(255, 255, 255, 0.95));
    border: 1px solid rgba(15, 91, 79, 0.08);
    box-shadow: var(--sombra);
    color: var(--tinta);
    min-height: 280px;
    justify-content: center;
}

button.service-option {
    width: 100%;
    border: 1px solid rgba(15, 91, 79, 0.08);
    box-shadow: var(--sombra);
}

.service-option:hover {
    transform: translateY(-4px);
    color: var(--tinta);
}

.service-icon {
    width: 148px;
    height: 148px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    margin-bottom: 20px;
    background: linear-gradient(145deg, #0d7b68, #0a5a4c);
    color: #fff;
    font-size: 40px;
    font-weight: 800;
    letter-spacing: 0.08em;
    box-shadow: inset 0 0 0 10px rgba(255, 255, 255, 0.08);
}

.service-heading {
    display: block;
    margin-bottom: 10px;
    color: #0d7b68;
    font-size: 31px;
    font-weight: 800;
    line-height: 1.1;
}

.service-text {
    display: block;
    max-width: 400px;
    color: var(--tinta-suave);
    font-size: 18px;
    line-height: 1.5;
}

.portal-header {
    background:
        linear-gradient(135deg, rgba(107, 23, 49, 0.97), rgba(74, 16, 35, 0.98)),
        linear-gradient(90deg, rgba(255, 255, 255, 0.06), transparent);
    color: var(--blanco);
    padding: 18px 24px 0;
    box-shadow: 0 12px 24px rgba(74, 16, 35, 0.22);
    position: relative;
    overflow: hidden;
}

.login-page {
    position: relative;
    overflow-x: hidden;
    background:
        linear-gradient(180deg, rgba(245, 241, 232, 0.9), rgba(239, 232, 218, 0.95)),
        linear-gradient(180deg, #f6f2ea 0%, #eee6d6 48%, #f5f1e7 100%);
}

.login-page::before,
.login-page::after {
    content: "";
    position: fixed;
    left: 0;
    right: 0;
    pointer-events: none;
    z-index: 0;
}

.login-page::before {
    top: 0;
    bottom: 0;
    background:
        linear-gradient(180deg, rgba(11, 45, 58, 0.06), rgba(11, 45, 58, 0.02) 30%, transparent 30%),
        repeating-linear-gradient(90deg,
            rgba(107, 23, 49, 0.14) 0 92px,
            rgba(244, 180, 0, 0.16) 92px 184px,
            rgba(15, 91, 79, 0.15) 184px 276px,
            rgba(34, 63, 95, 0.14) 276px 368px,
            transparent 368px 430px),
        repeating-linear-gradient(90deg,
            rgba(15, 91, 79, 0.12) 0 110px,
            rgba(107, 23, 49, 0.1) 110px 220px,
            rgba(214, 156, 62, 0.12) 220px 330px,
            transparent 330px 430px);
    background-position:
        0 100%,
        0 calc(100% - 92px),
        60px calc(100% - 176px);
    background-size:
        100% 100%,
        430px 78px,
        430px 68px;
    background-repeat: no-repeat, repeat-x, repeat-x;
    opacity: 0.95;
}

.login-page::after {
    top: 0;
    height: 48vh;
    background:
        radial-gradient(circle at 15% 16%, rgba(255, 255, 255, 0.7), transparent 18%),
        radial-gradient(circle at 84% 14%, rgba(15, 91, 79, 0.12), transparent 22%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.44), transparent 72%);
}

.portal-header-login {
    padding: 26px 24px 110px;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(240, 235, 224, 0.94)),
        linear-gradient(180deg, rgba(244, 240, 232, 0.98) 0%, rgba(229, 235, 227, 0.98) 100%);
    box-shadow: 0 18px 38px rgba(31, 41, 51, 0.12);
    color: var(--tinta);
}

.portal-header-login::after {
    background:
        linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.34) 28%, transparent 29%),
        linear-gradient(120deg, transparent 0%, rgba(15, 91, 79, 0.04) 62%, transparent 63%);
}

.portal-header::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.05) 32%, transparent 33%),
        linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.04) 58%, transparent 59%);
    pointer-events: none;
}

.portal-brand-row,
.portal-nav,
.hero-panel {
    max-width: 1180px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.portal-brand-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    padding-bottom: 18px;
}

.portal-brand-row-login {
    max-width: 980px;
    padding-bottom: 14px;
    justify-content: center;
}

.portal-brand {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.portal-brand-login {
    align-items: center;
    gap: 28px;
    flex-wrap: nowrap;
    justify-content: center;
    text-align: left;
}

.portal-logo {
    width: 320px;
    max-width: 100%;
    height: auto;
    display: block;
    filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.18));
}

.portal-title {
    min-width: 280px;
    flex: 1 1 320px;
}

.portal-title-login {
    max-width: 760px;
    padding-top: 0;
}

.portal-emblems {
    display: flex;
    gap: 10px;
}

.portal-emblem {
    width: 54px;
    height: 54px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    font-weight: 800;
    letter-spacing: 0.08em;
    background: linear-gradient(145deg, rgba(239, 228, 207, 0.95), rgba(220, 201, 162, 0.85));
    color: var(--vino);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.portal-title {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.portal-kicker {
    font-size: 12px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.72);
}

.portal-header-login .portal-kicker {
    color: #6e7d74;
    font-weight: 800;
}

.portal-name {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.portal-header-login .portal-name {
    color: #7a233f;
    font-size: clamp(34px, 4.1vw, 52px);
    line-height: 1.04;
}

.portal-subtitle {
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
}

.portal-header-login .portal-subtitle {
    color: #465560;
    font-size: 18px;
    line-height: 1.5;
}

.portal-logo-login {
    width: min(340px, 34vw);
    filter: drop-shadow(0 14px 28px rgba(31, 41, 51, 0.14));
}

.portal-divider {
    max-width: 980px;
    height: 1px;
    margin: 0 auto;
    background: linear-gradient(90deg, transparent 0%, rgba(31, 41, 51, 0.18) 10%, rgba(31, 41, 51, 0.18) 90%, transparent 100%);
    position: relative;
    z-index: 1;
}

.portal-badges {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.portal-badge {
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: rgba(255, 255, 255, 0.9);
    font-size: 12px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.portal-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 14px 0 18px;
    border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.portal-nav a {
    color: rgba(255, 255, 255, 0.8);
    padding: 10px 14px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
}

.portal-nav a:hover,
.portal-nav a.is-active {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
}

.hero-panel {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
    gap: 24px;
    align-items: stretch;
    padding: 18px 0 34px;
}

.hero-panel.hero-compact {
    grid-template-columns: 1fr;
}

.hero-main,
.hero-side {
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--sombra);
}

.hero-main {
    min-height: 280px;
    padding: 34px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    background:
        linear-gradient(160deg, rgba(7, 33, 44, 0.2), rgba(7, 33, 44, 0.75)),
        repeating-linear-gradient(120deg, rgba(255, 196, 84, 0.2) 0 6px, transparent 6px 24px),
        linear-gradient(135deg, #0f5b4f 0%, #1c6f63 30%, #20425d 72%, #6b1731 100%);
    color: #fff;
}

.hero-main h1,
.hero-main h2 {
    margin: 0 0 12px;
    color: #fff;
    text-align: left;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.05;
}

.hero-main p {
    margin: 0;
    max-width: 700px;
    font-size: 16px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
}

.hero-chip-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.hero-chip {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.hero-side {
    background: linear-gradient(180deg, rgba(239, 228, 207, 0.94), rgba(255, 255, 255, 0.98));
    padding: 28px;
    color: var(--tinta);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 18px;
}

.hero-side h3 {
    margin: 0;
    color: var(--verde);
    font-size: 20px;
}

.hero-side p {
    margin: 0;
    color: var(--tinta-suave);
    line-height: 1.55;
}

.hero-side ul {
    margin: 0;
    padding-left: 18px;
    color: var(--tinta);
}

.hero-side li {
    margin-bottom: 8px;
}

.container {
    max-width: 1180px;
    margin: -10px auto 0;
    padding: 0 24px 40px;
    position: relative;
    z-index: 2;
}

.container.narrow {
    max-width: 760px;
}

.result-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
}

.result-container {
    width: 100%;
    margin: 0 auto;
    padding: 0;
}

.result-card {
    margin-bottom: 0;
}

.compact-actions {
    margin-top: 0;
}

.card {
    background: rgba(255, 255, 255, 0.94);
    padding: 26px;
    border-radius: var(--radio);
    margin-bottom: 18px;
    border: 1px solid rgba(107, 23, 49, 0.08);
    box-shadow: var(--sombra);
    backdrop-filter: blur(10px);
}

.card.section-card {
    padding: 32px;
}

h2 {
    margin-top: 0;
    text-align: left;
    color: var(--vino);
    font-size: 30px;
}

h3 {
    color: var(--verde);
    margin-top: 24px;
    margin-bottom: 12px;
}

.page-lead {
    margin: 0 0 22px;
    color: var(--tinta-suave);
    line-height: 1.65;
}

.meta-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 18px;
}

.meta-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(15, 91, 79, 0.08);
    color: var(--verde);
    font-size: 13px;
    font-weight: 700;
}

label {
    display: block;
    margin-bottom: 10px;
    color: var(--tinta);
    font-weight: 600;
}

input,
select {
    width: 100%;
    padding: 12px 14px;
    margin: 8px 0 14px;
    border: 1px solid rgba(31, 41, 51, 0.14);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.96);
    color: var(--tinta);
    font-size: 15px;
}

input:focus,
select:focus {
    outline: none;
    border-color: rgba(15, 91, 79, 0.55);
    box-shadow: 0 0 0 4px rgba(15, 91, 79, 0.12);
}

.form-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.form-row label {
    flex: 1 0 180px;
    margin: 0;
}

.form-row select,
.form-row input[type="number"],
.form-row input[type="text"] {
    flex: 2 0 0;
    margin: 0;
}

.form-row-measure {
    align-items: stretch;
}

.measure-group {
    flex: 2 0 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 120px;
    gap: 12px;
}

.measure-group input,
.measure-group select {
    margin: 0;
}

#checklist-dinamico {
    padding: 10px 0 2px;
}

#checklist-dinamico label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: rgba(15, 91, 79, 0.05);
    border: 1px solid rgba(15, 91, 79, 0.08);
    border-radius: 12px;
}

#checklist-dinamico input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--verde);
    flex: none;
}

button,
.button-inline,
.button-link {
    border: none;
    cursor: pointer;
    width: 100%;
    padding: 14px 18px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--verde), var(--verde-oscuro));
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    text-align: center;
    box-shadow: 0 12px 24px rgba(15, 91, 79, 0.18);
}

button:hover,
.button-inline:hover,
.button-link:hover {
    background: linear-gradient(135deg, #157062, #0b4a40);
    color: #fff;
}

.button-inline,
.button-link {
    width: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.button-secondary {
    background: linear-gradient(135deg, #e9dfcb, #dbc9a8);
    color: var(--tinta);
    box-shadow: none;
}

.button-secondary:hover {
    background: linear-gradient(135deg, #e3d5bb, #d2ba8d);
    color: var(--tinta);
}

.button-danger {
    background: linear-gradient(135deg, #b71c1c, #8f1717);
}

.button-danger:hover {
    background: linear-gradient(135deg, #a01919, #761212);
}

.link-row,
.admin-actions,
.result-links {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 18px;
}

.inline-form {
    margin: 0;
}

.notice {
    padding: 14px 16px;
    border-radius: 14px;
    margin-bottom: 14px;
    font-weight: 600;
}

.success {
    background: rgba(27, 94, 32, 0.1);
    color: #1b5e20;
}

.error {
    background: rgba(183, 28, 28, 0.1);
    color: #b71c1c;
}

.admin-form label {
    display: block;
    font-weight: 700;
    margin-top: 10px;
}

.record-card {
    position: relative;
    overflow: hidden;
}

.record-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 6px;
    height: 100%;
    background: linear-gradient(180deg, var(--vino), var(--verde));
}

.record-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 18px;
    margin-top: 12px;
}

.record-item {
    color: var(--tinta-suave);
}

.record-item strong {
    color: var(--tinta);
}

.status-panel {
    border-left: 5px solid var(--verde);
}

.alto {
    color: #b71c1c;
    font-weight: 800;
}

.medio {
    color: #d17b00;
    font-weight: 800;
}

.bajo {
    color: #1b5e20;
    font-weight: 800;
}

.result-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 18px;
    margin: 18px 0;
}

.result-item {
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(15, 91, 79, 0.06);
    border: 1px solid rgba(15, 91, 79, 0.08);
}

.result-item strong {
    display: block;
    margin-bottom: 4px;
    color: var(--verde);
}

.inconsistency-box {
    padding: 16px 18px;
    border-radius: 16px;
    background: rgba(107, 23, 49, 0.06);
    border: 1px solid rgba(107, 23, 49, 0.08);
    margin: 18px 0;
}

.inconsistency-box strong {
    display: block;
    margin-bottom: 8px;
    color: var(--vino);
}

.login-card {
    width: min(560px, 100%);
    margin: 0 auto;
}

.login-shell {
    position: relative;
    z-index: 1;
}

.login-container {
    min-height: calc(100vh - 280px);
    margin: -62px auto 0;
    padding-bottom: 72px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    border: 1px solid rgba(122, 35, 63, 0.08);
    box-shadow: 0 30px 62px rgba(31, 41, 51, 0.18);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(250, 247, 241, 0.98));
    text-align: center;
}

.login-card form {
    margin-top: 18px;
    text-align: left;
}

.modal-open {
    overflow: hidden;
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(14, 24, 35, 0.64);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 1000;
}

.modal-overlay.is-open {
    display: flex;
}

.modal-window {
    width: min(980px, 100%);
    max-height: calc(100vh - 40px);
    background: linear-gradient(180deg, rgba(249, 246, 239, 0.98), rgba(255, 255, 255, 0.98));
    border-radius: 24px;
    box-shadow: 0 28px 60px rgba(10, 22, 34, 0.34);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.modal-window-large {
    width: min(1100px, 100%);
}

.modal-window-xlarge {
    width: min(1240px, 100%);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
    padding: 22px 26px;
    background: linear-gradient(135deg, var(--vino), var(--vino-oscuro));
    color: #fff;
}

.modal-header h2 {
    margin: 4px 0 0;
    color: #fff;
}

.modal-kicker {
    margin: 0;
    font-size: 12px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.74);
}

.modal-close {
    width: 48px;
    min-width: 48px;
    height: 48px;
    padding: 0;
    border-radius: 50%;
    font-size: 28px;
    line-height: 1;
    box-shadow: none;
    background: rgba(255, 255, 255, 0.12);
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.modal-body {
    overflow: auto;
    max-height: calc(100vh - 148px);
    padding: 24px;
}

.modal-body-iframe {
    padding: 0;
    background: #f4efe3;
}

.modal-section-card {
    margin-bottom: 0;
}

.history-frame {
    width: 100%;
    height: calc(100vh - 148px);
    border: 0;
    background: transparent;
}

.modal-embedded-body {
    background: transparent;
}

.modal-history-shell {
    padding: 20px;
}

.embedded-card {
    box-shadow: none;
    border-color: rgba(15, 91, 79, 0.12);
    background: rgba(255, 255, 255, 0.98);
}

.services-panel-history {
    padding-bottom: 10px;
}

.service-grid-history .service-option-active {
    pointer-events: none;
    border-color: rgba(107, 23, 49, 0.14);
    background:
        radial-gradient(circle at top, rgba(255, 255, 255, 0.62), transparent 40%),
        linear-gradient(180deg, rgba(232, 223, 203, 0.95), rgba(255, 255, 255, 0.96));
}

.admin-edit-card {
    background: linear-gradient(180deg, rgba(239, 228, 207, 0.55), rgba(255, 255, 255, 0.96));
}

.footer-note {
    margin-top: 16px;
    color: var(--tinta-suave);
    font-size: 13px;
}

.oficio {
    border: 1px solid var(--linea);
    padding: 20px;
}

.oficio h1 {
    text-align: center;
    font-size: 18px;
}

.oficio p {
    margin: 5px 0;
}

@media (max-width: 900px) {
    .service-grid {
        grid-template-columns: 1fr;
    }

    .usage-grid,
    .usage-flow {
        grid-template-columns: 1fr;
    }

    .portal-brand-row,
    .hero-panel {
        grid-template-columns: 1fr;
        display: grid;
    }

    .portal-brand-row {
        gap: 16px;
    }

    .portal-badges {
        justify-content: flex-start;
    }

    .container {
        padding: 0 16px 32px;
    }

    .hero-main {
        min-height: 220px;
        padding: 24px;
    }
}

@media (max-width: 700px) {
    .services-panel {
        padding: 16px 16px 6px;
    }

    .services-title-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .services-title-group {
        width: 100%;
        flex-direction: column;
        align-items: center;
    }

    .services-logo,
    .portal-logo {
        width: 220px;
    }

    .services-title-badge {
        font-size: 17px;
        min-height: 48px;
        width: 100%;
        justify-content: center;
        border-radius: 14px;
    }

    .service-option {
        min-height: auto;
        padding: 26px 20px;
    }

    .usage-section {
        padding: 22px;
    }

    .modal-overlay {
        padding: 10px;
    }

    .modal-header,
    .modal-body,
    .modal-history-shell {
        padding: 18px;
    }

    .history-frame {
        height: calc(100vh - 120px);
    }

    .service-icon {
        width: 116px;
        height: 116px;
        font-size: 30px;
    }

    .service-heading {
        font-size: 26px;
    }

    .service-text {
        font-size: 16px;
    }

    .portal-header {
        padding: 14px 16px 0;
    }

    .portal-header-login {
        padding: 18px 16px 74px;
    }

    .portal-brand-row-login {
        padding-bottom: 12px;
    }

    .portal-brand-login {
        flex-wrap: wrap;
        gap: 14px;
        text-align: center;
    }

    .portal-logo-login {
        width: 260px;
    }

    .portal-title-login {
        min-width: 0;
        padding-top: 0;
    }

    .portal-header-login .portal-kicker {
        letter-spacing: 0.14em;
    }

    .portal-header-login .portal-name {
        font-size: 32px;
    }

    .portal-header-login .portal-subtitle {
        font-size: 15px;
    }

    .login-container {
        min-height: auto;
        margin-top: -28px;
    }

    .portal-name {
        font-size: 22px;
    }

    .form-row,
    .record-grid,
    .result-grid {
        grid-template-columns: 1fr;
        display: grid;
    }

    .form-row label,
    .form-row select,
    .form-row input[type="number"],
    .form-row input[type="text"] {
        flex: auto;
        width: 100%;
    }

    .measure-group {
        grid-template-columns: 1fr;
    }

    .card,
    .card.section-card {
        padding: 22px;
    }
}