/* IDX Stock Analyzer — Frontend Styles */
.isa-wrap {
	max-width: 1100px;
	margin: 0 auto;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: #1a1f2b;
	box-sizing: border-box;
}
.isa-wrap *, .isa-wrap *::before, .isa-wrap *::after { box-sizing: border-box; }

.isa-header { text-align: center; margin-bottom: 24px; }
.isa-title {
	font-size: 28px;
	font-weight: 800;
	margin: 0 0 6px;
	background: linear-gradient(90deg, #0f4c81, #1b9c85);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}
.isa-subtitle { color: #5b6472; font-size: 15px; margin: 0; }

/* ---- Form ---- */
.isa-form {
	background: linear-gradient(135deg, #0f4c81 0%, #1b9c85 100%);
	border-radius: 16px;
	padding: 22px;
	box-shadow: 0 10px 30px rgba(15, 76, 129, 0.18);
	margin-bottom: 24px;
}
.isa-form-row {
	display: flex;
	gap: 14px;
	flex-wrap: wrap;
	align-items: flex-end;
}
.isa-field { flex: 1 1 200px; position: relative; }
.isa-field-btn { flex: 0 0 auto; }
.isa-field label {
	display: block;
	color: #eaf6f2;
	font-size: 13px;
	font-weight: 600;
	margin-bottom: 6px;
}
.isa-field input[type="text"],
.isa-field input[type="number"] {
	width: 100%;
	padding: 12px 14px;
	border-radius: 10px;
	border: none;
	font-size: 16px;
	background: #fff;
	color: #1a1f2b;
	outline: none;
}
.isa-field input:focus { box-shadow: 0 0 0 3px rgba(255,255,255,0.5); }

.isa-btn-analyze {
	background: #ffb020;
	color: #1a1f2b;
	border: none;
	border-radius: 10px;
	padding: 12px 22px;
	font-size: 16px;
	font-weight: 700;
	cursor: pointer;
	white-space: nowrap;
	transition: transform .12s ease, box-shadow .12s ease;
	width: 100%;
}
.isa-btn-analyze:hover { transform: translateY(-1px); box-shadow: 0 6px 14px rgba(0,0,0,0.18); }
.isa-btn-analyze:disabled { opacity: 0.7; cursor: progress; }

.isa-form-note { color: #d7ede6; font-size: 12.5px; margin: 12px 0 0; }

.isa-autocomplete {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	background: #fff;
	border-radius: 10px;
	box-shadow: 0 12px 24px rgba(0,0,0,0.18);
	margin-top: 6px;
	z-index: 50;
	max-height: 260px;
	overflow-y: auto;
	display: none;
}
.isa-autocomplete-item {
	padding: 10px 14px;
	font-size: 14px;
	cursor: pointer;
	border-bottom: 1px solid #f0f0f0;
	display: flex;
	justify-content: space-between;
	gap: 10px;
}
.isa-autocomplete-item:last-child { border-bottom: none; }
.isa-autocomplete-item:hover { background: #f3f9f7; }
.isa-ac-price { color: #5b6472; font-size: 12.5px; white-space: nowrap; }

/* ---- Error ---- */
.isa-error {
	background: #fde8e8;
	color: #a4222b;
	border: 1px solid #f5c2c7;
	border-radius: 10px;
	padding: 14px 16px;
	margin-bottom: 20px;
	font-size: 14.5px;
}

/* ---- Skeleton loading ---- */
.isa-skeleton {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
	gap: 16px;
}
.isa-skel-card {
	height: 220px;
	border-radius: 14px;
	background: linear-gradient(90deg, #eef1f4 25%, #e2e6ea 37%, #eef1f4 63%);
	background-size: 400% 100%;
	animation: isa-shimmer 1.4s ease infinite;
}
@keyframes isa-shimmer {
	0% { background-position: 100% 50%; }
	100% { background-position: 0 50%; }
}

/* ---- Stock header ---- */
.isa-stock-header {
	background: #fff;
	border: 1px solid #e6e9ee;
	border-radius: 14px;
	padding: 18px 20px;
	margin-bottom: 20px;
	box-shadow: 0 4px 14px rgba(0,0,0,0.04);
}
.isa-stock-title { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.isa-stock-kode { font-size: 24px; font-weight: 800; color: #0f4c81; }
.isa-stock-name { font-size: 16px; color: #444c58; }
.isa-stock-meta { margin-top: 8px; display: flex; gap: 14px; flex-wrap: wrap; align-items: center; font-size: 14px; color: #444c58; }
.isa-badge-sector {
	background: #eaf1fb; color: #0f4c81; padding: 4px 12px; border-radius: 999px; font-weight: 600; font-size: 12.5px;
}

/* ---- Cards grid ---- */
.isa-cards-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
	gap: 16px;
}

/* Kartu #1 (Fundamental Score) dipisah dari sisanya oleh margin ini. */
#isa-cards-top { margin-bottom: 16px; }

/* ---- Paywall lock: blur 10 modul di bawah Fundamental Score ---- */
.isa-locked-wrap {
	position: relative;
}
#isa-cards-bottom.isa-blurred {
	filter: blur(7px);
	-webkit-filter: blur(7px);
	pointer-events: none;
	user-select: none;
	/* jaga tinggi minimal supaya overlay CTA punya ruang meski konten pendek */
	min-height: 260px;
}
.isa-paywall-overlay {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: flex-start;
	justify-content: center;
	padding: 28px 16px 24px;
	z-index: 5;
	background: linear-gradient(180deg, rgba(255,255,255,0.95) 0%, rgba(255,255,255,0.75) 45%, rgba(255,255,255,0.15) 100%);
}
.isa-paywall-box {
	max-width: 480px;
	width: 100%;
	text-align: center;
	background: #fff;
	border-radius: 16px;
	border: 1px solid #e6e9ee;
	box-shadow: 0 10px 30px rgba(0,0,0,0.12);
	padding: 24px 20px;
}
.isa-card {
	background: #fff;
	border-radius: 14px;
	border: 1px solid #e6e9ee;
	border-top: 5px solid #9aa4b2;
	padding: 18px;
	box-shadow: 0 4px 14px rgba(0,0,0,0.04);
	display: flex;
	flex-direction: column;
}
.isa-card-good  { border-top-color: #1b9c6b; }
.isa-card-bad   { border-top-color: #d84343; }
.isa-card-neutral { border-top-color: #e0a030; }

.isa-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; margin-bottom: 6px; }
.isa-card-title { font-size: 15px; font-weight: 700; margin: 0; color: #1a1f2b; line-height: 1.35; }

.isa-verdict-badge { font-size: 11px; font-weight: 700; padding: 4px 9px; border-radius: 999px; white-space: nowrap; }
.isa-badge-good    { background: #e4f7ee; color: #1b9c6b; }
.isa-badge-bad     { background: #fbe7e7; color: #d84343; }
.isa-badge-neutral { background: #fdf3e0; color: #b3791f; }

.isa-card-headline { font-size: 21px; font-weight: 800; color: #0f4c81; margin: 4px 0 12px; }

.isa-card-points { margin-bottom: 10px; }
.isa-point {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 4px 10px;
	padding: 6px 0;
	border-bottom: 1px dashed #eef0f3;
	font-size: 13.5px;
}
.isa-point:last-child { border-bottom: none; }
.isa-point-label { color: #5b6472; flex: 1 1 55%; }
.isa-point-value { font-weight: 700; color: #1a1f2b; }
.isa-point-note { flex-basis: 100%; color: #8b93a1; font-size: 12px; }

.isa-card-narrative {
	font-size: 13px;
	color: #4b5563;
	line-height: 1.55;
	margin: 6px 0 0;
	border-top: 1px solid #f0f2f5;
	padding-top: 10px;
}

/* ---- Mobile responsiveness ---- */
@media (max-width: 640px) {
	.isa-title { font-size: 22px; }
	.isa-form { padding: 16px; border-radius: 14px; }
	.isa-form-row { flex-direction: column; align-items: stretch; }
	.isa-field { flex: 1 1 auto; }
	.isa-cards-grid { grid-template-columns: 1fr; }
	.isa-stock-kode { font-size: 20px; }
}
