/* =========================
   Care Page
========================= */

.pd-care {
	min-height: calc(
		90vh -
		50px -
		var(--petdori-nav-height)
	);
	min-height: calc(
		90dvh -
		50px -
		var(--petdori-nav-height)
	);

	padding-top: 0px;
	background: var(--petdori-surface);
}


/* =========================
   Empty
========================= */

.pd-care-empty {
	padding: 64px 20px;
	text-align: center;
}

.pd-care-empty h1 {
	margin: 0 0 12px;
	font-size: 24px;
	font-weight: 750;
	line-height: 1.45;
	letter-spacing: -0.04em;
}

.pd-care-empty p {
	margin: 0 0 28px;
	color: var(--petdori-text-sub);
	font-size: 14px;
	line-height: 1.6;
}


/* =========================
   Pet Switcher
========================= */

.pd-pet-switcher {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 14px;
	overflow-x: auto;
	padding: 2px 0 4px;
	scrollbar-width: none;
	-webkit-overflow-scrolling: touch;
}

.pd-pet-switcher::-webkit-scrollbar {
	display: none;
}


/* =========================
   Pet Tab
========================= */

.pd-pet-tab {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	gap: 7px;
	min-height: 40px;
	padding: 5px 12px 5px 6px;

	border: 2px solid var(--petdori-border);
	border-radius: 999px;

	background: #F8F9FC;
	color: var(--petdori-text);

	white-space: nowrap;
}


.pd-pet-tab-avatar {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	justify-content: center;

	width: 28px;
	height: 28px;

	overflow: hidden;
	border-radius: 50%;

	background: var(--petdori-surface);
	font-size: 16px;
}


.pd-pet-tab-image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}


.pd-pet-tab-name {
	max-width: 72px;
	overflow: hidden;

	font-size: 13px;
	font-weight: 600;
	line-height: 1;

	text-overflow: ellipsis;
	white-space: nowrap;
}


/* Active Pet */

.pd-pet-tab[aria-current="true"] {
	border-color: var(--petdori-primary);
	background: var(--petdori-secondary);
	color: var(--petdori-primary);
}


.pd-pet-tab[aria-current="true"]
.pd-pet-tab-name {
	font-weight: 700;
}


/* =========================
   Add Pet
========================= */

.pd-pet-add {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	gap: 6px;

	min-height: 40px;
	padding: 5px 12px 5px 8px;

	border: 1px dashed var(--petdori-border);
	border-radius: 999px;

	background: #F8F9FC;
	color: var(--petdori-text-sub);

	font-size: 13px;
	font-weight: 600;
	white-space: nowrap;
}


.pd-pet-add-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;

	width: 24px;
	height: 24px;

	border-radius: 50%;

	background: var(--petdori-surface);
	color: var(--petdori-primary);

	font-size: 18px;
	font-weight: 300;
	line-height: 1;
}


/* =========================
   Profile
========================= */

.pd-care-profile {
	margin-top: 0;
	margin-bottom: 0;
	padding: 18px 14px;
}


.pd-care-greeting {
	margin-bottom: 16px;
}


.pd-care-greeting h1 {
	margin: 0;
	font-size: 19px;
	font-weight: 700;
	line-height: 1.35;
	letter-spacing: -0.045em;
}


.pd-care-profile-body {
	display: flex;
	align-items: center;
	gap: 18px;
}


.pd-care-avatar {
	flex: 0 0 auto;
	width: 88px;
	height: 88px;
}


.pd-care-avatar-image,
.pd-care-avatar-placeholder {
	width: 88px;
	height: 88px;
	border-radius: 28px;
}


.pd-care-avatar-image {
	display: block;
	object-fit: cover;
}


.pd-care-avatar-placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--petdori-secondary);
	font-size: 34px;
}


.pd-care-profile-info {
	min-width: 0;
}


.pd-care-profile-main {
	font-size: 16px;
	line-height: 1.45;
}


.pd-care-profile-main strong {
	font-weight: 750;
}


.pd-care-sex {
	margin-left: 3px;
	color: var(--petdori-primary);
	font-size: 16px;
}


.pd-care-profile-sub {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 5px;
	margin-top: 7px;
	color: var(--petdori-text-sub);
	font-size: 14px;
	line-height: 1.4;
}

.pd-care-dot {
	opacity: 0.6;
}


/* =========================
   Sections
========================= */

.pd-care-section {
	margin-top: 12px;
	padding: 16px 12px;
	border: 1px solid rgba(15, 23, 42, 0.05);
	border-radius: 16px;
	background: var(--petdori-surface);
	box-shadow:
		0 2px 6px rgba(15, 23, 42, 0.04),
		0 8px 20px rgba(15, 23, 42, 0.06);
}

.pd-care-section + .pd-care-section {
	margin-top: 14px;
}

.pd-care-section-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	margin-bottom: 16px;
}


.pd-care-section-head h2 {
	margin: 0;
	font-size: 17px;
	font-weight: 700;
	line-height: 1.4;
	letter-spacing: -0.035em;
}

/* =========================
   Menu Icon
========================= */

.pd-care-row-left {
	display: flex;
	align-items: center;
	gap: 11px;
	min-width: 0;
}

.pd-care-menu-icon {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;

	width: 34px;
	height: 34px;

	border-radius: 10px;
	background: #F8F9FC;

	overflow: hidden;
}

.pd-care-menu-icon img {
	display: block;
	width: 22px;
	height: 22px;
	object-fit: contain;
}

/* =========================
   Activity Row
========================= */

.pd-care-activity-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	min-height: 42px;
	padding-bottom: 12px;
	border-bottom: 1px solid var(--petdori-border);
}


.pd-care-activity-inline {
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
	white-space: nowrap;
}

.pd-care-activity-inline strong {
	font-size: 14px;
	font-weight: 500;
}

.pd-care-activity-inline span {
	color: var(--petdori-text-sub);
	font-size: 13px;
}

.pd-care-start-button {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 66px;
	height: 32px;
	padding: 0 12px;
	border-radius: 999px;
	background: var(--petdori-third);
	color: var(--petdori-third-text);
	border: 1px solid var(--petdori-third-border);
	font-size: 13px;
	font-weight: 700;
}

@media (max-width: 360px) {

	.pd-care-activity-inline {
		gap: 4px;
	}

	.pd-care-activity-inline span {
		font-size: 11px;
	}

}

/* =========================
   Daily Rows
========================= */

.pd-care-simple-list {
	display: grid;
}


.pd-care-simple-row {
	display: grid;
	grid-template-columns:
		minmax(0, 1fr)
		auto;
	align-items: center;
	gap: 14px;
	width: 100%;
	min-height: 44px;
	padding: 0;
	border: 0;
	border-bottom: 1px solid var(--petdori-border);
	background: transparent;
	color: var(--petdori-text);
	text-align: left;
	cursor: pointer;
}


.pd-care-simple-row span {
	font-size: 14px;
	font-weight: 500;
}


.pd-care-simple-row strong {
	color: var(--petdori-text-sub);
	font-size: 13px;
	font-weight: 700;
	text-align: right;
}


/* =========================
   Recommendation
========================= */

.pd-care-recommend {
	display: flex;
	align-items: flex-start;
	gap: 6px;
	margin-top: 12px;
	padding: 13px 14px;
	border-radius: 14px;
	background: var(--petdori-secondary);
}


.pd-care-recommend p {
	margin: 0;
	color: var(--petdori-text-sub);
	font-size: 12px;
	line-height: 1.55;
}


/* =========================
   Extra Schedule
========================= */

.pd-care-extra {
	margin-top: 12px;
}


.pd-care-extra summary {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 38px;
	border-radius: 12px;
	color: var(--petdori-primary);
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	list-style: none;
}


.pd-care-extra summary::-webkit-details-marker {
	display: none;
}


.pd-care-extra[open] summary {
	margin-bottom: 14px;
	background: var(--petdori-secondary);
}


.pd-care-extra-form {
	display: grid;
	gap: 12px;
	padding-top: 2px;
}


.pd-care-extra-form label {
	display: grid;
	gap: 6px;
}


.pd-care-extra-form label > span {
	color: var(--petdori-text-sub);
	font-size: 12px;
	font-weight: 500;
}


.pd-care-extra-form select,
.pd-care-extra-form input {
	width: 100%;
	height: 40px;
	padding: 0 12px;
	border: 1px solid var(--petdori-border);
	border-radius: 4px;
	background: var(--petdori-surface);
	color: var(--petdori-text);
}


.pd-care-extra-date {
	display: grid;
	grid-template-columns:
		1fr 1fr;
	gap: 10px;
}


.pd-care-extra-submit {
	width: 100%;
	height: 42px;
	border: 0;
	border-radius: 4px;
	background: var(--petdori-primary);
	color: var(--petdori-on-primary);
	font-size: 12px;
	font-weight: 500;
}


.pd-care-extra-submit:disabled {
	opacity: 0.45;
}


/* =========================
   Medical Records
========================= */

.pd-care-record-add {
	flex: 0 0 auto;
	min-height: 36px;
	padding: 0 12px;
	border: 0;
	border-radius: 11px;
	background: var(--petdori-secondary);
	color: var(--petdori-primary);
	font-size: 13px;
	font-weight: 700;
	cursor: pointer;
}


.pd-care-record-empty {
	padding: 18px 0 5px;
	color: var(--petdori-text-sub);
	font-size: 13px;
	text-align: center;
}


/* =========================
   Insight
========================= */

.pd-care-section-label {
	margin: 0 0 4px;
	color: var(--petdori-primary);
	font-size: 12px;
	font-weight: 700;
	line-height: 1.4;
}


.pd-care-insight {
	display: grid;
	grid-template-columns:
		42px minmax(0, 1fr);
	align-items: start;
	gap: 14px;
}


.pd-care-insight-mark {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	border-radius: 14px;
	background: var(--petdori-secondary);
	color: var(--petdori-primary);
	font-size: 22px;
}


.pd-care-insight h2 {
	margin: 0 0 7px;
	font-size: 16px;
	font-weight: 750;
	line-height: 1.5;
	letter-spacing: -0.025em;
}


.pd-care-insight p:last-child {
	margin: 0;
	color: var(--petdori-text-sub);
	font-size: 13px;
	line-height: 1.6;
}


/* =========================
   Responsive
========================= */

@media (max-width: 360px) {

	.pd-care {
		padding-left: 14px;
		padding-right: 14px;
	}


	.pd-pet-switcher {
		gap: 4px;
	}


	.pd-care-avatar,
	.pd-care-avatar-image,
	.pd-care-avatar-placeholder {
		width: 80px;
		height: 80px;
	}


	.pd-care-section {
		padding: 20px 16px;
	}

}


/* =========================
   Care Date
========================= */

.pd-care-date {
	margin: 6px 0 14px;
	padding: 0 2px;

	color: var(--petdori-text-sub);
	font-size: 13px;
	font-weight: 600;
	line-height: 1.5;
}


/* =========================
   Greeting
========================= */

.pd-care-greeting {
	margin: 0 0 12px;
}

.pd-care-greeting h1 {
	margin: 0;
	font-size: 19px;
	font-weight: 700;
	line-height: 1.4;
	letter-spacing: -0.035em;
}


/* =========================
   Pet Carousel
========================= */

.pd-care-carousel {
	width: 100%;
	margin-top: 0;
	overflow: hidden;
}

.pd-care-carousel-track {
	display: flex;
	gap: 0;

	overflow-x: auto;
	overflow-y: hidden;

	padding: 0;

	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	-webkit-overflow-scrolling: touch;
	overscroll-behavior-x: contain;
}

.pd-care-carousel-track::-webkit-scrollbar {
	display: none;
}

.pd-care-carousel-slide {
	position: relative;
	flex: 0 0 100%;
	width: 100%;
	min-width: 100%;

	margin: 0 !important;
	padding: 14px 14px 16px;

	scroll-snap-align: start;
	scroll-snap-stop: always;
}

.pd-care-profile-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;

	min-height: 32px;
	margin-bottom: 12px;
}

.pd-care-profile-name {
	font-size: 15px;
	font-weight: 700;
}

.pd-care-profile-actions {
	display: flex;
	align-items: center;
	gap: 8px;
}

.pd-care-profile-add,
.pd-care-profile-edit {
	display: inline-flex;
	align-items: center;
	justify-content: center;

	width: 32px;
	height: 32px;

	padding: 0;
	border: 0;
	border-radius: 8px;

	background: var(--petdori-bg);
	color: var(--petdori-text-sub);
}

.pd-care-profile-add {
	font-size: 20px;
	font-weight: 500;
	line-height: 1;
	text-decoration: none;
}

.pd-care-profile-edit svg {
	width: 17px;
	height: 17px;

	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.pd-care-profile-edit:disabled {
	cursor: default;
	opacity: 0.7;
}

.pd-care-profile-next {
	position: absolute;
	top: 50%;
	right: 12px;
	transform: translateY(-50%);

	display: inline-flex;
	align-items: center;
	justify-content: center;

	width: 36px;
	height: 36px;

	border-radius: 50%;
	background: rgba(248, 249, 252, 0.95);
	box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);

	color: var(--petdori-text);
	font-size: 24px;
	line-height: 1;
	text-decoration: none;
}

/* =========================
   Add Pet Slide
========================= */

.pd-care-carousel-add {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 9px;

	min-height: 200px;
	border-style: dashed;

	color: var(--petdori-primary);
	text-align: center;
}

.pd-care-carousel-add-symbol {
	display: inline-flex;
	align-items: center;
	justify-content: center;

	width: 48px;
	height: 48px;
	border-radius: 50%;

	background: var(--petdori-secondary);
	color: var(--petdori-primary);

	font-size: 30px;
	font-weight: 400;
	line-height: 1;
}

.pd-care-carousel-add strong {
	font-size: 15px;
	font-weight: 700;
}

.pd-care-carousel-add > span:last-child {
	color: var(--petdori-text-sub);
	font-size: 12px;
}


/* =========================
   Titles Outside Cards
========================= */

.pd-care-section-head--outside {
	margin-top: 12px;
	margin-bottom: 0;
	padding: 0 4px;
}

.pd-care-section-head--outside h2 {
	margin: 0;
	font-size: 17px;
	font-weight: 700;
}

.pd-care-section-head--outside + .pd-care-section {
	margin-top: 10px;
}

@media (max-width: 360px) {

	.pd-care-carousel-slide {
		flex: 0 0 100%;
		width: 100%;
		min-width: 100%;
	}

	.pd-care-profile-body {
		gap: 12px;
	}

}


.pd-care [hidden] { display:none !important; }

/* =========================
   Care Dashboard Layout
========================= */

/* Weekly calendar first */

.pd-care-week {
	margin-top: 4px;
	margin-bottom: 10px;
	padding: 4px 0 8px;
}

/* Greeting */

.pd-care-greeting {
	margin: 0 0 14px;
}

/* One main care card */

.pd-care-dashboard {
	overflow: hidden;
	margin: 0;
	padding: 0;
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 18px;
	background: var(--petdori-surface);
	box-shadow:
		0 2px 8px rgba(15, 23, 42, 0.03),
		0 6px 18px rgba(15, 23, 42, 0.04);
}

/* Profile slider inside dashboard */

.pd-care-dashboard .pd-care-carousel {
	width: 100%;
	margin: 0;
	overflow: hidden;
}

.pd-care-dashboard .pd-care-carousel-track {
	gap: 0;
	padding: 0;
}

.pd-care-dashboard .pd-care-carousel-slide {
	position: relative;
	flex: 0 0 100%;
	width: 100%;
	min-width: 100%;
	margin: 0 !important;
	padding: 16px 14px;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	scroll-snap-align: start;
}

.pd-care-dashboard .pd-care-profile-top {
	min-height: 30px;
	margin-bottom: 10px;
}

.pd-care-dashboard .pd-care-profile-body {
	gap: 12px;
	padding-right: 35px;
}

/* Compact avatar */

.pd-care-dashboard .pd-care-avatar,
.pd-care-dashboard .pd-care-avatar-image,
.pd-care-dashboard .pd-care-avatar-placeholder {
	width: 64px;
	height: 64px;
}

.pd-care-dashboard .pd-care-avatar-image,
.pd-care-dashboard .pd-care-avatar-placeholder {
	border-radius: 18px;
}

.pd-care-dashboard .pd-care-avatar-placeholder {
	font-size: 29px;
}

.pd-care-dashboard .pd-care-profile-main {
	font-size: 14px;
}

.pd-care-dashboard .pd-care-profile-sub {
	margin-top: 4px;
	font-size: 12px;
}

.pd-care-dashboard .pd-care-sex {
	font-size: 14px;
}

.pd-care-dashboard .pd-care-profile-next {
	right: 10px;
	width: 32px;
	height: 32px;
	box-shadow: none;
}

/* Daily care belongs to the same card */

.pd-care-dashboard-heading {
	margin: 0 14px;
	padding: 14px 2px 10px;
	border-top: 1px solid var(--petdori-border);
}

.pd-care-dashboard-heading h2 {
	margin: 0;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.4;
}

.pd-care-dashboard-daily {
	margin: 0;
	padding: 0 14px 12px;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
}

/* Avoid duplicate card styling */

.pd-care-dashboard-daily .pd-care-activity-row {
	margin-top: 0;
}

.pd-care-dashboard-daily .pd-care-simple-list {
	margin-top: 0;
}

/* Small screens */

@media (max-width: 360px) {

	.pd-care-dashboard .pd-care-carousel-slide {
		padding: 14px 12px;
	}

	.pd-care-dashboard .pd-care-profile-body {
		gap: 10px;
		padding-right: 30px;
	}

	.pd-care-dashboard .pd-care-avatar,
	.pd-care-dashboard .pd-care-avatar-image,
	.pd-care-dashboard .pd-care-avatar-placeholder {
		width: 60px;
		height: 60px;
	}

	.pd-care-dashboard-daily {
		padding: 0 12px 12px;
	}

	.pd-care-dashboard-heading {
		margin: 0 12px;
	}

}

/* =========================
   Care Profile Actions
========================= */

.pd-care-profile-actions {
	display: flex;
	align-items: center;
	gap: 8px;
}

.pd-care-profile-actions .pd-care-profile-edit,
.pd-care-profile-actions .pd-care-profile-add {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 5px;
	height: 32px;
	padding: 0;
	border: 0;
	border-radius: 9px;
	text-decoration: none;
	box-sizing: border-box;
}

.pd-care-profile-actions .pd-care-profile-edit {
	width: auto;
	padding: 0 11px;
	background: #eaf2ff;
	color: #2563eb;
	font-size: 12px;
	font-weight: 700;
	opacity: 1;
	white-space: nowrap;
}

.pd-care-profile-actions .pd-care-profile-add {
	width: 32px;
	min-width: 32px;
	background: #f1f3f6;
	color: #374151;
}

.pd-care-profile-actions svg {
	display: block;
	width: 15px;
	height: 15px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.pd-care-profile-actions .pd-care-profile-add svg {
	width: 19px;
	height: 19px;
	stroke-width: 2.3;
}
