@import url('xselect.css');

.field-row {
	display: grid;
	grid-template-columns: 110px minmax(220px, 320px);
	align-items: center;
	gap: 12px;
	margin-bottom: 12px;
}

.field-row label {
	color: var(--color-text);
	text-align: right;
	font-size: 0.95rem;
}

input,
select,
textarea {
	width: 100%;
	border: 1px solid rgba(255,255,255,0.2);
	border-radius: var(--radius-sm);
	color: var(--color-text);
	background: rgba(255,255,255,0.055);
	outline: none;
	transition:
		border-color 0.18s ease,
		background 0.18s ease,
		box-shadow 0.18s ease;
}

input,
select {
	min-height: 36px;
	padding: 0 10px;
}

select {
    width: 100%;
    min-height: 42px;
    padding: 0.65rem 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.025)),
        rgba(10, 10, 10, 0.92);
    color: #fff;
    outline: none;
}

select:focus {
    border-color: rgba(255, 255, 255, 0.42);
}

textarea {
	min-height: 96px;
	resize: vertical;
	padding: 14px;
}

input:focus,
select:focus,
textarea:focus {
	border-color: rgba(255,255,255,0.56);
	box-shadow: 0 0 0 4px rgba(255,255,255,0.08);
}

select option {
	color: var(--color-text);
}


select option::after
{
	width: 100%;
	height: .1rem;
	background-color: #dc2626;
}

.date-field {
	display: grid;
	grid-template-columns: 1fr 38px;
	gap: 8px;
}

.icon-button {
	border: 1px solid rgba(255,255,255,0.2);
	border-radius: var(--radius-sm);
	background: rgba(255,255,255,0.07);
	color: var(--color-text);
}

.icon-button:hover {
	background: rgba(255,255,255,0.13);
}

.button {
	width: min(100%, 420px);
	min-height: 38px;
	border: 0;
	border-radius: var(--radius-sm);
	color: white;
	font-weight: 500;
}

.button-primary {
	background: linear-gradient(135deg, var(--color-green), #08752d);
}

.button-primary:hover {
	background: linear-gradient(135deg, var(--color-green-hover), var(--color-green));
}

.mini-actions {
	display: flex;
	gap: 8px;
	margin-top: 10px;
}

.mini-button {
	width: 30px;
	height: 28px;
	border: 0;
	border-radius: 7px;
	color: white;
	font-weight: 700;
}

.mini-button.add {
	background: var(--color-green);
}

.mini-button.add:hover {
	background: var(--color-green-hover);
}

.mini-button.remove {
	background: var(--color-red);
}

.mini-button.remove:hover {
	background: var(--color-red-hover);
}

.toast {
	position: fixed;
	right: 22px;
	bottom: 22px;
	max-width: min(420px, calc(100vw - 44px));
	padding: 14px 18px;
	border: 1px solid rgba(255,255,255,0.18);
	border-radius: var(--radius-md);
	color: var(--color-text);
	background: rgba(8, 10, 14, 0.92);
	box-shadow: var(--shadow-panel);
	opacity: 0;
	transform: translateY(16px);
	pointer-events: none;
	transition: opacity 0.22s ease, transform 0.22s ease;
	z-index: 20;
}

.toast.visible {
	opacity: 1;
	transform: translateY(0);
}

.toast.success {
	border-color: rgba(24, 182, 83, 0.45);
}

.toast.error {
	border-color: rgba(220, 38, 38, 0.55);
}

@media (max-width: 640px) {
	.field-row {
		grid-template-columns: 1fr;
	}

	.field-row label {
		text-align: left;
	}
}

.date-picker-wrapper {
  position: relative;
}

.calendar-popover {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 292px;
  padding: 14px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: var(--radius-md);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03)),
    rgba(7, 9, 13, 0.98);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(18px);
  z-index: 50;
}

.calendar-popover::before {
  content: "";
  position: absolute;
  top: -7px;
  right: 14px;
  width: 12px;
  height: 12px;
  transform: rotate(45deg);
  border-left: 1px solid rgba(255,255,255,0.18);
  border-top: 1px solid rgba(255,255,255,0.18);
  background: rgba(7, 9, 13, 0.98);
}

.calendar-header {
  display: grid;
  grid-template-columns: 34px 1fr 34px;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.calendar-header strong {
  text-align: center;
  font-size: 0.92rem;
  font-weight: 600;
  text-transform: capitalize;
}

.calendar-nav-button {
  width: 34px;
  height: 32px;
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: 8px;
  color: var(--color-text);
  background: rgba(255,255,255,0.06);
}

.calendar-nav-button:hover {
  background: rgba(255,255,255,0.13);
}

.calendar-weekdays,
.calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.calendar-weekdays {
  margin-bottom: 8px;
}

.calendar-weekdays span {
  color: var(--color-muted);
  font-size: 0.72rem;
  text-align: center;
}

.calendar-day {
  height: 32px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--color-text);
  background: transparent;
  font-size: 0.82rem;
}

.calendar-day:hover {
  border-color: rgba(255,255,255,0.22);
  background: rgba(255,255,255,0.1);
}

.calendar-day.is-today {
  border-color: rgba(255,255,255,0.45);
}

.calendar-day.is-selected {
  color: #020204;
  background: #ffffff;
}

.calendar-day.is-outside {
  color: rgba(255,255,255,0.28);
}

@media (max-width: 460px) {
  .calendar-popover {
    right: auto;
    left: 0;
    width: min(292px, calc(100vw - 48px));
  }

  .calendar-popover::before {
    right: auto;
    left: 50%;
  }
}

.project-status-archive
{
	color: var(--color-muted);
}

.project-status-termine
{
	text-decoration: line-through;
}


.hours-separator {
    width: 100%;
    margin: 2rem 0;
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.other-hours-section {
    width: 100%;
    margin-top: 1rem;
}

.other-hours-header {
    margin-bottom: 1.25rem;
}

.other-hours-header h2 {
    margin: 0;
    font-size: clamp(1.15rem, 2vw, 1.6rem);
    font-weight: 600;
    letter-spacing: -0.03em;
    color: #f5f5f5;
}

.other-hours-header p {
    margin: 0.35rem 0 0;
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.95rem;
}

.other-hours-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}

.other-hours-card {
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.025)),
        rgba(10, 10, 10, 0.9);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(14px);
}

.other-hours-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.other-hours-user {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    min-width: 0;
}

.other-hours-avatar {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    background: #f5f5f5;
    color: #050505;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.04em;
    flex: 0 0 auto;
}

.other-hours-user strong {
    display: block;
    color: #fff;
    font-size: 0.98rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.other-hours-user span {
    display: block;
    margin-top: 0.1rem;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.other-hours-total {
    padding: 0.45rem 0.7rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-weight: 700;
    white-space: nowrap;
}

.other-hours-details {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.other-hours-row {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.other-hours-project,
.other-hours-task {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.other-hours-project {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.other-hours-task {
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.9rem;
}

.other-hours-row-total {
    color: #fff;
    font-weight: 700;
    white-space: nowrap;
}

.other-hours-comments {
    margin: 1rem 0 0;
    padding-top: 0.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.65);
    font-size: 0.9rem;
    line-height: 1.45;
}

.other-hours-empty {
    padding: 1rem;
    border: 1px dashed rgba(255, 255, 255, 0.16);
    border-radius: 16px;
    color: rgba(255, 255, 255, 0.62);
    background: rgba(255, 255, 255, 0.035);
}

.other-hours-empty-error {
    color: #ffb4b4;
    border-color: rgba(255, 100, 100, 0.35);
    background: rgba(255, 50, 50, 0.08);
}

@media (max-width: 720px) {
    .other-hours-list {
        grid-template-columns: 1fr;
    }

    .other-hours-card {
        border-radius: 14px;
    }

    .other-hours-row {
        grid-template-columns: 1fr auto;
        grid-template-areas:
            "project hours"
            "task hours";
        gap: 0.2rem 0.75rem;
    }

    .other-hours-project {
        grid-area: project;
    }

    .other-hours-task {
        grid-area: task;
    }

    .other-hours-row-total {
        grid-area: hours;
    }
}

