/**
 * Sheena Carpets ERP - Modern Redesign Stylesheet
 * Brand Palette:
 *   - Primary Teal: #4FA0A4
 *   - Deep Charcoal: #343434
 *   - Clean White: #FFFFFF
 *   - Soft Background: #F5F7F7
 *   - Accent Green: #4ED49A
 */

:root {
  --sheena-teal: #4FA0A4;
  --sheena-teal-hover: #418b8f;
  --sheena-teal-active: #357376;
  --sheena-teal-subtle: #edf6f6;
  --sheena-teal-border: #c8e2e4;
  --sheena-charcoal: #343434;
  --sheena-charcoal-muted: #5c6466;
  --sheena-charcoal-light: #889295;
  --sheena-white: #ffffff;
  --sheena-bg-soft: #F5F7F7;
  --sheena-accent-green: #4ED49A;
  --sheena-border: #dde4e5;
  --sheena-border-focus: #4FA0A4;
  --sheena-error-bg: #fef2f2;
  --sheena-error-border: #fca5a5;
  --sheena-error-text: #b91c1c;
  --sheena-radius-lg: 16px;
  --sheena-radius-md: 10px;
  --sheena-radius-sm: 6px;
  --sheena-shadow-card: 0 20px 25px -5px rgba(52, 52, 52, 0.05), 0 8px 10px -6px rgba(52, 52, 52, 0.03);
  --sheena-shadow-hover: 0 25px 30px -5px rgba(79, 160, 164, 0.15), 0 10px 15px -5px rgba(52, 52, 52, 0.04);
  --sheena-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

/* Base resets & layout */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  font-family: var(--sheena-font);
  background-color: var(--sheena-bg-soft);
  color: var(--sheena-charcoal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.sheena-login-wrapper {
  display: flex;
  min-height: 100vh;
  width: 100%;
  background-color: var(--sheena-bg-soft);
  overflow-x: hidden;
}

/* Left Column: Brand Hero Presentation */
.sheena-brand-hero {
  flex: 1.1;
  background: linear-gradient(145deg, #f0f7f7 0%, #e6f1f2 100%);
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 3.5rem 4rem;
  overflow: hidden;
  border-right: 1px solid rgba(79, 160, 164, 0.15);
}

/* Subtle Woven Carpet Geometric Trellis SVG Background */
.sheena-brand-hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%234FA0A4' fill-opacity='0.05' fill-rule='evenodd'%3E%3Cpath d='M40 0L80 40L40 80L0 40zM40 8L72 40L40 72L8 40z'/%3E%3Ccircle cx='40' cy='40' r='6'/%3E%3Cpath d='M0 0l20 20M80 0L60 20M0 80l20-20M80 80L60 60' stroke='%23343434' stroke-width='0.75' stroke-opacity='0.04'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 1;
}

.sheena-brand-hero-content {
  position: relative;
  z-index: 2;
  max-width: 520px;
  margin: auto 0;
}

.sheena-logo-container {
  margin-bottom: 2.25rem;
  display: inline-block;
  background: #ffffff;
  padding: 1.25rem 1.75rem;
  border-radius: var(--sheena-radius-lg);
  box-shadow: 0 10px 25px -5px rgba(79, 160, 164, 0.12), 0 4px 6px -4px rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(79, 160, 164, 0.2);
  transition: transform 0.3s ease;
}

.sheena-logo-container:hover {
  transform: translateY(-2px);
}

.sheena-logo-img {
  display: block;
  max-width: 260px;
  height: auto;
  object-fit: contain;
}

.sheena-brand-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  background-color: rgba(79, 160, 164, 0.12);
  color: var(--sheena-teal);
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1.25rem;
}

.sheena-badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--sheena-accent-green);
  box-shadow: 0 0 0 2px rgba(78, 212, 154, 0.3);
}

.sheena-brand-title {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--sheena-charcoal);
  line-height: 1.25;
  margin-bottom: 0.85rem;
  letter-spacing: -0.02em;
}

.sheena-brand-subtitle {
  font-size: 1.1rem;
  color: var(--sheena-charcoal-muted);
  line-height: 1.6;
  margin-bottom: 2.5rem;
}

/* Feature pills showing ERP capability */
.sheena-features-list {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-top: 1rem;
}

.sheena-feature-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.925rem;
  color: var(--sheena-charcoal);
  font-weight: 500;
}

.sheena-feature-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background-color: #ffffff;
  color: var(--sheena-teal);
  box-shadow: 0 2px 5px rgba(0,0,0,0.04);
  border: 1px solid rgba(79, 160, 164, 0.18);
  flex-shrink: 0;
}

.sheena-hero-footer {
  position: relative;
  z-index: 2;
  font-size: 0.85rem;
  color: var(--sheena-charcoal-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Right Column: Form Container & Login Card */
.sheena-form-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 3rem 2rem;
  position: relative;
}

.sheena-login-card {
  width: 100%;
  max-width: 440px;
  background: var(--sheena-white);
  border-radius: var(--sheena-radius-lg);
  box-shadow: var(--sheena-shadow-card);
  padding: 2.75rem 2.5rem;
  border: 1px solid var(--sheena-border);
  position: relative;
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.sheena-login-card:hover {
  box-shadow: var(--sheena-shadow-hover);
  border-color: rgba(79, 160, 164, 0.3);
}

/* Mobile-only logo view */
.sheena-mobile-logo-header {
  display: none;
  text-align: center;
  margin-bottom: 1.5rem;
}

.sheena-mobile-logo {
  max-width: 180px;
  height: auto;
  margin: 0 auto;
}

/* Card Header */
.sheena-card-header {
  margin-bottom: 2rem;
}

.sheena-card-title {
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--sheena-charcoal);
  letter-spacing: -0.015em;
  margin-bottom: 0.35rem;
}

.sheena-card-subtitle {
  font-size: 0.925rem;
  color: var(--sheena-charcoal-muted);
}

/* Server-side / Client-side Alert Box */
.sheena-alert {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-radius: var(--sheena-radius-sm);
  margin-bottom: 1.5rem;
  font-size: 0.875rem;
  line-height: 1.4;
}

.sheena-alert-danger {
  background-color: var(--sheena-error-bg);
  border: 1px solid var(--sheena-error-border);
  color: var(--sheena-error-text);
}

.sheena-alert-icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: 1px;
}

/* Form Groups & Controls */
.sheena-form-group {
  margin-bottom: 1.35rem;
}

.sheena-form-label {
  display: block;
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--sheena-charcoal);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
}

.sheena-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.sheena-input-icon {
  position: absolute;
  left: 1rem;
  color: var(--sheena-charcoal-light);
  width: 18px;
  height: 18px;
  pointer-events: none;
  transition: color 0.2s ease;
  z-index: 2;
}

/* Styled Inputs & Dropdowns */
.sheena-form-control {
  width: 100%;
  height: 48px;
  padding: 0.65rem 1rem 0.65rem 2.85rem;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--sheena-charcoal);
  background-color: #ffffff;
  border: 1.5px solid var(--sheena-border);
  border-radius: var(--sheena-radius-md);
  outline: none;
  transition: all 0.2s ease;
}

.sheena-form-control::placeholder {
  color: #a0abaf;
  font-size: 0.9rem;
}

.sheena-form-control:focus {
  border-color: var(--sheena-border-focus);
  background-color: #ffffff;
  box-shadow: 0 0 0 4px rgba(79, 160, 164, 0.15);
}

.sheena-form-control:focus + .sheena-input-icon,
.sheena-input-wrapper:focus-within .sheena-input-icon {
  color: var(--sheena-teal);
}

/* Select Dropdown specific styling */
.sheena-form-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  cursor: pointer;
  padding-right: 2.75rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234FA0A4' stroke-width='2.2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 16px 16px;
  font-weight: 500;
}

/* Password Toggle Eye Button */
.sheena-password-toggle {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--sheena-charcoal-light);
  cursor: pointer;
  padding: 0.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--sheena-radius-sm);
  transition: color 0.2s ease, background-color 0.2s ease;
  z-index: 3;
}

.sheena-password-toggle:hover {
  color: var(--sheena-teal);
  background-color: var(--sheena-teal-subtle);
}

.sheena-password-toggle:focus-visible {
  outline: 2px solid var(--sheena-teal);
  outline-offset: 2px;
}

/* Field Validation Message */
.sheena-field-error {
  display: none;
  font-size: 0.785rem;
  color: var(--sheena-error-text);
  margin-top: 0.35rem;
  padding-left: 0.25rem;
  font-weight: 500;
}

.sheena-field-error.active {
  display: block;
}

.sheena-form-control.is-invalid {
  border-color: var(--sheena-error-border);
  background-color: #fffbfa;
}

.sheena-form-control.is-invalid:focus {
  box-shadow: 0 0 0 4px rgba(229, 62, 62, 0.15);
}

/* Options Bar: Remember Me & Assistance */
.sheena-form-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: -0.25rem;
  margin-bottom: 1.75rem;
  font-size: 0.875rem;
}

.sheena-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  user-select: none;
  color: var(--sheena-charcoal-muted);
}

.sheena-checkbox-label input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 17px;
  height: 17px;
  border: 1.5px solid var(--sheena-border);
  border-radius: 4px;
  background-color: #ffffff;
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
  vertical-align: middle;
}

.sheena-checkbox-label input[type="checkbox"]:checked {
  background-color: var(--sheena-teal);
  border-color: var(--sheena-teal);
}

.sheena-checkbox-label input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 2px;
  width: 4px;
  height: 8px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.sheena-checkbox-label input[type="checkbox"]:focus {
  box-shadow: 0 0 0 3px rgba(79, 160, 164, 0.2);
}

.sheena-forgot-link {
  color: var(--sheena-teal);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease, text-decoration 0.2s ease;
}

.sheena-forgot-link:hover {
  color: var(--sheena-teal-hover);
  text-decoration: underline;
}

/* Submit Button */
.sheena-btn-primary {
  width: 100%;
  height: 48px;
  background-color: var(--sheena-teal);
  color: #ffffff;
  border: none;
  border-radius: var(--sheena-radius-md);
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  box-shadow: 0 4px 12px rgba(79, 160, 164, 0.35);
  transition: all 0.2s ease;
  position: relative;
}

.sheena-btn-primary:hover:not(:disabled) {
  background-color: var(--sheena-teal-hover);
  box-shadow: 0 6px 16px rgba(79, 160, 164, 0.45);
  transform: translateY(-1px);
}

.sheena-btn-primary:active:not(:disabled) {
  background-color: var(--sheena-teal-active);
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(79, 160, 164, 0.3);
}

.sheena-btn-primary:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px rgba(79, 160, 164, 0.35);
}

/* Loading State for Button */
.sheena-btn-primary:disabled,
.sheena-btn-primary.is-loading {
  background-color: #8bbdc0;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none;
}

.sheena-btn-spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  border-top-color: #ffffff;
  animation: sheena-spin 0.75s linear infinite;
}

.sheena-btn-primary.is-loading .sheena-btn-spinner {
  display: inline-block;
}

.sheena-btn-primary.is-loading .sheena-btn-text {
  opacity: 0.9;
}

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

/* Card & Page Footer */
.sheena-card-footer {
  margin-top: 2rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--sheena-charcoal-light);
}

/* Responsive Breakpoints */
@media (max-width: 992px) {
  .sheena-brand-hero {
    display: none; /* Mobile & Tablet: Hide left column to make single-column centered */
  }

  .sheena-form-container {
    padding: 2.5rem 1.5rem;
    background-color: var(--sheena-bg-soft);
  }

  .sheena-mobile-logo-header {
    display: block;
  }

  .sheena-login-card {
    padding: 2.25rem 1.75rem;
    box-shadow: 0 10px 25px -5px rgba(52, 52, 52, 0.08);
  }
}

@media (max-width: 480px) {
  .sheena-form-container {
    padding: 1.5rem 1rem;
  }

  .sheena-login-card {
    padding: 1.75rem 1.25rem;
    border-radius: 12px;
  }

  .sheena-card-title {
    font-size: 1.45rem;
  }

  .sheena-form-options {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
}


/* ==========================================================================
   Telerik RadComboBox Modern Flat Theme Integration
   ========================================================================== */
div.RadComboBox,
div.RadComboBox * {
  background-image: none !important;
  box-sizing: border-box !important;
}
div.RadComboBox,
div.RadComboBox_Default,
div.RadComboBox_Lightweight {
  width: 100% !important;
  height: 48px !important;
  background-color: var(--sheena-bg-soft) !important;
  border: 1.5px solid var(--sheena-border) !important;
  border-radius: var(--sheena-radius-md) !important;
  transition: all 0.2s ease !important;
  font-family: var(--sheena-font) !important;
}
div.RadComboBox:hover {
  border-color: #b5c7c8 !important;
  background-color: #ffffff !important;
}
div.RadComboBox:focus-within,
div.RadComboBox.rcbFocused {
  border-color: var(--sheena-teal) !important;
  background-color: #ffffff !important;
  box-shadow: 0 0 0 3.5px rgba(79, 160, 164, 0.18) !important;
}
div.RadComboBox table {
  width: 100% !important;
  height: 100% !important;
  border: none !important;
  background: transparent !important;
  border-collapse: collapse !important;
}
div.RadComboBox td {
  border: none !important;
  background: transparent !important;
  vertical-align: middle !important;
}
div.RadComboBox .rcbInputCell {
  padding-left: 42px !important;
}
div.RadComboBox .rcbInput {
  height: 44px !important;
  line-height: 44px !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  color: var(--sheena-charcoal) !important;
  font-size: 0.95rem !important;
  font-weight: 500 !important;
  font-family: inherit !important;
  outline: none !important;
}
div.RadComboBox .rcbArrowCell {
  padding-right: 14px !important;
  width: 32px !important;
}
div.RadComboBox .rcbArrowCell a {
  background: transparent !important;
  color: var(--sheena-charcoal-muted) !important;
}
.RadComboBoxDropDown {
  border: 1px solid var(--sheena-border) !important;
  border-radius: var(--sheena-radius-md) !important;
  box-shadow: 0 10px 25px -5px rgba(52, 52, 52, 0.1) !important;
  font-family: var(--sheena-font) !important;
  font-size: 0.9rem !important;
}
.RadComboBoxDropDown .rcbItem,
.RadComboBoxDropDown .rcbHovered {
  padding: 8px 14px !important;
}
.RadComboBoxDropDown .rcbHovered {
  background-color: var(--sheena-teal-subtle) !important;
  color: var(--sheena-teal-active) !important;
}
