<?php
/**
 * Responsive Design Helper
 * Include this in your page header to automatically load all responsive styles
 * 
 * Usage in your page <head>:
 * <?php include 'path/to/responsive-head-helper.php'; ?>
 */

// Get the base path for assets
$base_url = isset($_SERVER['REQUEST_SCHEME']) ? 
    $_SERVER['REQUEST_SCHEME'] . '://' . $_SERVER['HTTP_HOST'] : 'http://localhost';

// Determine if we're in a subdirectory
$script_path = dirname($_SERVER['SCRIPT_NAME']);
$is_root = $script_path === '/' || $script_path === '';
?>

<!-- Responsive Design & Chat System CSS -->
<?php if (file_exists(__DIR__ . '/../assets/css/responsive-utilities.css')): ?>
    <link rel="stylesheet" href="<?php echo $is_root ? '/interior/' : $script_path . '/'; ?>assets/css/responsive-utilities.css">
<?php endif; ?>

<?php if (file_exists(__DIR__ . '/../assets/css/responsive-chat.css')): ?>
    <link rel="stylesheet" href="<?php echo $is_root ? '/interior/' : $script_path . '/'; ?>assets/css/responsive-chat.css">
<?php endif; ?>

<meta name="faren-api-base" content="<?php echo $is_root ? '/interior/' : $script_path . '/'; ?>auth-system/api/chat-ai-v3.php">

<!-- FontAwesome Icons (for chat and UI icons) -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css" integrity="sha512-iecdLmaskl7CVJkEZSU0KVk/P1XLMm45yPXylQe40/Llscul6lbWlN00bNVXF3ZJoua7kLcWM9qkQUFTuEQllA==" crossorigin="anonymous" referrerpolicy="no-referrer">

<!-- Meta Tags for Responsive -->
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=5.0, user-scalable=yes">
<meta name="theme-color" content="#D4A574">
