@charset "UTF-8";
@import url('reset.css');
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* -- CSS VARIABLES ---------------------------------------------------- */
:root {
	--blue-bg: #0ea5e9;
	--white: #ffffff;
	--text-dark: #1e293b;
	--text-gray: #64748b;
	--text-light: #94a3b8;
	--border: #e2e8f0;
	--bg-light: #e2e8f0;
	--accent: #0ea5e9;
	--accent-hover: #0284c7;
	--radius: 8px;
	--radius-lg: 16px;
}

/* -- BASE ------------------------------------------------------------- */
html {
	font-size: 62.5%;
}

body {
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
	font-size: 1.4rem;
	line-height: 1.6;
	color: var(--text-dark);
	background-color: var(--blue-bg);
	margin: 0;
	padding: 20px;
	min-height: 100vh;
}

/* -- LOGIN PAGE ------------------------------------------------------- */
#login {
	max-width: 400px;
	margin: 80px auto;
	background: var(--white);
	padding: 40px;
	border-radius: var(--radius-lg);
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
}

#login .logo {
	float: none;
	text-align: center;
	margin-bottom: 30px;
}

#login p {
	padding: 0;
}

/* -- MAIN CONTENT CARD ------------------------------------------------ */
#mainContent {
	background: var(--white);
	max-width: 1200px;
	margin: 0 auto;
	padding: 30px;
	border-radius: var(--radius-lg);
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
	min-height: calc(100vh - 40px);
}

/* -- LOGO ------------------------------------------------------------- */
.logo {
	float: left;
}

.logo img {
	height: 36px;
}

/* -- NAVIGATION ------------------------------------------------------- */
.logout {
	float: right;
	margin: 5px 0;
}

.logout a {
	color: var(--text-gray);
	text-decoration: none;
	padding: 8px 16px;
	font-size: 1.3rem;
	font-weight: 500;
	border-radius: var(--radius);
	transition: all 0.15s ease;
}

.logout a:hover {
	color: var(--accent);
}

.logout a:last-child {
	background: var(--bg-light);
	color: var(--text-gray);
	margin-left: 8px;
}

.logout a:last-child:hover {
	background: #fee2e2;
	color: #dc2626;
}

/* -- COUNTDOWN -------------------------------------------------------- */
#countDownExp {
	float: right;
	margin: 8px 20px;
	font-size: 1.2rem;
	color: var(--text-light);
}

/* -- ROW CONTROLS ----------------------------------------------------- */
.row1 {
	float: left;
	margin: 15px 15px 15px 0;
}

.rowHide {
	display: none;
}

/* -- SQL CONTENT ------------------------------------------------------ */
#SQLContent {
	clear: both;
	padding: 20px 0;
}

#SQLContent p {
	background: var(--bg-light);
	padding: 20px;
	margin-bottom: 12px;
	border-radius: var(--radius);
	font-family: 'SF Mono', Monaco, monospace;
	font-size: 1.3rem;
	line-height: 1.8;
	color: var(--text-dark);
}

/* -- HEADERS ---------------------------------------------------------- */
.header1 {
	display: inline-block;
	background: var(--accent);
	color: var(--white);
	padding: 4px 12px;
	border-radius: 4px;
	font-size: 1.1rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 10px;
}

/* -- TABLE ------------------------------------------------------------ */
#colTbl {
	width: 100%;
	border-collapse: collapse;
	margin: 15px 0;
}

#tblHeader td {
	background: var(--text-dark);
	color: var(--white);
	padding: 12px 16px;
	font-weight: 600;
	font-size: 1.2rem;
	text-transform: uppercase;
	letter-spacing: 0.3px;
}

#tblHeader td:first-child {
	border-radius: var(--radius) 0 0 0;
}

#tblHeader td:last-child {
	border-radius: 0 var(--radius) 0 0;
}

#tblRow td,
#tblRow0 td {
	padding: 12px 16px;
	border-bottom: 1px solid var(--border);
	vertical-align: top;
}

#tblRow:hover td,
#tblRow0:hover td {
	background: var(--bg-light);
}

/* -- ERROR ------------------------------------------------------------ */
#errorMsg {
	text-align: center;
	padding: 16px;
	margin-bottom: 20px;
	background: #fef2f2;
	border-radius: var(--radius);
	color: #dc2626;
}

/* -- MODEL FUNCTION --------------------------------------------------- */
#modelFunctContent {
	clear: both;
	padding: 20px 0;
}

.modelFunctWrapper {
	background: var(--bg-light);
	padding: 20px;
	margin-bottom: 12px;
	border-radius: var(--radius);
}

.modelFunctEditable {
	display: none;
}

.modelLabel {
	font-weight: 600;
	color: var(--accent);
	margin-right: 10px;
	cursor: pointer;
}

.modelValue,
.functNameValue {
	color: var(--text-dark);
}

.functNameLabel,
.functLabel {
	color: var(--text-gray);
	margin: 0 10px;
}

.functDescLabel {
	display: block;
	margin-top: 15px;
	color: var(--text-gray);
}

.functDescValue {
	width: 100%;
}

.functDescValue textarea {
	margin-top: 8px;
}

#showAll,
#hideAll,
#sync {
	display: inline-block;
	padding: 8px 16px;
	margin-left: 8px;
	background: var(--white);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	color: var(--text-gray);
	font-size: 1.2rem;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.15s ease;
}

#showAll:hover,
#hideAll:hover,
#sync:hover {
	border-color: var(--accent);
	color: var(--accent);
}

/* -- TEXTAREA --------------------------------------------------------- */
.colDesc {
	width: 100%;
	min-height: 70px;
	padding: 12px;
	font-family: inherit;
	font-size: 1.3rem;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--white);
	resize: vertical;
	transition: border-color 0.15s ease;
}

.colDesc:focus {
	outline: none;
	border-color: var(--accent);
}

/* -- FOOTER ----------------------------------------------------------- */
footer {
	text-align: center;
	padding: 20px;
	color: var(--text-light);
	font-size: 1.2rem;
}

/* -- RESPONSIVE ------------------------------------------------------- */
@media (max-width: 768px) {
	body {
		padding: 10px;
	}

	#mainContent {
		padding: 20px;
		border-radius: var(--radius);
	}

	.row1 {
		float: none;
		margin: 10px 0;
	}
}
