:root {
  --v2-bg: #f0f0f0;
  --v2-surface: #ffffff;
  --v2-line: #d8dde5;
  --v2-text: #1d2127;
  --v2-muted: #5a6470;
  --v2-brand-red: #c60000;
  --v2-brand-blue: #007be5;
  --v2-brand-blue-deep: #00559f;
  --v2-sidebar: linear-gradient(180deg, #f4f7fb 0%, #e7eef6 100%);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: "Manrope", "Inter", "Segoe UI", sans-serif;
  background: var(--v2-bg);
  color: var(--v2-text);
}

.v2-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 300px 1fr;
}

.v2-sidebar {
  border-right: 1px solid var(--v2-line);
  background: var(--v2-sidebar);
  padding: 24px 16px;
}

.v2-logo-wrap {
  margin-bottom: 16px;
}

.v2-logo {
  display: block;
  width: 33%;
  height: auto;
}

.v2-nav {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.v2-nav-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.v2-nav-link {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  text-decoration: none;
  color: var(--v2-text);
  font-weight: 700;
}

.v2-nav-link:hover { background: #eef3fa; }
.v2-nav-link.is-active {
  background: var(--v2-brand-blue);
  color: #fff;
}

.v2-submenu {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-left: 8px;
  border-left: 2px solid #cfd8e3;
  padding-left: 10px;
}

.v2-submenu-link {
  text-decoration: none;
  color: var(--v2-muted);
  border-radius: 8px;
  padding: 8px 10px;
  font-weight: 600;
}

.v2-submenu-link:hover { background: #ecf2fa; }
.v2-submenu-link.is-active {
  color: var(--v2-brand-blue-deep);
  background: #e7f1ff;
}

.v2-main {
  padding: 24px;
}

.v2-actions {
  margin-bottom: 14px;
}

.v2-page-header {
  margin-bottom: 18px;
}

.v2-page-header h1 {
  margin: 0;
  font-size: 34px;
  line-height: 1.1;
}

.v2-page-header p {
  margin: 8px 0 0;
  color: var(--v2-muted);
}

.v2-breadcrumbs {
  margin-bottom: 12px;
  color: var(--v2-muted);
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.v2-breadcrumbs a {
  color: var(--v2-brand-blue-deep);
  text-decoration: none;
}

.v2-breadcrumbs a:hover {
  text-decoration: underline;
}

.v2-section-title {
  margin: 0 0 10px;
  font-size: 24px;
}

.v2-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.v2-stack {
  display: grid;
  gap: 10px;
}

.v2-card {
  background: var(--v2-surface);
  border: 1px solid var(--v2-line);
  border-radius: 18px;
  padding: 16px;
}

.v2-card--accent {
  border-color: #b9d3f4;
  box-shadow: inset 0 0 0 1px rgba(0, 123, 229, 0.08);
  background:
    linear-gradient(180deg, rgba(231, 241, 255, 0.55) 0%, rgba(255, 255, 255, 1) 34%);
}

.v2-card--subtle {
  background: #f8fafc;
  border-color: #dfe6ef;
}

.v2-table-wrap {
  overflow: auto;
}

.v2-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 980px;
}

.v2-table th,
.v2-table td {
  text-align: left;
  padding: 12px;
  border-bottom: 1px solid #e7ebf2;
  vertical-align: middle;
}

.v2-table--compact {
  min-width: 0;
}

.v2-table--compact th,
.v2-table--compact td {
  padding: 10px 12px;
}

.v2-table th {
  font-size: 13px;
  color: #4f5967;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.v2-th-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 6px;
}

.v2-th-actions {
  display: inline-flex;
  gap: 6px;
  position: relative;
}

.v2-sort-btn {
  border: 1px solid #cfd8e5;
  background: #f7faff;
  border-radius: 6px;
  min-width: 28px;
  height: 28px;
  cursor: pointer;
}

.v2-filter-btn {
  border: 1px solid #cfd8e5;
  background: #f7faff;
  border-radius: 6px;
  min-width: 28px;
  height: 28px;
  cursor: pointer;
}

.v2-filter-btn.is-active {
  border-color: #8cb4e8;
  background: #e7f1ff;
  color: #00559f;
}

.v2-native-filter {
  position: absolute;
  right: 0;
  top: 0;
  width: 28px;
  height: 28px;
  opacity: 0;
  pointer-events: auto;
  z-index: 2;
}

.v2-filter-select {
  width: 100%;
  border: 1px solid #d5ddea;
  border-radius: 8px;
  min-height: 32px;
  font: inherit;
}

.v2-link {
  color: var(--v2-brand-blue-deep);
  font-weight: 700;
  text-decoration: none;
}

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

.v2-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  min-height: 42px;
  padding: 0 18px;
  font-weight: 800;
  cursor: pointer;
}

.v2-btn--primary {
  background: var(--v2-brand-red);
  color: #fff;
}

.v2-btn--primary:hover {
  background: #a90000;
}

.v2-btn--ghost {
  background: #fff;
  color: #2f3a48;
  border: 1px solid #d5ddea;
}

.v2-btn--ghost:hover {
  background: #f4f8ff;
}

.v2-search-form {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) auto auto;
  gap: 10px;
  align-items: center;
}

.v2-search-form input {
  width: 100%;
  border: 1px solid #d5ddea;
  border-radius: 10px;
  min-height: 42px;
  padding: 9px 10px;
  font: inherit;
}

.v2-search-form select {
  width: 100%;
  border: 1px solid #d5ddea;
  border-radius: 10px;
  min-height: 42px;
  padding: 9px 10px;
  font: inherit;
  background: #fff;
}

.v2-advanced-search {
  margin-top: 10px;
  display: inline-grid;
  gap: 6px;
}

.v2-advanced-search select {
  min-width: 240px;
  border: 1px solid #d5ddea;
  border-radius: 10px;
  min-height: 42px;
  padding: 8px 10px;
  font: inherit;
}

.is-hidden {
  display: none !important;
}

.v2-status {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 700;
}

.v2-status--plan {
  color: #704f00;
  background: #fff4d6;
}

.v2-status--live {
  color: #0f6a2c;
  background: #ddf7e5;
}

.v2-status--done {
  color: #7f2020;
  background: #fde2e2;
}

.v2-status--track-neutral {
  color: #596273;
  background: #edf1f7;
}

.v2-status--track-progress {
  color: #7a4f00;
  background: #ffe8bd;
}

.v2-status--track-live {
  color: #0f6a2c;
  background: #ddf7e5;
}

.v2-status--track-report {
  color: #3e4d91;
  background: #e4e9ff;
}

.v2-status--track-done {
  color: #1f6f42;
  background: #d5f5e3;
}

.v2-status--track-cancel {
  color: #8a1f2a;
  background: #ffe0e3;
}

.v2-empty {
  color: var(--v2-muted);
  margin: 8px 0;
}

.v2-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.v2-field {
  padding: 10px 0;
  border-bottom: 1px solid #eef2f7;
}

.v2-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 33, 0.45);
  display: grid;
  place-items: center;
  padding: 16px;
  z-index: 40;
}

.v2-modal-backdrop[hidden] {
  display: none;
}

.v2-modal {
  width: min(860px, 100%);
  max-height: calc(100vh - 36px);
  overflow: auto;
  background: #fff;
  border-radius: 20px;
  border: 1px solid #d9e0ea;
  padding: 16px;
}

.v2-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.v2-modal-head h2 {
  margin: 0;
  font-size: 26px;
}

.v2-icon-btn {
  border: 0;
  background: #eef3fa;
  color: #2c3645;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  font-size: 24px;
  cursor: pointer;
}

.v2-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.v2-form-grid input,
.v2-form-grid select,
.v2-form-grid textarea,
.v2-form-grid button {
  width: 100%;
  border: 1px solid #d5ddea;
  border-radius: 10px;
  min-height: 42px;
  padding: 9px 10px;
  font: inherit;
}

.v2-form-grid input[type="checkbox"] {
  width: 18px;
  min-height: 18px;
  height: 18px;
  padding: 0;
  border: 0;
  border-radius: 4px;
}

.v2-inline-form {
  display: flex;
  gap: 8px;
  align-items: center;
}

.v2-inline-form select {
  min-width: 180px;
}

.v2-inline-status-select {
  min-width: 190px;
  border: 1px solid #d5ddea;
  border-radius: 8px;
  min-height: 34px;
  padding: 6px 8px;
  font: inherit;
}

.v2-status-inline-trigger {
  cursor: pointer;
}

.v2-status-inline-form {
  display: inline-block;
  margin-left: 8px;
}

.v2-status-inline-form select {
  min-height: 30px;
  border: 1px solid #d5ddea;
  border-radius: 8px;
  padding: 4px 8px;
  font: inherit;
}

.v2-inline-form .v2-btn {
  min-height: 34px;
  padding: 0 12px;
}

.v2-form-grid textarea {
  min-height: 88px;
  resize: vertical;
}

.v2-form-grid textarea,
.v2-form-grid button,
.v2-smart-select {
  grid-column: 1 / -1;
}

body.v2-modal-open {
  overflow: hidden;
}

.v2-smart-select {
  display: grid;
  gap: 8px;
  position: relative;
}

.v2-smart-select__results {
  border: 1px solid #d8e0ec;
  border-radius: 10px;
  padding: 8px;
  display: grid;
  gap: 6px;
  max-height: 220px;
  overflow: auto;
  background: #fbfdff;
}

.v2-smart-select__results[hidden] {
  display: none;
}

.v2-sector-item {
  text-align: left;
  background: #fff;
  border: 1px solid #d6dfec;
  border-radius: 8px;
  padding: 8px 10px;
  cursor: pointer;
}

.v2-sector-item:hover {
  border-color: #adc5e6;
  background: #f3f8ff;
}

.v2-sector-item--add {
  border-style: dashed;
  font-weight: 700;
  color: #00559f;
}

.v2-smart-select__selected {
  font-size: 14px;
  color: #4f5967;
}

.v2-responsibles-label {
  grid-column: 1 / -1;
  font-weight: 700;
}

.v2-responsibles-picker {
  grid-column: 1 / -1;
  border: 1px solid #d5ddea;
  border-radius: 10px;
  background: #fff;
}

.v2-responsibles-summary {
  list-style: none;
  cursor: pointer;
  min-height: 42px;
  padding: 9px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.v2-responsibles-summary::-webkit-details-marker {
  display: none;
}

.v2-responsibles-summary::before {
  content: "▾";
  color: #5a6470;
  font-size: 14px;
}

.v2-responsibles-picker[open] .v2-responsibles-summary::before {
  content: "▴";
}

.v2-responsibles-list {
  border-top: 1px solid #e7ebf2;
  max-height: 220px;
  overflow: auto;
  padding: 8px 10px;
  display: grid;
  gap: 8px;
}

.v2-responsible-option {
  display: flex;
  align-items: center;
  gap: 8px;
}

.v2-register-body {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(0, 123, 229, 0.12), transparent 32%),
    linear-gradient(180deg, #f4f7fb 0%, #eef3f9 100%);
}

.v2-register-shell {
  width: min(1080px, calc(100% - 32px));
  margin: 0 auto;
  padding: 40px 0 56px;
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.v2-register-hero {
  padding: 16px 8px;
}

.v2-register-kicker {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--v2-brand-blue-deep);
}

.v2-register-hero h1 {
  margin: 0;
  font-size: 42px;
  line-height: 0.98;
}

.v2-register-text {
  margin: 12px 0 0;
  color: var(--v2-muted);
  font-size: 16px;
  line-height: 1.5;
}

.v2-register-event {
  margin-top: 18px;
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid #d8dde5;
  display: grid;
  gap: 6px;
}

.v2-register-card {
  padding: 24px;
}

.v2-register-alert {
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 14px;
  font-weight: 700;
}

.v2-register-alert--success {
  color: #17633a;
  background: #e3f7ea;
}

.v2-register-alert--error {
  color: #8b1e2d;
  background: #fde6ea;
}

.v2-duplicate-banner {
  display: grid;
  gap: 4px;
  border-radius: 16px;
  padding: 14px 16px;
  background: #e8f6ee;
  color: #17633a;
}

.v2-duplicate-banner--warning {
  background: #fff3cf;
  color: #7a4f00;
}

.v2-linked-company-details {
  margin-top: 8px;
  border: 1px solid #dbe3ed;
  border-radius: 16px;
  background: #fbfcfe;
}

.v2-linked-company-summary {
  list-style: none;
  cursor: pointer;
  min-height: 48px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  font-weight: 700;
}

.v2-linked-company-summary::-webkit-details-marker {
  display: none;
}

.v2-linked-company-summary::before {
  content: "▾";
  color: #5a6470;
  font-size: 14px;
  margin-right: 8px;
}

.v2-linked-company-details[open] .v2-linked-company-summary::before {
  content: "▴";
}

.v2-linked-company-summary span:first-child {
  display: flex;
  align-items: center;
  gap: 8px;
}

.v2-linked-company-summary span:last-child {
  color: #5a6470;
  font-weight: 600;
}

.v2-linked-company-panel {
  border-top: 1px solid #e7ebf2;
  padding: 0 14px 14px;
}

.v2-linked-company-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 16px;
}

.v2-register-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.v2-register-form label {
  display: grid;
  gap: 8px;
  font-weight: 700;
}

.v2-register-form input {
  width: 100%;
  min-height: 56px;
  border: 1px solid #d5ddea;
  border-radius: 20px;
  padding: 12px 16px;
  background: #f6f7f9;
  font: inherit;
}

.v2-register-form button {
  grid-column: 1 / -1;
  margin-top: 8px;
}

@media (max-width: 1024px) {
  .v2-shell {
    grid-template-columns: 1fr;
  }

  .v2-sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--v2-line);
  }

  .v2-grid {
    grid-template-columns: 1fr;
  }

  .v2-form-grid {
    grid-template-columns: 1fr;
  }

  .v2-search-form {
    grid-template-columns: 1fr;
  }

  .v2-register-shell {
    grid-template-columns: 1fr;
  }

  .v2-register-form {
    grid-template-columns: 1fr;
  }
}
