:root {
    --primary: #1e40af;
    --primary-soft: rgba(30, 64, 175, 0.1);
    --background: #f4f7fa;
    --text-dark: #111827;
    --text-muted: #6b7280;
    --border: #e5e7eb;
}

.i2g-admin[data-view="registro_ejecutivo"] {
    font-family: 'Inter', sans-serif;
    background-color: var(--background);
    color: var(--text-dark);
    padding: 0;
    min-height: 100vh;
}

.i2g-admin[data-view="registro_ejecutivo"] .i2g-content {
    gap: 0;
}

.i2g-alert {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border-radius: 0.75rem;
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
    font-weight: 600;
    box-shadow: 0 6px 18px rgba(185, 28, 28, 0.12);
}

.i2g-alert.hidden {
    display: none;
}

.card {
    background-color: #fff;
    border-radius: 0.75rem;
    border: 1px solid var(--border);
    padding: 2rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.stepper {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.step {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-muted);
    flex: 1;
}

.step-circle {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    background-color: #fff;
}

.step-title {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
}

.step-subtitle {
    font-weight: 600;
    color: var(--text-dark);
}

.step-line {
    flex: 0 0 3rem;
    height: 2px;
    background-color: var(--border);
}

.step.active {
    color: var(--primary);
}

.step.active .step-circle {
    border-color: var(--primary);
    background-color: var(--primary-soft);
    color: var(--primary);
}

.step.completed .step-circle {
    background-color: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

.section-header {
    margin-bottom: 1.5rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 700;
}

.section-subtitle {
    color: var(--text-muted);
    margin-top: 0.35rem;
}

.label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.4rem;
}

.i2g-register .input-field,
.i2g-register input.input-field,
.i2g-register select.input-field,
.i2g-register textarea.input-field {
    width: 100%;
    border-radius: 0.5rem;
    border: 1px solid var(--border);
    padding: 0.65rem 0.8rem;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    background-color: #fff;
    box-sizing: border-box;
    min-height: 42px;
    line-height: 1.3;
    appearance: none;
}

.i2g-register .input-field:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-soft);
}

.i2g-register .input-field.is-invalid {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

.helper-text {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.4rem;
}

.info-icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    color: #4b5563;
    cursor: pointer;
}

.info-icon .tooltip-text {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 125%;
    background-color: #111827;
    color: #f9fafb;
    padding: 0.35rem 0.5rem;
    border-radius: 0.375rem;
    font-size: 0.6875rem;
    font-weight: 600;
    max-width: 240px;
    white-space: normal;
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease, visibility 0.15s ease;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.info-icon:hover .tooltip-text,
.info-icon:focus-within .tooltip-text {
    opacity: 1;
    visibility: visible;
}

.info-icon .tooltip-text::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-width: 6px;
    border-style: solid;
    border-color: #111827 transparent transparent transparent;
}

.range-field {
    width: 100%;
    accent-color: var(--primary);
    margin-top: 0.3rem;
    height: 6px;
    border-radius: 999px;
    background: #e2e8f0;
}

.range-field::-webkit-slider-runnable-track {
    height: 6px;
    background: #e2e8f0;
    border-radius: 999px;
}

.range-field::-webkit-slider-thumb {
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 999px;
    background: var(--primary);
    border: 2px solid #fff;
    box-shadow: 0 2px 6px rgba(30, 64, 175, 0.3);
    margin-top: -7px;
}

.range-field::-moz-range-track {
    height: 6px;
    background: #e2e8f0;
    border-radius: 999px;
}

.range-field::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 999px;
    background: var(--primary);
    border: 2px solid #fff;
    box-shadow: 0 2px 6px rgba(30, 64, 175, 0.3);
}

.range-value {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
}

.portfolio-block {
    border: 1px solid var(--border);
    background: #fff;
    padding: 1.5rem;
    border-radius: 0.75rem;
}

.portfolio-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.portfolio-title {
    font-weight: 700;
    color: #1e3a8a;
}

.portfolio-caption {
    font-size: 0.85rem;
    color: #475569;
}

.tag-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    padding: 0.5rem;
    cursor: text;
}

.tag-dropdown {
    position: absolute;
    left: 0;
    right: 0;
    margin-top: 0.5rem;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
    max-height: 12rem;
    overflow-y: auto;
    z-index: 30;
}

.tag-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.3rem 0.55rem;
    border-radius: 9999px;
    background-color: #eef2ff;
    color: #1e40af;
    font-size: 0.75rem;
    font-weight: 600;
}

.tag-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.tag-option:hover {
    background-color: #f9fafb;
}

.tag-option.active {
    border-color: #1d4ed8;
    background-color: #eff6ff;
}

.tag-search-input {
    flex: 1;
    min-width: 140px;
    padding: 0.35rem;
    font-size: 0.9rem;
    outline: none;
}

.portfolio-form .form-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    margin-bottom: 0.3rem;
}

.portfolio-form .form-input {
    width: 100%;
    padding: 0.5rem 0.6rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    outline: none;
}

.portfolio-form .form-input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 1px #2563eb33;
}

.form-card {
    position: relative;
    padding: 1.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    background-color: #fff;
}

.form-card + .form-card {
    margin-top: 1rem;
}

.btn-remove {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: #ef4444;
    background: transparent;
    border: 1px solid #fee2e2;
    border-radius: 9999px;
    padding: 0.25rem 0.6rem;
}

.btn-remove:hover {
    background-color: #fef2f2;
}

.editor-toolbar button {
    padding: 0.35rem;
    border-radius: 0.35rem;
    border: 1px solid #e5e7eb;
    background: #fff;
    color: #4b5563;
}

.editor-toolbar button:hover {
    background-color: #f3f4f6;
}

.editor-area {
    border: 1px solid #e5e7eb;
    min-height: 140px;
    border-radius: 0.5rem;
    padding: 0.75rem;
}

.editor-area:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 1px #2563eb33;
}

/* Make bullets and formatting visible in contenteditable */
.editor-area ul {
    list-style-type: disc;
    padding-left: 1.5rem;
    margin: 0.5rem 0;
}

.editor-area ol {
    list-style-type: decimal;
    padding-left: 1.5rem;
    margin: 0.5rem 0;
}

.editor-area li {
    margin: 0.25rem 0;
}

.editor-area strong {
    font-weight: 700;
}

.editor-area em {
    font-style: italic;
}

.editor-area u {
    text-decoration: underline;
}

.end-date-container.hidden {
    display: none;
}


.summary-card {
    position: sticky;
    top: 6rem;
    height: fit-content;
}

.summary-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.summary-list {
    display: grid;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.summary-label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #9ca3af;
    letter-spacing: 0.08em;
    font-weight: 600;
}

.summary-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
}

.summary-tip {
    display: flex;
    gap: 0.6rem;
    align-items: flex-start;
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    padding: 0.9rem;
    border-radius: 0.75rem;
    color: #0f172a;
    font-size: 0.85rem;
}

.btn-primary {
    background-color: var(--primary);
    color: #fff;
    padding: 0.75rem 1.5rem;
    border-radius: 0.6rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.btn-primary:hover {
    background-color: #1d4ed8;
}

.btn-secondary {
    background-color: #fff;
    border: 1px solid var(--border);
    color: #1f2937;
    padding: 0.7rem 1.3rem;
    border-radius: 0.6rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.btn-secondary:hover {
    border-color: #cbd5f5;
    color: var(--primary);
}

.btn-tertiary {
    color: var(--primary);
    font-weight: 600;
    padding: 0.7rem 1.1rem;
    border-radius: 0.6rem;
    background: rgba(30, 64, 175, 0.08);
}

.btn-tertiary:hover {
    background: rgba(30, 64, 175, 0.14);
}

.btn-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: #1d4ed8;
    background: transparent;
    border: none;
    padding: 0;
}

.btn-link:hover {
    text-decoration: underline;
}

.hidden {
    display: none;
}

@media (max-width: 1024px) {
    .summary-card {
        position: static;
    }
}

@media (max-width: 768px) {
    .stepper {
        flex-direction: column;
        gap: 1rem;
    }

    .step-line {
        width: 2px;
        height: 2rem;
    }
}
