:root {
  --bg: #e9e9e7;
  --card: #f7f7f7;
  --panel: #f5f5f5;
  --line: #d7d7d7;
  --text: #1f2430;
  --muted: #5e6470;
  --primary: #1f5fe3;
  --primary-dark: #124cc5;
  --shadow: rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--text);
}

button,
input,
select {
  font: inherit;
}

.page-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.top-bar {
  height: 46px;
  background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  display: flex;
  align-items: center;
  padding: 0 14px;
  gap: 12px;
}

.browser-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 84px;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
}

.dot.red { background: #eb5d57; }
.dot.yellow { background: #f4bf4f; }
.dot.green { background: #61c554; }

.address-bar {
  flex: 1;
  background: rgba(11, 17, 29, 0.04);
  border-radius: 999px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14px;
  color: #3c3f46;
}

.lock {
  opacity: 0.7;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  color: #5a5f6d;
}

.content-wrap {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 28px;
  padding: 44px 20px 30px;
}

.profile-card,
.profiles-panel {
  width: min(100%, 600px);
  background: rgba(255, 255, 255, 0.35);
  border: 1px solid rgba(120, 128, 140, 0.2);
  border-radius: 18px;
  box-shadow: 0 8px 20px var(--shadow);
}

.profile-card {
  padding: 28px 28px 16px;
}

h1 {
  margin: 0 0 8px;
  font-size: clamp(2.1rem, 3vw, 3rem);
  line-height: 1.1;
  text-align: center;
  letter-spacing: -0.04em;
  font-weight: 700;
}

.subtitle {
  margin: 0 0 24px;
  text-align: center;
  font-size: 1.05rem;
  color: var(--muted);
  font-weight: 400;
}

.fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px 16px;
}

.two-col .field-group:last-child:nth-child(odd) {
  grid-column: span 1;
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field-group.full-width {
  margin-top: 4px;
}

label {
  display: block;
  font-size: 0.92rem;
  font-weight: 600;
  color: #2d3440;
}

input,
select {
  width: 100%;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.5);
  color: var(--text);
  padding: 0 14px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input::placeholder {
  color: #9ca3af;
}

input:focus,
select:focus {
  border-color: rgba(31, 95, 227, 0.7);
  box-shadow: 0 0 0 4px rgba(31, 95, 227, 0.1);
}

select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #666 50%),
    linear-gradient(135deg, #666 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.submit-btn {
  width: 100%;
  margin-top: 18px;
  border: none;
  height: 52px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary) 0%, #1e66f0 100%);
  color: #fff;
  font-size: 1.08rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease;
  box-shadow: 0 10px 18px rgba(31, 95, 227, 0.2);
}

.submit-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(31, 95, 227, 0.3);
}

.profiles-panel {
  padding: 18px 18px 10px;
}

.panel-header {
  padding: 8px 8px 12px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.panel-header h2 {
  margin: 0;
  font-size: 1.5rem;
}

.empty-state {
  padding: 16px 8px 10px;
  color: var(--muted);
}

.entries-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 10px 8px 14px;
}

.profile-entry {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(120, 128, 140, 0.2);
  border-radius: 12px;
  padding: 14px 16px;
}

.profile-entry-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}

.profile-entry h3 {
  margin: 0;
  font-size: 1.1rem;
}

.profile-entry .badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(31, 95, 227, 0.12);
  color: var(--primary-dark);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 6px 10px;
}

.profile-entry-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 18px;
  font-size: 0.94rem;
}

.entry-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.entry-row span {
  color: var(--muted);
  font-size: 0.8rem;
}

@media (max-width: 640px) {
  .fields,
  .profile-entry-grid {
    grid-template-columns: 1fr;
  }

  .profile-card,
  .profiles-panel {
    width: min(100%, 480px);
  }

  .profile-card {
    padding-left: 18px;
    padding-right: 18px;
  }

  .address-bar {
    font-size: 12px;
  }
}