.profile-projects-page {
  width: min(1320px, 100%);
  padding-block: clamp(28px, 4.4vw, 58px) 110px;
}

.profile-projects-hero {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 24px;
}

.profile-projects-hero > div:first-child {
  min-width: 0;
}

.profile-projects-hero h1 {
  margin: 5px 0 0;
  font-family: var(--font-display);
  font-size: clamp(2.55rem, 5.6vw, 5rem);
  font-weight: 650;
  letter-spacing: -0.072em;
  line-height: 0.94;
}

.profile-projects-hero > div:first-child > p:last-child {
  max-width: 69ch;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.6;
}

.profile-projects-now {
  display: flex;
  min-width: min(100%, 310px);
  align-items: center;
  gap: 14px;
  padding: 15px 18px;
  border: 1px solid color-mix(in srgb, var(--line) 72%, transparent);
  border-radius: 20px;
  background: color-mix(in srgb, var(--surface-raised) 88%, transparent);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(22px) saturate(1.18);
  -webkit-backdrop-filter: blur(22px) saturate(1.18);
}

.profile-projects-now > .material-symbols-outlined {
  display: grid;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  place-items: center;
  border-radius: 15px;
  background: linear-gradient(145deg, rgba(0, 113, 227, 0.14), rgba(128, 104, 216, 0.14));
  color: var(--sapphire);
  font-size: 1.35rem;
}

.profile-projects-now div {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.profile-projects-now small,
.profile-section-heading small,
.profile-create-card > small,
.profile-invite-card > small,
.profile-privacy-card > small,
.profile-invitations header small {
  color: var(--violet-deep);
  font-size: 0.59rem;
  font-weight: 850;
  letter-spacing: 0.14em;
}

.profile-projects-now time {
  overflow: hidden;
  color: var(--text);
  font-size: 0.8rem;
  font-weight: 760;
  text-overflow: ellipsis;
  text-transform: capitalize;
  white-space: nowrap;
}

.profile-projects-now strong {
  color: var(--muted);
  font: 700 0.71rem/1.2 var(--font-mono);
}

.profile-projects-notice {
  margin: 0 0 14px;
  padding: 13px 16px;
  border: 1px solid color-mix(in srgb, currentcolor 18%, transparent);
  border-radius: 14px;
  background: color-mix(in srgb, currentcolor 6%, var(--surface-raised));
  font-size: 0.76rem;
  font-weight: 700;
}

.profile-projects-notice.is-success,
.profile-save-status .is-success {
  color: var(--success);
}

.profile-projects-notice.is-error,
.profile-save-status .is-error,
.profile-inline-error {
  color: var(--error);
}

.profile-projects-workbench {
  min-height: 680px;
  border-color: color-mix(in srgb, var(--line) 72%, transparent);
  border-radius: 30px;
  background: color-mix(in srgb, var(--surface-raised) 88%, transparent);
  box-shadow: var(--shadow);
  backdrop-filter: blur(28px) saturate(1.15);
  -webkit-backdrop-filter: blur(28px) saturate(1.15);
}

.profile-projects-toolbar {
  display: flex;
  min-height: 74px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 10px 13px 10px 18px;
  border-bottom: 1px solid var(--line-soft);
  background: color-mix(in srgb, var(--surface-subtle) 55%, transparent);
}

.profile-projects-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
}

.profile-projects-tabs button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 15px;
  border: 0;
  border-radius: 15px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 780;
}

.profile-projects-tabs button:hover:not(:disabled) {
  background: color-mix(in srgb, var(--surface-raised) 76%, transparent);
  color: var(--text-soft);
}

.profile-projects-tabs button.is-active {
  background: var(--surface-raised);
  color: var(--sapphire);
  box-shadow: 0 5px 18px rgba(29, 62, 118, 0.1);
}

.profile-projects-tabs button:disabled:not(.is-active) {
  opacity: 0.36;
}

.profile-projects-tabs .material-symbols-outlined {
  font-size: 1.1rem;
}

.profile-project-picker {
  display: grid;
  min-width: min(100%, 270px);
  gap: 3px;
}

.profile-project-picker > span {
  padding-left: 3px;
  color: var(--muted);
  font-size: 0.52rem;
  font-weight: 850;
  letter-spacing: 0.12em;
}

.profile-project-picker select,
.profile-form-grid input,
.profile-form-grid select,
.profile-form-grid textarea,
.profile-create-card input,
.profile-create-card textarea,
.profile-invite-card input,
.profile-invite-card select,
.profile-team-member select,
.profile-invitation-link input {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--field-bg);
  color: var(--text);
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.profile-create-card textarea,
.profile-form-grid textarea {
  min-height: 86px;
  padding-block: 11px;
  resize: vertical;
}

.profile-project-picker select:focus,
.profile-form-grid input:focus,
.profile-form-grid select:focus,
.profile-form-grid textarea:focus,
.profile-create-card input:focus,
.profile-create-card textarea:focus,
.profile-invite-card input:focus,
.profile-invite-card select:focus,
.profile-team-member select:focus {
  border-color: color-mix(in srgb, var(--sapphire) 58%, var(--line));
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--sapphire) 10%, transparent);
}

.profile-project-picker select:disabled {
  opacity: 0.62;
}

.profile-projects-state {
  display: grid;
  min-height: 430px;
  place-items: center;
  align-content: center;
  gap: 10px;
  padding: 34px;
  text-align: center;
}

.profile-projects-state > .material-symbols-outlined {
  color: var(--error);
  font-size: 2.1rem;
}

.profile-projects-state h2,
.profile-projects-state p {
  margin: 0;
}

.profile-projects-state p {
  max-width: 52ch;
  color: var(--muted);
  font-size: 0.76rem;
}

.profile-today-layout,
.profile-section-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(310px, 0.35fr);
  min-height: 606px;
}

.profile-day-main,
.profile-section-main {
  min-width: 0;
  padding: clamp(20px, 3vw, 38px);
}

.profile-day-header,
.profile-section-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 26px;
}

.profile-day-header small {
  color: var(--violet-deep);
  font-size: 0.59rem;
  font-weight: 850;
  letter-spacing: 0.13em;
}

.profile-day-header h2,
.profile-section-heading h2,
.profile-create-card h2,
.profile-invite-card h2,
.profile-privacy-card h2 {
  margin: 4px 0 0;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 650;
  letter-spacing: -0.045em;
  line-height: 1.04;
}

.profile-day-header p,
.profile-section-heading p,
.profile-create-card > p,
.profile-invite-card > p {
  max-width: 63ch;
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.55;
}

.profile-date-controls {
  display: grid;
  grid-template-columns: 46px auto minmax(136px, auto) 46px;
  overflow: hidden;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: var(--field-bg);
}

.profile-date-controls button,
.profile-date-controls input {
  min-width: 44px;
  min-height: 46px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 760;
}

.profile-date-controls button + button,
.profile-date-controls label,
.profile-date-controls label + button {
  border-left: 1px solid var(--line-soft);
}

.profile-date-controls button:disabled,
.profile-date-controls input:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.profile-date-controls input {
  width: 100%;
  padding-inline: 8px;
}

.profile-count-list {
  gap: 10px;
}

.profile-count-row {
  min-height: 70px;
  border: 1px solid transparent;
  background: color-mix(in srgb, var(--surface-subtle) 84%, transparent);
}

.profile-count-row:focus-within {
  border-color: color-mix(in srgb, var(--sapphire) 24%, transparent);
}

.profile-day-summary {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: center;
  padding: clamp(26px, 3.3vw, 43px);
  border-left: 1px solid var(--line-soft);
  background:
    radial-gradient(circle at 50% 22%, rgba(75, 170, 236, 0.16), transparent 14rem),
    linear-gradient(155deg, color-mix(in srgb, var(--surface-blue) 82%, transparent), color-mix(in srgb, var(--surface-lilac) 78%, transparent));
}

.profile-day-total {
  text-align: center;
}

.profile-day-total small {
  color: var(--violet-deep);
  font-size: 0.62rem;
  font-weight: 880;
  letter-spacing: 0.16em;
}

.profile-day-total output {
  display: block;
  max-width: 100%;
  margin: 18px 0 8px;
  overflow: hidden;
  font-family: var(--font-display);
  font-size: clamp(4.6rem, 9vw, 7.6rem);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.085em;
  line-height: 0.8;
  text-overflow: ellipsis;
}

.profile-day-total span {
  color: var(--muted);
  font-size: 0.73rem;
}

.profile-day-breakdown {
  display: grid;
  gap: 7px;
  margin: 30px 0 0;
}

.profile-day-breakdown > div {
  display: flex;
  min-height: 44px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 13px;
  border-radius: 13px;
  background: color-mix(in srgb, var(--surface-raised) 68%, transparent);
}

.profile-day-breakdown dt {
  color: var(--muted);
  font-size: 0.66rem;
}

.profile-day-breakdown dd {
  margin: 0;
  font: 760 0.76rem/1 var(--font-mono);
}

.profile-day-actions {
  display: grid;
  gap: 8px;
  margin-top: 22px;
}

.profile-day-actions .button,
.profile-create-card .button,
.profile-invite-card .button {
  min-height: 48px;
}

.profile-day-actions .button:disabled,
.profile-create-card .button:disabled,
.profile-invite-card .button:disabled,
.profile-form-actions .button:disabled {
  box-shadow: none;
  opacity: 0.46;
}

.profile-discard-button:disabled {
  display: none;
}

.profile-save-status {
  min-height: 25px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.65rem;
  line-height: 1.45;
}

.profile-save-status p {
  margin: 0;
}

.profile-save-status button {
  min-height: 44px;
  margin-top: 8px;
  padding: 0 12px;
  border: 0;
  border-radius: 11px;
  background: color-mix(in srgb, var(--error) 10%, transparent);
  color: var(--error);
  cursor: pointer;
  font-weight: 750;
}

.profile-empty-state {
  display: grid;
  min-height: 250px;
  place-items: center;
  align-content: center;
  padding: 28px;
  border: 1px dashed color-mix(in srgb, var(--line) 86%, transparent);
  border-radius: 20px;
  text-align: center;
}

.profile-empty-state .material-symbols-outlined {
  color: var(--violet);
  font-size: 2rem;
}

.profile-empty-state h3,
.profile-empty-state p {
  margin: 0;
}

.profile-empty-state p {
  max-width: 42ch;
  color: var(--muted);
  font-size: 0.72rem;
}

.profile-section-count {
  flex: 0 0 auto;
  padding: 8px 11px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--sapphire) 8%, transparent);
  color: var(--sapphire);
  font-size: 0.61rem;
  font-weight: 760;
}

.profile-project-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.profile-project-card {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line-soft);
  border-radius: 20px;
  background: color-mix(in srgb, var(--surface-subtle) 76%, transparent);
  transition: border-color 150ms ease, transform 150ms ease;
}

.profile-project-card.is-selected {
  border-color: color-mix(in srgb, var(--sapphire) 38%, var(--line));
  background: color-mix(in srgb, var(--surface-blue) 76%, var(--surface-raised));
}

.profile-project-card__select {
  display: flex;
  width: 100%;
  min-height: 52px;
  align-items: center;
  gap: 11px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  text-align: left;
}

.profile-project-card__select > .material-symbols-outlined {
  display: grid;
  width: 43px;
  height: 43px;
  flex: 0 0 43px;
  place-items: center;
  border-radius: 13px;
  background: color-mix(in srgb, var(--sapphire) 9%, transparent);
  color: var(--sapphire);
}

.profile-project-card__select > span:last-child {
  display: grid;
  min-width: 0;
}

.profile-project-card__select strong,
.profile-project-card__select small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-project-card__select strong {
  font-size: 0.8rem;
}

.profile-project-card__select small {
  color: var(--muted);
  font-size: 0.62rem;
}

.profile-project-card > p {
  min-height: 2.8em;
  margin: 11px 0;
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.4;
}

.profile-project-card dl {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
  margin: 0;
}

.profile-project-card dl > div {
  display: grid;
  gap: 1px;
  padding: 8px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--surface-raised) 70%, transparent);
}

.profile-project-card dt {
  color: var(--muted);
  font-size: 0.52rem;
}

.profile-project-card dd {
  margin: 0;
  overflow: hidden;
  font-size: 0.62rem;
  font-weight: 730;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-project-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 10px;
  padding-top: 9px;
  border-top: 1px solid var(--line-soft);
}

.profile-project-card__actions button,
.profile-delete-confirm button,
.profile-team-member__remove button,
.profile-invitation-list button,
.profile-invitation-link button {
  min-height: 44px;
  padding: 0 11px;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.65rem;
  font-weight: 730;
}

.profile-project-card__actions button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.profile-project-card__actions .material-symbols-outlined {
  font-size: 1rem;
}

.profile-project-editor {
  margin-top: 16px;
  padding: clamp(18px, 2.4vw, 28px);
  border: 1px solid color-mix(in srgb, var(--sapphire) 20%, var(--line-soft));
  border-radius: 20px;
  background:
    radial-gradient(circle at 94% 3%, rgba(0, 113, 227, 0.09), transparent 13rem),
    color-mix(in srgb, var(--surface-blue) 58%, var(--surface-raised));
}

.profile-project-editor > header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
}

.profile-project-editor > header small {
  color: var(--sapphire);
  font-size: 0.56rem;
  font-weight: 850;
  letter-spacing: 0.14em;
}

.profile-project-editor > header h3,
.profile-project-editor > header p {
  margin: 2px 0 0;
}

.profile-project-editor > header p {
  max-width: 62ch;
  color: var(--muted);
  font-size: 0.67rem;
  line-height: 1.45;
}

.profile-project-editor > header > button {
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  place-items: center;
  border: 0;
  border-radius: 13px;
  background: color-mix(in srgb, var(--surface-raised) 80%, transparent);
  color: var(--muted);
  cursor: pointer;
}

.profile-conflict-status {
  display: grid;
  justify-items: start;
}

.profile-delete-confirm {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid color-mix(in srgb, var(--error) 22%, transparent);
  border-radius: 16px;
  background: color-mix(in srgb, var(--error) 6%, var(--surface-raised));
}

.profile-delete-confirm p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 0.64rem;
}

.profile-delete-confirm > div:last-child {
  display: flex;
  flex: 0 0 auto;
  gap: 6px;
}

.is-danger {
  background: color-mix(in srgb, var(--error) 12%, transparent) !important;
  color: var(--error) !important;
}

.profile-create-card,
.profile-invite-card,
.profile-privacy-card {
  min-width: 0;
  padding: clamp(25px, 3vw, 38px);
  border-left: 1px solid var(--line-soft);
  background:
    radial-gradient(circle at 88% 5%, rgba(128, 104, 216, 0.12), transparent 12rem),
    color-mix(in srgb, var(--surface-lilac) 64%, transparent);
}

.profile-create-card__icon,
.profile-privacy-card > .material-symbols-outlined {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  margin-bottom: 17px;
  border-radius: 15px;
  background: color-mix(in srgb, var(--violet) 11%, transparent);
  color: var(--violet-deep);
}

.profile-create-card label,
.profile-invite-card label,
.profile-form-grid label {
  display: grid;
  min-width: 0;
  gap: 6px;
  margin-top: 14px;
}

.profile-create-card label > span,
.profile-invite-card label > span,
.profile-form-grid label > span {
  color: var(--muted);
  font-size: 0.59rem;
  font-weight: 780;
  letter-spacing: 0.04em;
}

.profile-create-dates {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.profile-create-card > .button,
.profile-invite-card > .button {
  width: 100%;
  margin-top: 18px;
}

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

.profile-form-grid .is-wide {
  grid-column: 1 / -1;
}

.profile-form-grid .is-hidden {
  display: none;
}

.profile-form-grid input[readonly] {
  color: var(--muted);
}

.profile-avatar-large {
  display: grid;
  width: 62px;
  height: 62px;
  flex: 0 0 62px;
  place-items: center;
  border-radius: 21px;
  background: linear-gradient(145deg, var(--sapphire), var(--violet));
  color: #fff;
  box-shadow: 0 12px 30px rgba(49, 91, 171, 0.2);
  font-size: 1.05rem;
  font-weight: 810;
}

.profile-form-actions {
  display: flex;
  min-height: 58px;
  align-items: center;
  gap: 16px;
  margin-top: 23px;
}

.profile-form-actions .profile-save-status {
  margin: 0;
}

.profile-privacy-card ul {
  display: grid;
  gap: 11px;
  margin: 25px 0 0;
  padding: 0;
  list-style: none;
}

.profile-privacy-card li {
  position: relative;
  padding-left: 21px;
  color: var(--text-soft);
  font-size: 0.71rem;
  line-height: 1.45;
}

.profile-privacy-card li::before {
  position: absolute;
  top: 0.43em;
  left: 2px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  content: "";
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--success) 10%, transparent);
}

.profile-team-list {
  display: grid;
  gap: 8px;
}

.profile-team-member {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) minmax(130px, auto) 46px;
  min-height: 70px;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 16px;
  background: color-mix(in srgb, var(--surface-subtle) 78%, transparent);
}

.profile-team-member__avatar {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 14px;
  background: color-mix(in srgb, var(--sapphire) 10%, var(--surface-raised));
  color: var(--sapphire);
  font-size: 0.7rem;
  font-weight: 820;
}

.profile-team-member__identity {
  display: grid;
  min-width: 0;
}

.profile-team-member__identity strong,
.profile-team-member__identity span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-team-member__identity strong {
  font-size: 0.75rem;
}

.profile-team-member__identity span {
  color: var(--muted);
  font-size: 0.62rem;
}

.profile-team-member__identity small {
  margin-top: 2px;
  color: var(--sapphire);
  font-size: 0.5rem;
  font-weight: 820;
  letter-spacing: 0.09em;
}

.profile-team-member__role select {
  min-width: 130px;
}

.profile-role-pill {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--violet) 9%, transparent);
  color: var(--violet-deep);
  font-size: 0.61rem;
  font-weight: 750;
}

.profile-team-member__remove:empty {
  display: none;
}

.profile-team-member__remove .material-symbols-outlined {
  font-size: 1.05rem;
}

.profile-invitations {
  margin-top: 28px;
  padding-top: 23px;
  border-top: 1px solid var(--line-soft);
}

.profile-invitations h3 {
  margin: 2px 0 0;
  font-size: 1rem;
}

.profile-invitations > p {
  color: var(--muted);
  font-size: 0.69rem;
}

.profile-invitation-list {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.profile-invitation-list article {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  min-height: 58px;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 14px;
  background: color-mix(in srgb, var(--surface-subtle) 78%, transparent);
}

.profile-invitation-list article > .material-symbols-outlined {
  color: var(--violet);
}

.profile-invitation-list article > div {
  display: grid;
  min-width: 0;
}

.profile-invitation-list strong,
.profile-invitation-list small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-invitation-list strong {
  font-size: 0.7rem;
}

.profile-invitation-list small {
  color: var(--muted);
  font-size: 0.59rem;
}

.profile-permission-note {
  display: flex;
  align-items: start;
  gap: 10px;
  margin-top: 22px;
  padding: 14px;
  border-radius: 15px;
  background: color-mix(in srgb, var(--surface-raised) 70%, transparent);
}

.profile-permission-note p {
  margin: 0;
  color: var(--muted);
  font-size: 0.69rem;
}

.profile-invitation-link {
  display: grid;
  gap: 8px;
  margin-top: 15px;
  padding: 13px;
  border: 1px solid color-mix(in srgb, var(--success) 24%, transparent);
  border-radius: 16px;
  background: color-mix(in srgb, var(--success) 6%, var(--surface-raised));
}

.profile-invitation-link > div:first-child {
  display: grid;
}

.profile-invitation-link strong {
  font-size: 0.68rem;
}

.profile-invitation-link span,
.profile-invitation-link small {
  color: var(--muted);
  font-size: 0.58rem;
}

.profile-invitation-link label {
  margin: 0;
}

.profile-invitation-link input {
  font: 0.61rem/1.2 var(--font-mono);
}

.profile-invitation-link > div:nth-of-type(2) {
  display: flex;
  gap: 6px;
}

.profile-invitation-link button:first-child {
  background: color-mix(in srgb, var(--success) 13%, transparent);
  color: var(--success);
}

.profile-inline-error {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--error) 7%, transparent);
  font-size: 0.67rem;
}

.profile-projects-security-note {
  display: flex;
  max-width: 880px;
  align-items: start;
  gap: 9px;
  margin: 17px auto 0;
  color: var(--muted);
  font-size: 0.64rem;
  line-height: 1.5;
  text-align: center;
}

.profile-projects-security-note .material-symbols-outlined {
  flex: 0 0 auto;
  color: var(--success);
  font-size: 1rem;
}

@media (max-width: 1080px) {
  .profile-projects-toolbar {
    align-items: stretch;
    flex-direction: column-reverse;
    gap: 8px;
  }

  .profile-project-picker {
    width: 100%;
    max-width: none;
  }

  .profile-projects-tabs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
  }

  .profile-today-layout,
  .profile-section-layout {
    grid-template-columns: 1fr;
  }

  .profile-day-summary,
  .profile-create-card,
  .profile-invite-card,
  .profile-privacy-card {
    border-top: 1px solid var(--line-soft);
    border-left: 0;
  }

  .profile-day-summary {
    display: grid;
    grid-template-columns: minmax(240px, 0.7fr) minmax(220px, 1fr);
    gap: 25px;
  }

  .profile-day-total {
    align-self: center;
  }

  .profile-day-breakdown,
  .profile-day-actions {
    margin-top: 0;
  }

  .profile-save-status {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .profile-projects-hero {
    align-items: stretch;
    flex-direction: column;
    gap: 18px;
  }

  .profile-projects-now {
    width: 100%;
  }

  .profile-day-header,
  .profile-section-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .profile-date-controls {
    width: 100%;
    grid-template-columns: 46px 72px minmax(130px, 1fr) 46px;
  }

  .profile-project-card-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  body:has(.profile-projects-page) .site-header,
  body:has(.profile-projects-page) .site-footer {
    display: none;
  }

  .profile-projects-page.container {
    width: 100%;
    padding: 0 max(0px, var(--safe-right)) calc(86px + var(--safe-bottom)) max(0px, var(--safe-left));
  }

  .profile-projects-hero {
    gap: 13px;
    padding: 20px 16px 15px;
    margin: 0;
  }

  .profile-projects-hero h1 {
    font-size: 2.45rem;
  }

  .profile-projects-hero > div:first-child > p:last-child {
    margin-top: 10px;
    font-size: 0.75rem;
  }

  .profile-projects-now {
    min-width: 0;
    padding: 11px 12px;
    border-radius: 17px;
    box-shadow: none;
  }

  .profile-projects-now > .material-symbols-outlined {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
  }

  .profile-projects-notice {
    margin-inline: 12px;
  }

  .profile-projects-workbench {
    min-height: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .profile-projects-toolbar {
    position: sticky;
    z-index: 20;
    top: 0;
    padding: 9px 10px;
    background: color-mix(in srgb, var(--surface-raised) 90%, transparent);
    backdrop-filter: blur(22px) saturate(1.18);
    -webkit-backdrop-filter: blur(22px) saturate(1.18);
  }

  .profile-projects-tabs {
    gap: 3px;
  }

  .profile-projects-tabs button {
    min-width: 0;
    min-height: 52px;
    gap: 1px;
    flex-direction: column;
    padding: 3px 2px;
    border-radius: 13px;
    font-size: 0.58rem;
  }

  .profile-projects-tabs .material-symbols-outlined {
    font-size: 1.15rem;
  }

  .profile-project-picker select,
  .profile-form-grid input,
  .profile-form-grid select,
  .profile-form-grid textarea,
  .profile-create-card input,
  .profile-create-card textarea,
  .profile-invite-card input,
  .profile-invite-card select,
  .profile-team-member select,
  .profile-invitation-link input,
  .profile-date-controls input {
    font-size: 16px;
  }

  .profile-day-main,
  .profile-section-main,
  .profile-create-card,
  .profile-invite-card,
  .profile-privacy-card {
    padding: 18px 13px;
  }

  .profile-day-header,
  .profile-section-heading {
    gap: 14px;
    margin-bottom: 18px;
  }

  .profile-date-controls {
    grid-template-columns: 46px 70px minmax(0, 1fr) 46px;
  }

  .profile-date-controls input {
    min-width: 0;
    padding-inline: 4px;
  }

  .profile-count-row {
    grid-template-columns: 1fr 44px;
    gap: 5px;
    padding: 10px;
  }

  .profile-count-row > label:first-child {
    grid-column: 1;
  }

  .profile-count-row .project-counter-stepper {
    grid-column: 1 / -1;
    grid-row: 2;
    grid-template-columns: 1fr 82px 1fr 58px;
    width: 100%;
  }

  .profile-count-row .project-counter-row__remove {
    grid-column: 2;
    grid-row: 1;
  }

  .profile-day-summary {
    display: flex;
    padding: 35px 17px;
  }

  .profile-day-total output {
    font-size: 5.6rem;
  }

  .profile-day-breakdown {
    width: 100%;
    margin-top: 25px;
  }

  .profile-day-actions {
    width: 100%;
    margin-top: 18px;
  }

  .profile-project-card dl {
    grid-template-columns: 1fr;
  }

  .profile-project-card > p {
    min-height: 0;
  }

  .profile-delete-confirm {
    align-items: stretch;
    flex-direction: column;
  }

  .profile-delete-confirm > div:last-child {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .profile-form-grid,
  .profile-create-dates {
    grid-template-columns: 1fr;
  }

  .profile-form-grid .is-wide {
    grid-column: auto;
  }

  .profile-form-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .profile-project-card__actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .profile-project-card__actions button {
    justify-content: center;
    min-height: 44px;
  }

  .profile-team-member {
    grid-template-columns: 46px minmax(0, 1fr) 44px;
  }

  .profile-team-member__role {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .profile-team-member__role select,
  .profile-role-pill {
    width: 100%;
  }

  .profile-team-member__remove {
    grid-column: 3;
    grid-row: 1;
  }

  .profile-invitation-list article {
    grid-template-columns: 35px minmax(0, 1fr);
  }

  .profile-invitation-list article > button,
  .profile-invitation-list article > :last-child:not(div) {
    grid-column: 1 / -1;
  }

  .profile-invitation-list button {
    width: 100%;
  }

  .profile-projects-security-note {
    padding-inline: 14px;
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  .profile-project-card,
  .profile-projects-tabs button {
    transition: none;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .profile-projects-now,
  .profile-projects-workbench,
  .profile-projects-toolbar {
    background: var(--surface-strong);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}

@media (prefers-contrast: more) {
  .profile-project-card,
  .profile-projects-workbench,
  .profile-project-picker select,
  .profile-form-grid input,
  .profile-form-grid textarea,
  .profile-create-card input,
  .profile-invite-card input {
    border-color: currentcolor;
  }
}
