/******************************************************************************/
/*                                                                            */
/* rexx-print.css - CSS for Rexx highlighting, print-optimized style         */
/* =================================================================         */
/*                                                                            */
/* Designed for paper output: white background, high-contrast colours         */
/* that remain distinguishable when printed in colour or greyscale.           */
/* Inspired by the conventions of LaTeX listings and printed textbooks.       */
/*                                                                            */
/* This program is part of the Rexx Parser package                            */
/* [See https://rexx.epbcn.com/rexx-parser/]                                  */
/*                                                                            */
/* Copyright (c) 2024-2026 Josep Maria Blasco <josep.maria.blasco@epbcn.com>  */
/*                                                                            */
/* License: Apache License 2.0 (https://www.apache.org/licenses/LICENSE-2.0)  */
/*                                                                            */
/* Version history:                                                           */
/*                                                                            */
/* Date     Version Details                                                   */
/* -------- ------- --------------------------------------------------------- */
/* 20260310    0.5  First release                                             */
/*                                                                            */
/******************************************************************************/

/******************************************************************************/
/******************************************************************************/
/* BASE SELECTOR: highlight-rexx-print                                        */
/******************************************************************************/
/******************************************************************************/
/*   Format: "highlight-rexx-<stylename>                                      */
/*   It will apply to the whole CSS file                                      */
/******************************************************************************/

.highlight-rexx-print {

/******************************************************************************/
/* Default settings                                                           */
/* ================                                                           */
/*                                                                            */
/*   Pure white background, near-black text.                                  */
/*   The "rexx" class is used as a fallback when no suitable class is found   */
/*                                                                            */
/******************************************************************************/

  pre, .rexx {
    background-color: #ffffff;
    color: #1a1a1a;
  }

/******************************************************************************/
/* Support for line numbers                                                   */
/* ========================                                                   */
/******************************************************************************/

  .rx-lineno  {                         /* ANSI Driver only                   */
    color: #888888;
    font-style: italic;
  }
  .rx-linebar {                         /* ANSI Driver only                   */
    color: #aaaaaa;
  }

  pre.number-lines {
          padding-left: 50px;
    &.w3 {padding-left: 58px; code:before {width:58px;} }
    &.w4 {padding-left: 65px; code:before {width:65px;} }
    &.w5 {padding-left: 72px; code:before {width:72px;} }
    code:before{
      content: attr(lineno) " | ";
      position:absolute;
      left:10px;
      width:50px;
      text-align:right;
      color: #aaaaaa;
    }
  }

/******************************************************************************/
/* Whitespace and continuations                                               */
/* ============================                                               */
/******************************************************************************/

  .rx-ws, .rx-cont { color: #aaaaaa; }

/******************************************************************************/
/* Standard (non-doc) comments                                                */
/* ===========================                                                */
/******************************************************************************/

  .rx-cm,                               /* Classic, block comments            */
  .rx-lncm {                            /* Line comments                      */
    color: #606060;
    font-style: italic;
  }

/******************************************************************************/
/* Doc-comments                                                               */
/* ============                                                               */
/******************************************************************************/

  .rx-doc-comment,                      /* Classic style doc-comments         */
  .rx-doc-comment-markdown {            /* Markdown style doc-comments        */

    color: #505060;                     /* Default values (for "block"..      */
    font-style: italic;                 /* ..highlighting).                   */

    &.rx-doc-comment-armature,          /* Armature, whitespace and main      */
    &.rx-doc-comment-whitespace,        /* description share the same style.  */
    &.rx-doc-comment-main-description {
      color: #505060;
      font-style: italic;
    }
    &.rx-doc-comment-summary {          /* Initial summary statement.         */
      color: #8b4500;
      text-decoration:underline;
      font-style: normal;
    }
    &.rx-doc-comment-tag {              /* @block-tag                         */
      color: #9a2040;
      font-style: normal;
    }
    &.rx-doc-comment-tag-value {        /* As the name in "@param name".      */
      color: #6a1b9a;
      font-style: normal;
    }
    &.rx-doc-comment-tag-description {  /* Text after @deprecated.            */
      color: #2e6e4e;
      font-style: italic;
    }
  }

/******************************************************************************/
/* Shebangs                                                                   */
/* ========                                                                   */
/******************************************************************************/

  .rx-shb { color: #9a2040; font-style: italic; }

/******************************************************************************/
/* Keywords and subkeywords, assignment sequences, and "::"                   */
/* ========================================================                   */
/******************************************************************************/

  .rx-kw,                               /* Keywords                           */
  .rx-skw,                              /* Subkeywords                        */
  .rx-dkw,                              /* Directive keywords                 */
  .rx-dskw,                             /* Directive subkeywords              */
  .rx-asg,                              /* Assignment sequences (incl. "=")   */
  .rx-dir                               /* The directive start "::" sequence  */
  {
    color: #2b3d8f;
    font-weight: bold;
  }

  /* Additionally, directive keywords and subkeywords are underlined          */

  .rx-dkw, .rx-dskw { text-decoration:underline; }

/******************************************************************************/
/* Strings (including taken constants that are strings)                       */
/* ====================================================                       */
/******************************************************************************/

  .rx-str , .rx-bstr, .rx-xstr,         /* Classic Rexx strings               */
  .rx-ystr, .rx-pstr, .rx-gstr, .rx-tstr, .rx-ustr { /* TUTOR Unicode strings */
    color: #3a6e2e;                     /* the inner part of the string       */
    &.rx-ssuf            {color: #a04000;} /* String suffix                   */
    &.rx-oquo, &.rx-cquo {color: #6a4000;} /* Quotes                         */
  }

  /* Taken constants that are strings                                         */

  .rx-const {
    &.rx-ssuf            {color: #a04000;} /* String suffix                   */
    &.rx-oquo, &.rx-cquo {color: #6a4000;} /* Quotes                         */
  }

/******************************************************************************/
/* Numbers                                                                    */
/* =======                                                                    */
/******************************************************************************/

  /*--------------------------------------------------------------------------*/
  /* Simple highlighting classes (not used by the highlighter)                */
  /*--------------------------------------------------------------------------*/

  .rx-int,                              /* Integers                           */
  .rx-deci,                             /* Decimals (w/ a dot, no exponent)   */
  .rx-exp {                             /* Exponentials (w/ or w/o a dot)     */
    color:#a04000;
  }

  /*--------------------------------------------------------------------------*/
  /* Detailed highlighting (includes non X and B strings that are numbers)    */
  /*--------------------------------------------------------------------------*/

  .rx-nsign { color: #6a4000; }         /* Number sign (for strings only)     */


  .rx-ipart,                            /* Integer part                       */
  .rx-fpart,                            /* Fractional part                    */
  .rx-expon                             /* The exponent itself                */
  {
    color:#a04000;
  }

  .rx-dpoint { color: #6a4000; }        /* The decimal point                  */
  .rx-emark  { color: #6a4000; }        /* The exponent mark ("E" or "e")     */
  .rx-esign  { color: #6a4000; }        /* The (optional) exponent sign       */

/******************************************************************************/
/* Variables and constant symbols                                             */
/* ==============================                                             */
/******************************************************************************/

  /* Common color for all variables (except stems)                            */
  .rx-var, .rx-xvar, .rx-cmp, .rx-xcmp { color: #1a1a1a; }

  /* Stems get their own color to stand out                                   */
  .rx-stem, .rx-xstem { color: #6a1b9a; }

  /* Additionally, exposed variables will be italicized                       */
  .rx-xvar, .rx-xstem, .rx-xcmp { font-style: italic; }

  /* Environment symbols                                                      */
  .rx-env { color: #6a1b9a; font-style: italic; }

  /* Const symbols that are not environment symbols                           */
  .rx-lit { color: #5a6e50; }

/******************************************************************************/
/* Special characters                                                         */
/* ==================                                                         */
/******************************************************************************/

  .rx-spe { color:#9a2040; }

/******************************************************************************/
/* Operators                                                                  */
/* =========                                                                  */
/******************************************************************************/

  .rx-op  { color:#5a6e50; }

/******************************************************************************/
/* Taken constants                                                            */
/* ===============                                                            */
/*                                                                            */
/*   I.e., tokens that are "strings or symbols taken as a constant".          */
/*   In the case of strings, quotes and suffixes are styled under "strings".  */
/******************************************************************************/

  .rx-const {

    /*------------------------------------------------------------------------*/
    /* Default highlighting                                                   */
    /*------------------------------------------------------------------------*/

    color: #4a5a8a;

    /*------------------------------------------------------------------------*/
    /* Named arguments (Executor)                                             */
    /*------------------------------------------------------------------------*/

    &.rx-argument-name {
      color:#8b4500;                     /* Color                             */
    }

    /*------------------------------------------------------------------------*/
    /* Built-in functions and procedures                                      */
    /*------------------------------------------------------------------------*/

    &.rx-bif-func, &.rx-bif-proc {
      color:#4a5a8a;                     /* Color (symbols and strings)        */
      &.rx-ssuf {color: #a04000;}        /* Suffix (for strings)               */
      &.rx-oquo,                         /* Quotes (for strings)               */
      &.rx-cquo {color: #6a4000;}
    }

    /*------------------------------------------------------------------------*/
    /* Internal functions and procedures, labels and block instruction names  */
    /*------------------------------------------------------------------------*/

    &.rx-int-func, &.rx-int-proc, &.rx-block, &.rx-label {
      color:#a04000;                     /* Color (symbols and strings)        */
      &.rx-ssuf {color: #a04000;}        /* Suffix (for strings)               */
      &.rx-oquo,                         /* Quotes (for strings)               */
      &.rx-cquo {color: #6a4000;}
    }

    /*------------------------------------------------------------------------*/
    /* ::ROUTINE names, ::ROUTINE function and procedure calls,               */
    /* and namespace-qualified ::ROUTINEs                                     */
    /*------------------------------------------------------------------------*/

    &.rx-routine, &.rx-pkg-func, &.rx-pkg-proc, &.rx-ext-pkg-func,
    &.rx-ext-pkg-proc {
      color:#9a2040;                     /* Color (symbols and strings)        */
      &.rx-ssuf {color: #a04000;}        /* Suffix (for strings)               */
      &.rx-oquo,                         /* Quotes (for strings)               */
      &.rx-cquo {color: #6a4000;}
    }

    /*------------------------------------------------------------------------*/
    /* External calls                                                         */
    /*------------------------------------------------------------------------*/

    &.rx-ext-func, &.rx-ext-proc {
      color:#9a2040;                     /* Color (symbols and strings)        */
      font-style: italic;               /* Italic (symbols and strings)       */
      &.rx-ssuf {color: #a04000;}        /* Suffix (for strings)               */
      &.rx-oquo,                         /* Quotes (for strings)               */
      &.rx-cquo {color: #6a4000;}
    }

    /*------------------------------------------------------------------------*/
    /* Method names                                                           */
    /*------------------------------------------------------------------------*/

    &.rx-method {
      color:#8b4500;                     /* Color (symbols and strings)        */
      font-style: italic;               /* Italic (symbols and strings)       */
      &.rx-ssuf {color: #a04000;}        /* Suffix (for strings)               */
      &.rx-oquo,                         /* Quotes (for strings)               */
      &.rx-cquo {color: #6a4000;}
    }

    /*------------------------------------------------------------------------*/
    /* Namespace names                                                        */
    /*------------------------------------------------------------------------*/

    &.rx-namespace {
      color: #8b4500;                    /* Color (symbols and strings)        */
      &.rx-ssuf {color: #a04000;}        /* Suffix (for strings)               */
      &.rx-oquo,                         /* Quotes (for strings)               */
      &.rx-cquo {color: #6a4000;}
    }

    /*------------------------------------------------------------------------*/
    /* Resources                                                              */
    /*------------------------------------------------------------------------*/

    /* Resource name                                                          */
    &.rx-resource {
      color: #8b4500;                    /* Color (symbols and strings)        */
      &.rx-ssuf {color: #a04000;}        /* Suffix (for strings)               */
      &.rx-oquo,                         /* Quotes (for strings)               */
      &.rx-cquo {color: #6a4000;}
    }

    /* Resource delimiter                                                     */
    .rx-res-delimiter {
      color: #8b4500;
      text-decoration:underline;
    }

  } /* <-- END OF .rx-const                                                   */

/******************************************************************************/
/* ::RESOURCE data and ignored stuff                                          */
/******************************************************************************/

  /* Resource data                                                            */
  .rx-res-data {
    color: #8b4500;
    font-style: italic;
  }

  /* Resource ignored stuff                                                   */
  .rx-res-ignore {
    color: #606060;
    font-style: italic;
  }

/******************************************************************************/
/******************************************************************************/
/* END highlight-rexx-print                                                   */
/******************************************************************************/
/******************************************************************************/

} /* <--- END OF highlight-rexx-print                                         */

/******************************************************************************/
/******************************************************************************/
/* END OF BASE SELECTOR highlight-rexx-print                                  */
/******************************************************************************/
/******************************************************************************/