/* ================================
   Measurement Profiles Page
   Premium Italian Tailoring Design
   Navy & Gold Color Scheme
   ================================ */

/* GLOBAL OVERRIDE: Premium Navy/Gold Theme */
.ssc-profiles-page,
.ssc-profiles-page *,
.ssc-profiles-page *::before,
.ssc-profiles-page *::after {
	/* Premium Navy/Gold colors */
	--mp-navy: #0f2942;
	--mp-navy-light: #1a4a6e;
	--mp-gold: #c9a227;
	--mp-gold-soft: #d4b85a;
	--mp-ink: #1a1a1c;
	--mp-slate: #6e6e73;
	--mp-silver: #98989d;
	--mp-mist: #e8e8ed;
	--mp-cloud: #f5f5f7;
	--mp-snow: #ffffff;
	/* Override WooCommerce/Elementor colors */
	--wc-red: var(--mp-navy) !important;
	--e-a-color-danger: var(--mp-navy) !important;
	--e-a-color-accent: var(--mp-gold) !important;
	--e-a-bg-danger: var(--mp-cloud) !important;
	--e-a-btn-bg-primary: var(--mp-navy) !important;
	--e-a-btn-bg-primary-hover: var(--mp-navy-light) !important;
}

/* Force all buttons to premium style */
.ssc-profiles-page button,
.ssc-profiles-page button:hover,
.ssc-profiles-page button:active,
.ssc-profiles-page button:focus {
	border-color: var(--mp-mist) !important;
	background: transparent !important;
	color: var(--mp-navy) !important;
}

.ssc-profiles-page button.active,
.ssc-profiles-page button:hover {
	background: var(--mp-navy) !important;
	color: white !important;
	border-color: var(--mp-navy) !important;
}

:root {
	--ssc-primary: #0f2942;
	--ssc-primary-light: #1a4a6e;
	--ssc-gold: #c9a227;
	--ssc-gray-900: #1a1a1c;
	--ssc-gray-600: #6e6e73;
	--ssc-gray-400: #98989d;
	--ssc-gray-200: #e8e8ed;
	--ssc-gray-100: #f5f5f7;
	--ssc-border-radius: 14px;
	--ssc-transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}


/* Main Container */
.ssc-profiles-page {
	max-width: 1000px;
	margin: 0 auto;
	padding: 3rem 2rem;
	font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
	background-color: #ffffff;
}

/* View Management */
.ssc-profiles-view {
	display: none;
}

.ssc-profiles-view.active {
	display: block;
	animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
	from { opacity: 0; transform: translateY(10px); }
	to { opacity: 1; transform: translateY(0); }
}

/* ================================
   MAIN VIEW: Profile List
   ================================ */

.ssc-profiles-header {
	text-align: center;
	margin-bottom: 2.5rem;
	padding: 2.5rem 2rem;
	background: linear-gradient(135deg, rgba(15,41,66,0.04) 0%, rgba(201,162,39,0.04) 100%);
	border-radius: 20px;
}

.ssc-profiles-title {
	font-size: 2rem;
	font-weight: 700;
	color: #0f2942;
	margin: 0 0 0.75rem 0;
	letter-spacing: -0.02em;
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
}

.ssc-profiles-subtitle {
	font-size: 0.9rem;
	line-height: 1.7;
	color: #6e6e73;
	margin: 0;
	max-width: 600px;
	margin: 0 auto;
}

.ssc-profiles-list-container {
	max-width: 850px;
	margin: 0 auto;
}

.ssc-profiles-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
	gap: 1.5rem;
	margin-bottom: 1.5rem;
}

.ssc-profile-item {
	background: #ffffff;
	border: 1px solid #e8e8ed;
	border-radius: 16px;
	padding: 0;
	display: flex;
	flex-direction: column;
	transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
	min-height: auto;
	overflow: hidden;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.ssc-profile-item:hover {
	transform: translateY(-4px);
	border-color: #0f2942;
	box-shadow: 0 12px 30px rgba(15, 41, 66, 0.15);
}

/* Gold accent bar on hover */
.ssc-profile-item::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 4px;
	background: linear-gradient(90deg, #c9a227, #d4b85a, #c9a227);
	opacity: 0;
	transition: opacity 0.3s ease;
}

.ssc-profile-item:hover::before {
	opacity: 1;
}

/* Profile Card Header */
.ssc-profile-item-header {
	background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 50%, #0f2942 100%);
	padding: 1.25rem;
	position: relative;
	overflow: hidden;
	display: flex;
	align-items: center;
	gap: 1rem;
}

.ssc-profile-item-header::before {
	content: '';
	position: absolute;
	top: -50%;
	right: -30%;
	width: 150px;
	height: 150px;
	background: rgba(255, 255, 255, 0.1);
	border-radius: 50%;
}

.ssc-profile-item-header::after {
	content: '';
	position: absolute;
	bottom: -40%;
	left: -20%;
	width: 100px;
	height: 100px;
	background: rgba(255, 255, 255, 0.08);
	border-radius: 50%;
}

.ssc-profile-name {
	font-size: 1.25rem;
	font-weight: 700;
	color: #ffffff;
	margin: 0;
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	gap: 0.75rem;
}

.ssc-profile-name::before {
	content: '';
	display: inline-flex;
	width: 40px;
	height: 40px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 12px;
	align-items: center;
	justify-content: center;
	backdrop-filter: blur(4px);
}

.ssc-profile-date {
	font-size: 0.8rem;
	color: rgba(255, 255, 255, 0.8);
	margin-top: 0.5rem;
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

/* Profile Card Body - Measurements Preview */
.ssc-profile-item-body {
	padding: 1.25rem;
	background: linear-gradient(180deg, #f8faf9 0%, #ffffff 100%);
}

.ssc-profile-measurements-preview {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 0.75rem;
}

.ssc-measurement-preview-item {
	padding: 1rem;
	background: #ffffff;
	border: 2px solid #e5e7eb;
	border-radius: 12px;
	transition: all 0.3s ease;
}

.ssc-measurement-preview-item:hover {
	border-color: #c9a227;
	background: linear-gradient(135deg, #faf7ef 0%, #ffffff 100%);
}

.ssc-measurement-preview-label {
	font-size: 0.65rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: #9ca3af;
	margin-bottom: 0.25rem;
}

.ssc-measurement-preview-value {
	font-size: 1.5rem;
	font-weight: 700;
	color: #1f2937;
	line-height: 1.2;
}

.ssc-measurement-preview-unit {
	font-size: 0.7rem;
	color: #9ca3af;
	font-weight: 500;
}

.ssc-profile-more-measurements {
	text-align: center;
	font-size: 0.75rem;
	color: #6b7280;
	margin-top: 0.75rem;
	font-weight: 500;
}

/* ================================
   JS-Rendered Profile Cards
   New elegant card styling
   ================================ */

/* Profile Icon in Header */
.ssc-profile-icon {
	width: 48px;
	height: 48px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	backdrop-filter: blur(4px);
	flex-shrink: 0;
}

.ssc-profile-icon svg {
	color: white;
	stroke: white;
}

/* Profile Info in Header */
.ssc-profile-info {
	flex: 1;
	min-width: 0;
}

.ssc-profile-item-header .ssc-profile-name {
	margin: 0;
	font-size: 1.1rem;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.ssc-profile-item-header .ssc-profile-name::before {
	display: none;
}

/* Profile Body with Measurements Preview */
.ssc-profile-body {
	padding: 1rem 1.25rem;
	background: linear-gradient(180deg, #f8faf9 0%, #ffffff 100%);
	min-height: 60px;
}

.ssc-measurement-preview {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.ssc-measurement-tag {
	display: inline-block;
	padding: 0.35rem 0.7rem;
	background: #ffffff;
	border: 1px solid #e5e7eb;
	border-radius: 20px;
	font-size: 0.75rem;
	color: #4b5563;
	font-weight: 500;
	transition: all 0.2s ease;
}

.ssc-measurement-tag:hover {
	border-color: #c9a227;
	background: #faf7ef;
	color: #0f2942;
}

/* Profile Actions Footer */
.ssc-profile-actions {
	display: flex;
	gap: 0.5rem;
	padding: 1rem 1.25rem;
	background: #ffffff;
	border-top: 1px solid #f3f4f6;
}

.ssc-profile-actions .ssc-btn-action {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.4rem;
	padding: 0.6rem 0.75rem !important;
	border-radius: 10px !important;
	font-size: 0.8rem !important;
	font-weight: 600 !important;
	cursor: pointer !important;
	transition: all 0.3s ease !important;
	border: none !important;
	white-space: nowrap;
}

.ssc-profile-actions .ssc-btn-action svg {
	flex-shrink: 0;
}

.ssc-profile-actions .view-profile {
	background: linear-gradient(135deg, #e8eef5 0%, #dce5f0 100%) !important;
	color: #0f2942 !important;
}

.ssc-profile-actions .view-profile:hover {
	background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 100%) !important;
	color: #ffffff !important;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(15, 41, 66, 0.25);
}

.ssc-profile-actions .edit-profile {
	background: linear-gradient(135deg, #faf5e6 0%, #f5edd4 100%) !important;
	color: #8b6914 !important;
}

.ssc-profile-actions .edit-profile:hover {
	background: linear-gradient(135deg, #c9a227 0%, #d4b85a 100%) !important;
	color: #ffffff !important;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(201, 162, 39, 0.3);
}

.ssc-profile-actions .delete-profile {
	background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%) !important;
	color: #991b1b !important;
}

.ssc-profile-actions .delete-profile:hover {
	background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%) !important;
	color: #ffffff !important;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(220, 38, 38, 0.25);
}

/* No Profiles Empty State */
.ssc-no-profiles {
	grid-column: 1 / -1;
	text-align: center;
	padding: 4rem 2rem;
	background: linear-gradient(135deg, #f8faf9 0%, #ffffff 100%);
	border-radius: 16px;
	border: 2px dashed #e5e7eb;
}

.ssc-no-profiles-icon {
	margin-bottom: 1.5rem;
	color: #9ca3af;
}

.ssc-no-profiles-icon svg {
	width: 64px;
	height: 64px;
}

.ssc-no-profiles h3 {
	font-size: 1.25rem;
	font-weight: 700;
	color: #1f2937;
	margin: 0 0 0.5rem 0;
}

.ssc-no-profiles p {
	font-size: 0.95rem;
	color: #6b7280;
	margin: 0;
}

/* Profile Card Footer - Actions */
.ssc-profile-item-footer {
	padding: 1rem 1.25rem;
	background: #ffffff;
	border-top: 1px solid #f3f4f6;
}

.ssc-profile-actions-inline {
	display: flex;
	gap: 0.5rem;
	align-items: center;
	flex-wrap: nowrap;
}

.ssc-profile-actions-inline button {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	padding: 0.75rem 1rem !important;
	border-radius: 10px !important;
	font-size: 0.85rem !important;
	font-weight: 600 !important;
	cursor: pointer !important;
	transition: all 0.3s ease !important;
	border: none !important;
}

.ssc-profile-actions-inline button.view-profile {
	background: linear-gradient(135deg, #dbeafe 0%, #e0e7ff 100%) !important;
	color: #1e40af !important;
}

.ssc-profile-actions-inline button.view-profile:hover {
	background: linear-gradient(135deg, #bfdbfe 0%, #c7d2fe 100%) !important;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(30, 64, 175, 0.2);
}

.ssc-profile-actions-inline button.edit-profile {
	background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%) !important;
	color: #92400e !important;
}

.ssc-profile-actions-inline button.edit-profile:hover {
	background: linear-gradient(135deg, #fde68a 0%, #fcd34d 100%) !important;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(146, 64, 14, 0.2);
}

.ssc-profile-actions-inline button.delete-profile {
	background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%) !important;
	color: #991b1b !important;
}

.ssc-profile-actions-inline button.delete-profile:hover {
	background: linear-gradient(135deg, #fecaca 0%, #fca5a5 100%) !important;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(153, 27, 27, 0.2);
}

#ssc-btn-create-profile.ssc-btn-add-profile,
button.ssc-btn-add-profile,
.ssc-btn-add-profile {
	width: 100% !important;
	max-width: 100% !important;
	background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 100%) !important;
	background-color: #0f2942 !important;
	border: none !important;
	border-width: 0 !important;
	color: #ffffff !important;
	padding: 1.25rem 2rem !important;
	font-size: 0.95rem !important;
	font-weight: 600 !important;
	font-family: inherit !important;
	line-height: 1.5 !important;
	cursor: pointer !important;
	border-radius: 14px !important;
	transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 0.75rem !important;
	text-transform: none !important;
	text-align: center !important;
	text-decoration: none !important;
	white-space: normal !important;
	box-sizing: border-box !important;
	margin: 0 !important;
	appearance: none !important;
	-webkit-appearance: none !important;
	box-shadow: 0 4px 15px rgba(15, 41, 66, 0.25) !important;
}

#ssc-btn-create-profile.ssc-btn-add-profile:hover,
button.ssc-btn-add-profile:hover,
.ssc-btn-add-profile:hover {
	background: linear-gradient(135deg, #c9a227 0%, #d4b85a 100%) !important;
	background-color: #c9a227 !important;
	color: #ffffff !important;
	text-decoration: none !important;
	transform: translateY(-3px) !important;
	box-shadow: 0 8px 25px rgba(201, 162, 39, 0.35) !important;
}

.ssc-btn-icon {
	font-size: 1.2rem !important;
	font-weight: normal !important;
	line-height: 1 !important;
	display: inline-block !important;
}

.ssc-loading-profiles {
	grid-column: 1 / -1;
	text-align: center;
	padding: 3rem 2rem;
	color: var(--ssc-gray-400);
}

.ssc-spinner {
	width: 40px;
	height: 40px;
	border: 3px solid var(--ssc-gray-200);
	border-top-color: var(--ssc-primary);
	border-radius: 50%;
	animation: spin 0.8s linear infinite;
	margin: 0 auto 1rem;
}

@keyframes spin {
	to { transform: rotate(360deg); }
}

/* ================================
   CREATE VIEW: Method Selection
   ================================ */

.ssc-create-profile-container {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
}

.ssc-create-profile-left {
	text-align: center;
	margin-bottom: 2rem;
}

.ssc-btn-back {
	background: none;
	border: none;
	color: var(--ssc-gray-600);
	font-size: 0.9rem;
	font-weight: 500;
	cursor: pointer;
	padding: 0.5rem 0;
	margin-bottom: 2rem;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	transition: var(--ssc-transition);
}

.ssc-btn-back:hover {
	color: var(--ssc-primary);
}

.ssc-create-title {
	font-size: 2.5rem;
	font-weight: 700;
	color: var(--ssc-gray-900);
	margin: 0 0 2rem 0;
	line-height: 1.2;
	letter-spacing: -0.01em;
	font-family: 'Playfair Display', Georgia, serif;
}

.ssc-create-description {
	font-size: 0.95rem;
	line-height: 1.7;
	color: var(--ssc-gray-600);
	margin-bottom: 3rem;
}

.ssc-create-description p {
	margin: 0 0 1rem 0;
}

.ssc-method-title {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--ssc-gray-900);
	margin: 0 0 2rem 0;
	letter-spacing: -0.01em;
	font-family: 'Playfair Display', Georgia, serif;
}

.ssc-measurement-method {
	display: grid;
	grid-template-columns: 300px 1fr;
	gap: 2rem;
	margin-bottom: 3rem;
	padding-bottom: 3rem;
	border-bottom: 1px solid var(--ssc-gray-200);
}

.ssc-measurement-method:last-child {
	border-bottom: none;
	margin-bottom: 0;
	padding-bottom: 0;
}

.ssc-method-image {
	border-radius: var(--ssc-border-radius);
	overflow: hidden;
	border: 1px solid var(--ssc-gray-200);
}

.ssc-method-image img,
.ssc-method-image svg {
	width: 100%;
	height: auto;
	display: block;
}

.ssc-method-content {
	display: flex;
	flex-direction: column;
}

.ssc-method-name {
	font-size: 1.3rem;
	font-weight: 700;
	color: var(--ssc-gray-900);
	margin: 0 0 1rem 0;
	font-family: 'Playfair Display', Georgia, serif;
}

.ssc-method-features {
	list-style: none;
	padding: 0;
	margin: 0 0 1.5rem 0;
	flex: 1;
}

.ssc-method-features li {
	padding-left: 1.5rem;
	margin-bottom: 0.75rem;
	position: relative;
	font-size: 0.9rem;
	line-height: 1.6;
	color: var(--ssc-gray-600);
}

.ssc-method-features li::before {
	content: '•';
	position: absolute;
	left: 0;
	color: var(--ssc-primary);
	font-weight: 700;
}

.ssc-link {
	color: var(--ssc-primary);
	text-decoration: underline;
	transition: var(--ssc-transition);
}

.ssc-link:hover {
	color: var(--ssc-primary-light);
}

.ssc-btn-primary {
	background: var(--ssc-primary);
	color: white;
	border: none;
	padding: 0.75rem 2rem;
	font-size: 0.85rem;
	font-weight: 700;
	letter-spacing: 0.5px;
	text-transform: capitalize;
	cursor: pointer;
	border-radius: var(--ssc-border-radius);
	transition: var(--ssc-transition);
	align-self: flex-start;
}

.ssc-btn-primary:hover {
	background: var(--ssc-primary-light);
	transform: translateY(-1px);
}

/* ================================
   FORM VIEW: Measurement Form
   Elegant styling with gradient header
   ================================ */

.ssc-measurement-form-container {
	display: grid;
	grid-template-columns: 1fr;
	gap: 0;
	background: white;
	border-radius: 20px;
	overflow: hidden;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.ssc-form-left {
	background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 50%, #0f2942 100%);
	padding: 2.5rem 2rem;
	text-align: center;
	position: relative;
	overflow: hidden;
}

.ssc-form-left::before {
	content: '';
	position: absolute;
	top: -50%;
	right: -20%;
	width: 300px;
	height: 300px;
	background: rgba(255, 255, 255, 0.1);
	border-radius: 50%;
}

.ssc-form-left::after {
	content: '';
	position: absolute;
	bottom: -30%;
	left: -10%;
	width: 200px;
	height: 200px;
	background: rgba(255, 255, 255, 0.08);
	border-radius: 50%;
}

.ssc-form-left .ssc-btn-back {
	background: rgba(255, 255, 255, 0.2) !important;
	color: white !important;
	border: none !important;
	padding: 0.6rem 1.2rem !important;
	border-radius: 25px !important;
	font-size: 0.85rem !important;
	font-weight: 500 !important;
	backdrop-filter: blur(8px);
	margin-bottom: 1.5rem;
	position: relative;
	z-index: 1;
	transition: all 0.3s ease;
}

.ssc-form-left .ssc-btn-back:hover {
	background: rgba(255, 255, 255, 0.3) !important;
	transform: translateX(-3px);
}

.ssc-form-left .ssc-back-icon {
	margin-right: 0.5rem;
}

.ssc-form-guide-image {
	margin-bottom: 2rem;
	border-radius: var(--ssc-border-radius);
	overflow: hidden;
	border: 1px solid var(--ssc-gray-200);
	background: var(--ssc-gray-100);
	padding: 1rem;
}

.ssc-form-title {
	font-size: 2rem;
	font-weight: 700;
	color: white;
	margin: 0 0 1.5rem 0;
	line-height: 1.3;
	letter-spacing: -0.01em;
	font-family: 'Playfair Display', Georgia, serif;
	position: relative;
	z-index: 1;
}

.ssc-form-instructions {
	font-size: 0.9rem;
	line-height: 1.7;
	color: rgba(255, 255, 255, 0.9);
	margin-bottom: 1.5rem;
	position: relative;
	z-index: 1;
}

.ssc-form-instructions p {
	margin: 0 0 1rem 0;
}

.ssc-form-notice {
	background: rgba(255, 255, 255, 0.15);
	backdrop-filter: blur(8px);
	color: white;
	padding: 1.25rem;
	border-radius: 12px;
	display: flex;
	gap: 1rem;
	align-items: flex-start;
	margin-bottom: 0;
	position: relative;
	z-index: 1;
	border: 1px solid rgba(255, 255, 255, 0.2);
}

.ssc-notice-icon {
	font-size: 1.25rem;
	flex-shrink: 0;
	width: 32px;
	height: 32px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
}

.ssc-form-notice p {
	margin: 0;
	font-size: 0.85rem;
	line-height: 1.6;
}

.ssc-form-right {
	padding: 2.5rem 2rem;
	background: #f9fafb;
}

.ssc-profile-form {
	max-width: 100%;
}

/* Form Header Section */
.ssc-form-header-section {
	margin-bottom: 2rem;
	padding: 1.5rem;
	background: white;
	border-radius: 16px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.ssc-form-label-main {
	display: block;
	font-size: 0.85rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.8px;
	color: #374151;
	margin-bottom: 1rem;
}

.ssc-form-name-group {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.ssc-form-input-name {
	width: 100%;
	padding: 1rem 1.25rem;
	font-size: 1.1rem;
	border: 2px solid #e5e7eb;
	border-radius: 12px;
	transition: all 0.3s ease;
	background: #f9fafb;
}

.ssc-form-input-name:focus {
	outline: none;
	border-color: #1a4a6e;
	background: white;
	box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.1);
}

.ssc-form-input-name::placeholder {
	color: #9ca3af;
}

.ssc-form-unit-toggle {
	display: flex;
	align-items: center;
	gap: 1rem;
	flex-wrap: wrap;
}

.ssc-unit-label {
	font-size: 0.8rem;
	font-weight: 600;
	color: #6b7280;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.ssc-toggle-buttons {
	display: flex;
	gap: 0.5rem;
}

.ssc-form-input-main {
	width: 100%;
	padding: 0.75rem;
	font-size: 1rem;
	border: 1px solid var(--ssc-gray-200);
	border-radius: var(--ssc-border-radius);
	transition: var(--ssc-transition);
}

.ssc-form-input-main:focus {
	outline: none;
	border-color: var(--ssc-gray-600);
	box-shadow: 0 0 0 3px rgba(189, 189, 189, 0.15);
}

/* Measurements Grid */
.ssc-measurements-grid,
.ssc-measurements-form-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 1rem;
	margin-bottom: 2rem;
}

.ssc-form-group {
	display: flex;
	flex-direction: column;
	background: white;
	padding: 1.25rem;
	border-radius: 12px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
	transition: all 0.3s ease;
}

.ssc-form-group:hover {
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
	transform: translateY(-2px);
}

.ssc-form-label {
	font-size: 0.75rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: #0f2942;
	margin-bottom: 0.75rem;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.ssc-form-label::before {
	content: '';
	width: 8px;
	height: 8px;
	background: linear-gradient(135deg, #1a4a6e 0%, #0f2942 100%);
	border-radius: 50%;
}

.ssc-form-input,
.ssc-field-input {
	padding: 0.75rem 1rem;
	font-size: 1rem;
	border: 2px solid #e5e7eb;
	border-radius: 10px;
	transition: all 0.3s ease;
	background: #f9fafb;
	width: 100%;
}

.ssc-form-input:focus,
.ssc-field-input:focus {
	outline: none;
	border-color: #1a4a6e;
	background: white;
	box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.ssc-form-input::placeholder,
.ssc-field-input::placeholder {
	color: #9ca3af;
}

.ssc-form-input-group {
	display: flex;
	gap: 0.5rem;
	align-items: center;
}

.ssc-form-input-group input {
	flex: 1;
}

.ssc-form-input-unit {
	font-size: 0.8rem;
	font-weight: 600;
	color: var(--ssc-gray-600);
	padding: 0.65rem 0.75rem;
	background: transparent;
	border: none;
	border-bottom: 1px solid var(--ssc-gray-200);
	border-radius: 0;
	min-width: 60px;
	text-align: center;
}

.ssc-unit-toggle {
	display: flex;
	gap: 0.5rem;
	margin-bottom: 2rem;
	align-self: flex-end;
}

.ssc-unit-toggle button {
	background: transparent;
	border: 1px solid var(--ssc-gray-200);
	color: var(--ssc-gray-600);
	padding: 0.5rem 1rem;
	font-size: 0.8rem;
	font-weight: 600;
	cursor: pointer;
	border-radius: var(--ssc-border-radius);
	transition: var(--ssc-transition);
}

.ssc-unit-toggle button.active {
	background: var(--ssc-gray-600);
	color: white;
	border-color: var(--ssc-gray-600);
}

.ssc-unit-toggle button:hover {
	border-color: var(--ssc-gray-600);
	color: var(--ssc-gray-600);
}

/* Form Notes Section */
.ssc-form-notes {
	background: white;
	padding: 1.25rem;
	border-radius: 12px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
	margin-bottom: 2rem;
}

.ssc-form-notes .ssc-form-label {
	color: #6b7280;
	margin-bottom: 0.75rem;
}

.ssc-form-notes .ssc-form-label::before {
	background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.ssc-form-textarea {
	width: 100%;
	padding: 1rem;
	font-size: 0.95rem;
	border: 2px solid #e5e7eb;
	border-radius: 10px;
	transition: all 0.3s ease;
	background: #f9fafb;
	resize: vertical;
	min-height: 80px;
	font-family: inherit;
}

.ssc-form-textarea:focus {
	outline: none;
	border-color: #f59e0b;
	background: white;
	box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
}

/* Form Actions */
.ssc-form-actions {
	display: flex;
	gap: 1rem;
	margin-top: 1rem;
	padding-top: 0;
	border-top: none;
}

.ssc-btn-save-profile {
	width: 100%;
	padding: 1.25rem 2rem;
	font-size: 1rem;
	font-weight: 700;
	letter-spacing: 1px;
	background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 100%);
	color: white;
	border: none;
	border-radius: 12px;
	cursor: pointer;
	transition: all 0.3s ease;
	text-transform: uppercase;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.75rem;
	box-shadow: 0 4px 14px rgba(11, 93, 59, 0.3);
}

.ssc-btn-save-profile:hover {
	background: linear-gradient(135deg, #0a1f33 0%, #0f2942 100%);
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(11, 93, 59, 0.4);
}

.ssc-btn-save-profile:disabled {
	background: #d1d5db;
	cursor: not-allowed;
	transform: none;
	box-shadow: none;
}

.ssc-btn-arrow {
	font-size: 1.3rem;
	transition: transform 0.3s ease;
}

.ssc-btn-save-profile:hover .ssc-btn-arrow {
	transform: translateX(5px);
}

.ssc-btn-submit,
.ssc-btn-cancel {
	padding: 0.75rem 2rem;
	font-size: 0.85rem;
	font-weight: 700;
	border: none;
	border-radius: var(--ssc-border-radius);
	cursor: pointer;
	transition: var(--ssc-transition);
	text-transform: capitalize;
}

.ssc-btn-submit {
	background: var(--ssc-gray-600);
	color: white;
}

.ssc-btn-submit:hover {
	background: var(--ssc-gray-900);
	transform: translateY(-1px);
}

.ssc-btn-cancel {
	background: transparent;
	color: var(--ssc-gray-600);
	border: 1px solid var(--ssc-gray-200);
}

.ssc-btn-cancel:hover {
	background: var(--ssc-gray-100);
	border-color: var(--ssc-gray-300);
}

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

@media (max-width: 768px) {
	.ssc-profiles-page {
		padding: 1.5rem 1rem;
	}

	.ssc-profiles-title {
		font-size: 2rem;
	}

	.ssc-profiles-grid {
		grid-template-columns: 1fr;
		gap: 1.5rem;
	}

	/* Form responsive */
	.ssc-measurement-form-container {
		border-radius: 16px;
	}

	.ssc-form-left {
		padding: 2rem 1.5rem;
	}

	.ssc-form-title {
		font-size: 1.5rem;
	}

	.ssc-form-instructions {
		font-size: 0.85rem;
	}

	.ssc-form-right {
		padding: 1.5rem;
	}

	.ssc-form-header-section {
		padding: 1.25rem;
	}

	.ssc-form-input-name {
		font-size: 1rem;
		padding: 0.875rem 1rem;
	}

	.ssc-form-unit-toggle {
		flex-direction: column;
		align-items: flex-start;
		gap: 0.75rem;
	}

	.ssc-form-group {
		padding: 1rem;
	}

	.ssc-measurement-method {
		grid-template-columns: 1fr;
	}

	.ssc-measurements-grid,
	.ssc-measurements-form-grid {
		grid-template-columns: 1fr;
	}

	.ssc-btn-save-profile {
		padding: 1rem 1.5rem;
		font-size: 0.9rem;
	}

	.ssc-profile-item {
		flex-direction: column;
		align-items: stretch;
	}

	.ssc-profile-item-header {
		padding: 1rem;
		gap: 0.75rem;
	}

	.ssc-profile-icon {
		width: 40px;
		height: 40px;
	}

	.ssc-profile-icon svg {
		width: 20px;
		height: 20px;
	}

	.ssc-profile-info .ssc-profile-name {
		font-size: 1rem;
	}

	.ssc-profile-body {
		padding: 0.75rem 1rem;
	}

	.ssc-measurement-preview {
		gap: 0.35rem;
	}

	.ssc-measurement-tag {
		font-size: 0.7rem;
		padding: 0.25rem 0.5rem;
	}

	.ssc-profile-actions {
		flex-direction: column;
		gap: 0.5rem;
		padding: 0.75rem 1rem;
	}

	.ssc-profile-actions .ssc-btn-action {
		width: 100%;
		padding: 0.75rem !important;
	}

	.ssc-profile-actions-inline {
		width: 100%;
		gap: 0.5rem;
	}

	.ssc-profile-actions-inline button {
		flex: 1;
		text-align: center;
	}

	.ssc-no-profiles {
		padding: 3rem 1.5rem;
	}

	.ssc-no-profiles-icon svg {
		width: 48px;
		height: 48px;
	}
}

/* ================================
   Utility Classes
   ================================ */

.ssc-error-loading,
.ssc-no-profiles {
	text-align: center;
	padding: 2rem;
	color: var(--ssc-gray-600);
	font-size: 0.95rem;
}

.ssc-loading {
	opacity: 0.6;
	pointer-events: none;
}

/* ================================
   Notifications
   ================================ */

.ssc-notification {
	position: fixed;
	top: 20px;
	right: 20px;
	padding: 1rem 1.5rem;
	background: var(--ssc-gray-100);
	border: 2px solid var(--ssc-gray-300);
	border-radius: var(--ssc-border-radius);
	color: var(--ssc-gray-900);
	font-weight: 600;
	font-size: 0.95rem;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
	z-index: 10000;
	opacity: 0;
	transform: translateX(100px);
	transition: all 0.3s ease;
}

.ssc-notification.show {
	opacity: 1;
	transform: translateX(0);
}

.ssc-notification-success {
	border-left: 4px solid var(--ssc-gray-600);
}

.ssc-notification-error {
	border-left: 4px solid var(--ssc-gray-900);
}

/* ================================
   View Profile Modal - Elegant Design
   ================================ */

.ssc-view-modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.6);
	backdrop-filter: blur(4px);
	z-index: 10001;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
	animation: fadeIn 0.3s ease;
}

.ssc-view-modal {
	background: white;
	border-radius: 20px;
	max-width: 560px;
	width: 100%;
	max-height: 90vh;
	overflow: hidden;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
	position: relative;
	animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideUp {
	from {
		opacity: 0;
		transform: translateY(20px) scale(0.98);
	}
	to {
		opacity: 1;
		transform: translateY(0) scale(1);
	}
}

.ssc-view-modal-close {
	position: absolute;
	top: 1rem;
	right: 1rem;
	width: 40px;
	height: 40px;
	display: flex !important;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.2) !important;
	backdrop-filter: blur(8px);
	border: none !important;
	border-radius: 50% !important;
	cursor: pointer;
	color: white !important;
	z-index: 10;
	transition: all 0.3s ease;
	padding: 0 !important;
}

.ssc-view-modal-close:hover {
	background: rgba(255, 255, 255, 0.3) !important;
	transform: rotate(90deg);
}

.ssc-view-modal-close svg {
	stroke: white;
}

.ssc-view-modal-header {
	background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 50%, #0f2942 100%);
	padding: 2.5rem 2rem 2rem;
	text-align: center;
	position: relative;
	overflow: hidden;
}

.ssc-view-modal-header::before {
	content: '';
	position: absolute;
	top: -60%;
	right: -20%;
	width: 200px;
	height: 200px;
	background: rgba(255, 255, 255, 0.1);
	border-radius: 50%;
}

.ssc-view-modal-header::after {
	content: '';
	position: absolute;
	bottom: -50%;
	left: -10%;
	width: 150px;
	height: 150px;
	background: rgba(255, 255, 255, 0.08);
	border-radius: 50%;
}

.ssc-modal-profile-icon {
	width: 72px;
	height: 72px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto 1rem;
	backdrop-filter: blur(8px);
	position: relative;
	z-index: 1;
}

.ssc-modal-profile-icon svg {
	stroke: white;
}

.ssc-view-modal-header h2 {
	margin: 0 0 0.5rem 0;
	font-size: 1.5rem;
	font-weight: 700;
	color: white;
	position: relative;
	z-index: 1;
	font-family: 'Playfair Display', Georgia, serif;
}

.ssc-modal-date {
	font-size: 0.85rem;
	color: rgba(255, 255, 255, 0.85);
	position: relative;
	z-index: 1;
}

.ssc-view-modal-body {
	padding: 1.5rem 2rem;
	max-height: 50vh;
	overflow-y: auto;
}

.ssc-view-method-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.5rem 1rem;
	background: linear-gradient(135deg, #f8f9fc 0%, #e8eef5 100%);
	border: 1px solid #a7f3d0;
	border-radius: 25px;
	font-size: 0.85rem;
	color: #065f46;
	font-weight: 600;
	margin-bottom: 1.5rem;
}

.ssc-view-method-badge svg {
	color: #0f2942;
}

.ssc-view-measurements-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 0.75rem;
}

.ssc-view-measurement-card {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 1rem;
	background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	transition: all 0.3s ease;
}

.ssc-view-measurement-card:hover {
	border-color: #1a4a6e;
	background: linear-gradient(135deg, #f8f9fc 0%, #ffffff 100%);
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(16, 185, 129, 0.15);
}

.ssc-measurement-icon {
	width: 40px;
	height: 40px;
	background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 100%);
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.ssc-measurement-icon svg {
	stroke: white;
	width: 20px;
	height: 20px;
}

.ssc-measurement-details {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.ssc-measurement-label {
	font-size: 0.7rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: #9ca3af;
	margin-bottom: 0.15rem;
}

.ssc-measurement-value {
	font-size: 1.1rem;
	font-weight: 700;
	color: #1f2937;
}

.ssc-measurement-value small {
	font-size: 0.7rem;
	font-weight: 500;
	color: #9ca3af;
}

.ssc-no-measurements {
	grid-column: 1 / -1;
	text-align: center;
	padding: 2rem;
	color: #9ca3af;
	font-style: italic;
}

.ssc-view-notes {
	margin-top: 1.5rem;
	padding: 1rem;
	background: linear-gradient(135deg, #fefce8 0%, #fef9c3 100%);
	border: 1px solid #fde047;
	border-radius: 12px;
}

.ssc-notes-header {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin-bottom: 0.5rem;
	font-weight: 600;
	color: #854d0e;
	font-size: 0.85rem;
}

.ssc-notes-header svg {
	color: #ca8a04;
}

.ssc-view-notes p {
	margin: 0;
	font-size: 0.9rem;
	color: #713f12;
	line-height: 1.6;
}

.ssc-view-modal-footer {
	display: flex;
	gap: 0.75rem;
	padding: 1.25rem 2rem;
	background: #f9fafb;
	border-top: 1px solid #e5e7eb;
	justify-content: flex-end;
}

.ssc-view-modal-footer button {
	display: inline-flex !important;
	align-items: center;
	gap: 0.5rem;
	padding: 0.75rem 1.5rem !important;
	border-radius: 10px !important;
	font-size: 0.9rem !important;
	font-weight: 600 !important;
	cursor: pointer !important;
	transition: all 0.3s ease !important;
}

.ssc-btn-close-view {
	background: white !important;
	color: #6b7280 !important;
	border: 1px solid #d1d5db !important;
}

.ssc-btn-close-view:hover {
	background: #f3f4f6 !important;
	border-color: #9ca3af !important;
}

.ssc-btn-edit-from-view {
	background: linear-gradient(135deg, #0f2942 0%, #1a4a6e 100%) !important;
	color: white !important;
	border: none !important;
	box-shadow: 0 4px 14px rgba(11, 93, 59, 0.3);
}

.ssc-btn-edit-from-view:hover {
	background: linear-gradient(135deg, #0a1f33 0%, #0f2942 100%) !important;
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(11, 93, 59, 0.4);
}

/* Mobile responsive for modal */
@media (max-width: 600px) {
	.ssc-view-modal {
		max-width: 100%;
		margin: 1rem;
		border-radius: 16px;
	}
	
	.ssc-view-modal-header {
		padding: 2rem 1.5rem 1.5rem;
	}
	
	.ssc-modal-profile-icon {
		width: 60px;
		height: 60px;
	}
	
	.ssc-modal-profile-icon svg {
		width: 28px;
		height: 28px;
	}
	
	.ssc-view-modal-header h2 {
		font-size: 1.25rem;
	}
	
	.ssc-view-modal-body {
		padding: 1.25rem;
	}
	
	.ssc-view-measurements-grid {
		grid-template-columns: 1fr;
	}
	
	.ssc-view-modal-footer {
		flex-direction: column-reverse;
		padding: 1rem 1.25rem;
	}
	
	.ssc-view-modal-footer button {
		width: 100%;
		justify-content: center;
	}
}

/* Legacy modal styles - keeping for backwards compatibility */
.ssc-view-method {
	margin-bottom: 1rem;
	font-size: 0.95rem;
	color: var(--ssc-gray-700);
}

.ssc-view-measurements h3 {
	font-size: 1rem;
	font-weight: 600;
	margin: 0 0 0.75rem 0;
	color: var(--ssc-gray-900);
}

.ssc-view-measurement {
	display: flex;
	justify-content: space-between;
	padding: 0.5rem 0;
	border-bottom: 1px solid var(--ssc-gray-100);
	font-size: 0.9rem;
}

.ssc-view-measurement strong {
	color: var(--ssc-gray-700);
	font-weight: 500;
}

/* ================================
   Delete Confirmation Modal
   ================================ */

.ssc-confirm-modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.6);
	backdrop-filter: blur(4px);
	z-index: 10002;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
	animation: fadeIn 0.2s ease;
}

.ssc-confirm-modal {
	background: white;
	border-radius: 20px;
	max-width: 400px;
	width: 100%;
	padding: 2rem;
	text-align: center;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
	animation: slideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.ssc-confirm-modal-icon {
	width: 80px;
	height: 80px;
	background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto 1.5rem;
}

.ssc-confirm-modal-icon svg {
	color: #dc2626;
	stroke: #dc2626;
}

.ssc-confirm-modal h3 {
	margin: 0 0 0.75rem 0;
	font-size: 1.25rem;
	font-weight: 700;
	color: #1f2937;
	font-family: 'Playfair Display', Georgia, serif;
}

.ssc-confirm-modal p {
	margin: 0 0 1.5rem 0;
	font-size: 0.9rem;
	color: #6b7280;
	line-height: 1.6;
}

.ssc-confirm-modal-actions {
	display: flex;
	gap: 0.75rem;
	justify-content: center;
}

.ssc-confirm-modal-actions button {
	display: inline-flex !important;
	align-items: center;
	gap: 0.5rem;
	padding: 0.75rem 1.25rem !important;
	border-radius: 10px !important;
	font-size: 0.9rem !important;
	font-weight: 600 !important;
	cursor: pointer !important;
	transition: all 0.3s ease !important;
	flex: 1;
	justify-content: center;
}

.ssc-btn-cancel-delete {
	background: white !important;
	color: #6b7280 !important;
	border: 1px solid #d1d5db !important;
}

.ssc-btn-cancel-delete:hover {
	background: #f3f4f6 !important;
	border-color: #9ca3af !important;
}

.ssc-btn-confirm-delete {
	background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%) !important;
	color: white !important;
	border: none !important;
	box-shadow: 0 4px 14px rgba(220, 38, 38, 0.3);
}

.ssc-btn-confirm-delete:hover {
	background: linear-gradient(135deg, #b91c1c 0%, #dc2626 100%) !important;
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(220, 38, 38, 0.4);
}

.ssc-spinner-small {
	display: inline-block;
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, 0.3);
	border-top-color: white;
	border-radius: 50%;
	animation: spin 0.8s linear infinite;
}

@media (max-width: 480px) {
	.ssc-confirm-modal {
		padding: 1.5rem;
		margin: 1rem;
	}
	
	.ssc-confirm-modal-icon {
		width: 64px;
		height: 64px;
	}
	
	.ssc-confirm-modal-icon svg {
		width: 32px;
		height: 32px;
	}
	
	.ssc-confirm-modal-actions {
		flex-direction: column-reverse;
	}
	
	.ssc-confirm-modal-actions button {
		width: 100%;
	}
}
