/* Satoshi font-face definitions */
@font-face {
    font-family: 'Satoshi';
    font-style: normal;
    font-weight: 400;
    src: url('/seawhale/public/fonts/Satoshi-Regular.woff') format('woff');
}
@font-face {
    font-family: 'Satoshi';
    font-style: normal;
    font-weight: 700;
    src: url('/seawhale/public/fonts/Satoshi-Bold.woff') format('woff');
}
@font-face {
    font-family: 'Satoshi';
    font-style: italic;
    font-weight: 400;
    src: url('/seawhale/public/fonts/Satoshi-Italic.woff') format('woff');
}
@font-face {
    font-family: 'Satoshi';
    font-style: italic;
    font-weight: 700;
    src: url('/seawhale/public/fonts/Satoshi-BoldItalic.woff') format('woff');
}

body {
    font-family: 'Satoshi', Arial, sans-serif;
}

/* Sea Whale Brand Colors */
:root {
    --sw-primary: #0A1A4E;     /* Dark Navy */
    --sw-secondary: #4088FE;   /* Light Blue */
    --sw-tertiary: #3B424A;    /* Dark Gray */
    --sw-accent: #76E6FC;      /* Light Cyan */
    --sw-warning: #FFB800;     /* Golden Yellow - complements the blue palette */
    --whale: #0A194D;
    --seawater: #77BAEF;
    --clouds: #77E7FD;
    --border: #020266;
    --light-bg: #F5F8FB;
}

/* Sea Whale Background Colors */
.bg-sw-primary {
    background-color: var(--sw-primary) !important;
}

.bg-sw-secondary {
    background-color: var(--sw-secondary) !important;
}

.bg-sw-tertiary {
    background-color: var(--sw-tertiary) !important;
}

/* Sea Whale Text Colors */
.text-sw-primary {
    color: var(--sw-primary) !important;
}

.text-sw-secondary {
    color: var(--sw-secondary) !important;
}

.text-sw-tertiary {
    color: var(--sw-tertiary) !important;
}

.text-sw-accent {
    color: var(--sw-accent) !important;
}

/* Sea Whale Gradients */
.bg-sw-gradient-primary {
    background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-tertiary) 100%) !important;
}

/* Navbar specific gradient to ensure it works properly */
.navbar.bg-sw-gradient-primary {
    background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-tertiary) 100%) !important;
}

/* Ensure mobile menu has the same background */
@media (max-width: 991.98px) {
    .navbar.bg-sw-gradient-primary .navbar-collapse {
        background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-tertiary) 100%) !important;
        margin-top: 10px;
        padding: 15px;
        border-radius: 8px;
    }
}

/* Force override any Bootstrap navbar background */
nav.navbar-dark.bg-sw-gradient-primary,
.navbar-expand-lg.navbar-dark.bg-sw-gradient-primary,
nav.navbar.navbar-expand-lg.navbar-dark.bg-sw-gradient-primary {
    background: linear-gradient(135deg, #0A1A4E 0%, #3B424A 100%) !important;
    background-color: transparent !important;
}

.bg-sw-gradient-secondary {
    background: linear-gradient(135deg, var(--sw-secondary) 0%, var(--sw-primary) 100%) !important;
}

.bg-sw-gradient-ocean {
    background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-tertiary) 40%, var(--sw-primary) 100%) !important;
    position: relative !important;
}

.bg-sw-gradient-card {
    background: linear-gradient(135deg, rgba(10, 26, 78, 0.95) 0%, rgba(120, 187, 240, 0.1) 100%) !important;
}

/* Sea Whale Button Styles */
.btn-sw-primary {
    background: var(--sw-primary);
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-sw-primary:hover {
    background: #011249;
    color: white;
}

.btn-sw-secondary {
    background: var(--sw-secondary);
    color: white;
}

.btn-sw-secondary:hover {
    background: #0386f1;
    color: white;
}

.btn-sw-warning {
    background: var(--sw-warning);
    color: #000;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-sw-warning:hover {
    background: #f5bc2e;
    color: #000;
}

.btn {
    align-content: center;
}

/* Additional navbar styling to prevent background issues */
.navbar-dark.bg-sw-gradient-primary {
    background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-tertiary) 100%) !important;
}

/* Force gradient on all navbar elements */
nav.navbar.navbar-dark.bg-sw-gradient-primary {
    background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-tertiary) 100%) !important;
}

/* Ensure toggler button is visible on gradient */
.navbar-dark .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.3);
}

.navbar-dark .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.75%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Sea Whale Badge Styles */
.badge-sw-primary {
    background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-tertiary) 100%) !important;
    color: white !important;
    font-weight: 600 !important;
    padding: 0.5rem 0.75rem !important;
    border-radius: 10px !important;
    font-size: 0.75rem !important;
}

.badge-sw-warning {
    background: linear-gradient(135deg, var(--sw-warning) 0%, #FFD700 100%) !important;
    color: #000 !important;
    font-weight: 600 !important;
    padding: 0.5rem 0.75rem !important;
    border-radius: 10px !important;
    font-size: 0.75rem !important;
}

.badge-sw-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
    color: white !important;
    font-weight: 600 !important;
    padding: 0.5rem 0.75rem !important;
    border-radius: 10px !important;
    font-size: 0.75rem !important;
}

.badge-sw-info {
    background: linear-gradient(135deg, #17a2b8 0%, var(--sw-secondary) 100%) !important;
    color: white !important;
    font-weight: 600 !important;
    padding: 0.5rem 0.75rem !important;
    border-radius: 10px !important;
    font-size: 0.75rem !important;
}

.badge-sw-danger {
    background: linear-gradient(135deg, #dc3545 0%, #e74c3c 100%) !important;
    color: white !important;
    font-weight: 600 !important;
    padding: 0.5rem 0.75rem !important;
    border-radius: 10px !important;
    font-size: 0.75rem !important;
}

.badge-sw-dark {
    background: linear-gradient(135deg, #343a40 0%, #495057 100%) !important;
    color: white !important;
    font-weight: 600 !important;
    padding: 0.5rem 0.75rem !important;
    border-radius: 10px !important;
    font-size: 0.75rem !important;
}

.badge-sw-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #adb5bd 100%) !important;
    color: white !important;
    font-weight: 600 !important;
    padding: 0.5rem 0.75rem !important;
    border-radius: 10px !important;
    font-size: 0.75rem !important;
}

/* Sea Whale Service Card Styles */
.service-icon {
    background: rgba(120, 187, 240, 0.2);
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.service-icon-light {
    background: rgba(10, 26, 78, 0.1);
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.service-card-dark {
    background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-tertiary) 100%);
    min-height: 350px;
}

.service-card-light {
    background: linear-gradient(135deg, var(--sw-secondary) 0%, #a8ccf0 100%);
    min-height: 350px;
}

.service-card-gradient {
    background: linear-gradient(135deg, var(--sw-tertiary) 0%, var(--sw-primary) 100%);
    min-height: 350px;
}

.service-card-body {
    padding: 3rem 2rem !important;
}

/* Section Background Gradients */
.bg-section-light {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}
/* Single border between feature cards */
.features .card {
    border-right: 0;
}
.features .col-lg-3:not(:last-child) .card {
    border-right: 1px solid #0d6efd;
}
.features .col-lg-3:first-child .card {
    border-left: 1px solid #0d6efd;
}

/* Custom styles for the whole site */
.navbar, footer {
    position: relative;
    z-index: 999;
}
.hero-content {
    position: relative;
    z-index: 10;
    text-align: left;
    background: none;
    color: #fff;
    height: 100vh;
    max-width: auto;
    margin-left: 0;
    padding-top: 200px;
    padding-bottom: 100px
}
.hero-bg {
    position: relative;
    width: 100%;
}
.slideshow-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-size: cover;
    background-position: center;
    opacity: 0;
    z-index: 0;
    transition: opacity 2s;
    pointer-events: none;
}
.slideshow-bg.active {
    opacity: 1;
    animation: zoom-bg 30s ease-in-out infinite;
}
@keyframes zoom-bg {
    0% { transform: scale(1); }
    50% { transform: scale(1.25); }
    100% { transform: scale(1.25); }
}
.hero-bg .hero-content {
    position: relative;
    z-index: 2;
    text-align: left;
    color: #fff;
    padding: 6rem 4vw;
    pointer-events: auto;
    background: none;
    box-shadow: none;
    border-radius: 0;
    width: 100%;
    max-width: none;
}
.p-80 {
    padding: clamp(1.5rem, -10.8339rem + 16.4589vw, 5rem);
}

/* ==========================================
   CLIENT DASHBOARD STYLES
   ========================================== */

.dashboard-hero {
    background: linear-gradient(135deg, #0A1A4E 0%, #1e3a8a 50%, #3B424A 100%);
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

.dashboard-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="grid" width="50" height="50" patternUnits="userSpaceOnUse"><path d="M 50 0 L 0 0 0 50" fill="none" stroke="rgba(120,187,240,0.1)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    pointer-events: none;
}

.dashboard-card {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
}

/* Icon Background Utilities - Consistent Sizing */
.icon-bg-sm {
    width: 40px !important;
    height: 40px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
}

.icon-bg-md {
    width: 50px !important;
    height: 50px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
}

.icon-bg-lg {
    width: 60px !important;
    height: 60px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
}

/* Default icon background for consistency */
.bg-opacity-10.rounded-circle {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.floating-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.shape {
    position: absolute;
    background: rgba(120, 187, 240, 0.1);
    border-radius: 50%;
    animation: float 20s infinite linear;
}

.shape:nth-child(1) {
    width: 80px;
    height: 80px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.shape:nth-child(2) {
    width: 120px;
    height: 120px;
    top: 70%;
    right: 10%;
    animation-delay: 7s;
}

.shape:nth-child(3) {
    width: 60px;
    height: 60px;
    top: 50%;
    left: 5%;
    animation-delay: 14s;
}

.shape:nth-child(4) {
    width: 100px;
    height: 100px;
    top: 30%;
    right: 20%;
    animation-delay: 10s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    33% { transform: translateY(-30px) rotate(120deg); }
    66% { transform: translateY(20px) rotate(240deg); }
}

.header-card {
    background: linear-gradient(135deg, rgba(10, 26, 78, 0.9) 0%, rgba(30, 58, 138, 0.9) 100%);
    color: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.btn-modern {
    border-radius: 10px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-modern:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.btn-logout {
    background: linear-gradient(135deg, #dc3545 0%, #b02a37 100%);
    color: white;
}

.btn-logout:hover {
    background: linear-gradient(135deg, #b02a37 0%, #dc3545 100%);
    color: white;
}

.search-card {
    border-radius: 15px;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.dashboard-card .form-control,
.dashboard-card .form-select {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.dashboard-card .form-control:focus,
.dashboard-card .form-select:focus {
    border-color: #78BBF0;
    box-shadow: 0 0 0 0.25rem rgba(120, 187, 240, 0.25);
}

.table-card {
    border-radius: 15px;
    border: none;
    box-shadow: none !important;
    overflow: hidden;
}

.dashboard-card .table thead th {
    background: #f8f9fa;
    color: #0A1A4E;
    border: none;
    font-weight: 600;
    padding: 1rem;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dashboard-card .table tbody td {
    padding: 1rem;
    border-color: #f8f9fa;
    vertical-align: middle;
}

.dashboard-card .table tbody tr:hover {
    background-color: rgba(120, 187, 240, 0.05);
}

.status-badge {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.welcome-text {
    font-size: 1.25rem;
    margin-bottom: 0;
}

.client-name {
    background: linear-gradient(135deg, #78BBF0 0%, #295afc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
}

/* ==========================================
   CLIENT LOGIN STYLES
   ========================================== */

.login-hero {
    background: linear-gradient(135deg, #0A1A4E 0%, #1e3a8a 50%, #3B424A 100%);
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

.login-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="grid" width="50" height="50" patternUnits="userSpaceOnUse"><path d="M 50 0 L 0 0 0 50" fill="none" stroke="rgba(120,187,240,0.1)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    pointer-events: none;
}

.login-card {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

.login-card .form-floating .form-control {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 2rem 0.75rem 1rem;
    height: calc(3.5rem + 2px);
    line-height: 1.25;
    transition: all 0.3s ease;
}

.login-card .form-floating .form-control:focus {
    border-color: #78BBF0;
    box-shadow: 0 0 0 0.25rem rgba(120, 187, 240, 0.25);
}

.login-card .form-floating label {
    color: #6c757d;
    font-weight: 500;
}

.btn-login {
    background: linear-gradient(135deg, #0A1A4E 0%, #1e3a8a 100%);
    border: none;
    border-radius: 10px;
    padding: 0.875rem 2rem;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(10, 26, 78, 0.3);
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(10, 26, 78, 0.4);
    background: linear-gradient(135deg, #1e3a8a 0%, #0A1A4E 100%);
}

.password-toggle {
    border: 2px solid #e9ecef;
    border-left: none;
    border-radius: 0 10px 10px 0;
    background: transparent;
    color: #6c757d;
    transition: all 0.3s ease;
}

.password-toggle:hover {
    background: #f8f9fa;
    color: #0A1A4E;
}

.welcome-section {
    background: rgba(10, 26, 78, 0.1);
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    text-align: center;
}

.brand-logo {
    max-height: 60px;
    margin-bottom: 1rem;
}

/* ==========================================
   ADMIN DASHBOARD STYLES
   ========================================== */

.admin-action-card {
    border: 2px solid #f8f9fa !important;
    transition: all 0.3s ease;
    background: #fff;
}

.admin-action-card:hover {
    border-color: #78BBF0 !important;
    background: rgba(120, 187, 240, 0.02);
}

.admin-comm-item {
    transition: all 0.2s ease;
    cursor: pointer;
}

.admin-comm-item:hover {
    background-color: rgba(120, 187, 240, 0.05) !important;
}

/* Modern Badge Styles for Shipments */
.badge-success-glass {
    background: linear-gradient(135deg, rgba(25, 135, 84, 0.9), rgba(25, 135, 84, 0.7));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(25, 135, 84, 0.3);
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.badge-warning-glass {
    background: linear-gradient(135deg, rgba(255, 193, 7, 0.9), rgba(255, 193, 7, 0.7));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 193, 7, 0.3);
    color: #212529;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.badge-danger-glass {
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.9), rgba(220, 53, 69, 0.7));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(220, 53, 69, 0.3);
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.badge-info-glass {
    background: linear-gradient(135deg, rgba(13, 202, 240, 0.9), rgba(13, 202, 240, 0.7));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(13, 202, 240, 0.3);
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.badge-primary-glass {
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.9), rgba(13, 110, 253, 0.7));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(13, 110, 253, 0.3);
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.badge-secondary-glass {
    background: linear-gradient(135deg, rgba(108, 117, 125, 0.9), rgba(108, 117, 125, 0.7));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(108, 117, 125, 0.3);
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Table Improvements */
.table-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.25), rgba(255, 255, 255, 0.1));
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.bg-gradient-primary {
    background: linear-gradient(135deg, var(--sw-primary) 0%, var(--sw-secondary) 100%) !important;
}

.table-hover tbody tr:hover {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
}

/* Dropdown z-index fix for table containers */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute !important;
    z-index: 10000 !important;
    transform: translateZ(0);
}

/* Force dropdown to be above everything */
.dropdown.show .dropdown-menu {
    z-index: 10001 !important;
    position: absolute !important;
    will-change: transform;
}

/* Ensure card header allows dropdowns to overflow */
.card-header {
    overflow: visible !important;
    position: relative;
    z-index: 9998;
}

/* Table responsive container adjustments */
.table-responsive {
    position: relative;
    z-index: 1;
    overflow-x: auto;
    overflow-y: visible;
}

/* Dashboard card specific fixes */
.dashboard-card {
    position: relative;
    z-index: auto;
}

.dashboard-card .table-card {
    overflow: visible;
}

/* Force table container to respect dropdown layering */
.table-card .card-body {
    position: relative;
    z-index: 1 !important;
}

/* Dynamic height table adjustments */
.dynamic-height-table {
    transition: height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.dynamic-height-table .table-responsive {
    height: calc(100% - 80px); /* Subtract header height */
    overflow-y: auto;
    overflow-x: auto;
}

/* Height rules based on quotation count */
.dynamic-height-table[data-row-count="0"],
.dynamic-height-table[data-row-count="1"] {
    height: 330px !important;
}

.dynamic-height-table[data-row-count="2"],
.dynamic-height-table[data-row-count="3"],
.dynamic-height-table[data-row-count="4"],
.dynamic-height-table[data-row-count="5"] {
    height: 100% !important;
}

/* For 6+ quotations, also use 100% height */
.dynamic-height-table[data-row-count] {
    height: 100%;
}

.dynamic-height-table[data-row-count="0"],
.dynamic-height-table[data-row-count="1"] {
    height: 330px !important;
}

/* Responsive height adjustments */
@media (max-width: 768px) {
    .dynamic-height-table {
        min-height: 300px !important;
        height: auto !important;
    }
    
    .dynamic-height-table .table-responsive {
        height: auto;
        max-height: 400px;
    }
}
